You can deprecate a script that’s no longer required. Once a script is deprecated, only the View Details option is enabled in the Quick Actions drop-down menu.
In the Scripts tab, select the script you want to deprecate and then click Quick Actions > Deprecate.
The Deprecate option is disabled if the script is deprecated or rejected.
A deprecated script is automatically deleted after 7 days as a part of a scheduled job.