I appreciate the idea, but the comma just looks horrible to me as part of a filename. I can imagine someone unfamiliar with the naming scheme to get confused. I'd prefer to use underscore (when writing BASH scripts, I name all my local variables starting with underscore), but a simple two or three letter prefix would also work. I don't like the idea of a punctuation prefix as punctuation usually has a specific meanin…
I use my_ as a prefix.
Start all of your commands with a comma (2009)
41–50 of 252 posts
Re: Start all of your commands with a comma (2009)
#42quick, easy and consistent. entirely voluntary.
Bravo
Re: Start all of your commands with a comma (2009)
#43If we want to stay within (lowercase) alphabetic Latin characters I think prefixing with the least common letters or bigrams that start a word (x, q, y, z, j) is best.
`y' for instance only autocompletes to `yes' and `ypdomainname' on my path.
Choosing a unique bigram is actually quite easy and a fun exercise.
And we can always use uppercase Latin letters since commands very rarely use never mind start with those.
Re: Start all of your commands with a comma (2009)
#44Why so many people use ~/bin/? What’s wrong with ~/.local/bin?
Re: Start all of your commands with a comma (2009)
#45Re: Start all of your commands with a comma (2009)
#46Off-topic: What the hell is that font on this website? And why does the "a" look like that?
Re: Start all of your commands with a comma (2009)
#47Re: Start all of your commands with a comma (2009)
#48This is one of those ideas that is so simple and elegant that it makes you think “why did I never think of doing this?!” Neat trick! I don’t think I’ll namespace everything this way, because there’s some aliases and commands I run so often that the comma would get annoying, but for other less frequently used helper scripts then this will be perfect!
I do something similar with build trees, naming them +build, +cross-arm etc. This convention was suggested by the GNU Arch version control system years ago (maybe 20??), but it's really useful for the same tab completion reason and I have kept it for almost two decades, even when I switched to git.
File names or directories starting with a comma where considered “junk”, and ones with a plus sign I think where considered “precious”.
Re: Start all of your commands with a comma (2009)
#49I didn't like the idea. I prefer the alternative approach: _I_ decide the order of dirs in the PATH env. If I introduce an executable with a name, that overrides a system one - I probably do that intentionally. If I introduce an alias (like `grep='grep --binary-files=without-match --ignore-case --color=auto`) that matches the name of a system binary - I probably do that intentionally. And if I EVER need to call grep…
> If I introduce an executable with a name, that overrides a system one ... and breaks existing scripts that reference the system one, right?
Re: Start all of your commands with a comma (2009)
#50I use a different prefix character, e.g. "[", but I have been doing this for years I started using a prefix because I like very short script names that are easy to type I prefer giving scripts numbers instead of names Something like "[number" I use prefixes and suffixes to group related scripts together, e.g., scripts that run other scripts I have an executable directory like ~/bin but it's not called bin. It contain…