How to add custom script

You can simply install the plugin – “Code Snippets”, author: Shea Bunge

Go to Snippets->Add New

Input the title and code, choose where you want to rund the script, all done!