Manage source code of AppleScript

As "young" user of Apple technologies, AppleScript and KM, I want to ask experienced users here how you manage your AppleScript code, samples, solutions.

I see plenty of code here, for example from @ccstone which have beauty header with good description (see for example here Activate Safari/Chrome and Select an Existing Tab vs Creating a New Tab) which may be used in many cases and I'm wondering how to group such code, searching then it is needed etc.
For me Unix/Perl/Python practitioner for above 30 years, AppleScript is hard to write and use and many times when I find nice code snippet, I want to save it somewhere ... And later when I want to use it, I always digging into different places in filesystem where I hide it before.

Could you have some advices, good practice rules os something?

And are you store your scripts in text or maybe in compiled form? Are you using code versioning (git?).

Many thanks for any suggestion..

I wouldn't say I'm as experienced as a lot of the other people here, but I've been trying to organise my code with a snippets library. I generally use SnippetsLab, which used to be paid software but is now free. Although I usually prefer open source and have looked at alternatives like FSNotes, massCode, and Lepton, I haven't actually tried any yet. Sadly SnippetsLab is only available through the Mac App Store, but the three open source alternatives I mentioned can be installed with brew.

1 Like

Thanks
I didn't know about any of that programs, maybe I will check SinppetsLab - I prefer local solutions - not using public Github or Gitlab (I have my own instance of Forego on FreeBSD).

Another option is to make own repository with good, clean header in the beginning and use scanning to read Tags inside them. Maybe moving tags to the macOS filesystem is good option - just wondering about different solutions.

Anyway - thank you for your suggestions.