This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### | |
A meta-compilation of: | |
https://raw.github.com/gist/1453705/d253733a56632a8d2c29321a75c18b627fa4dda8/reserved_usernames.rb | |
http://blog.postbit.com/reserved-username-list.html | |
http://www.quora.com/How-do-sites-prevent-vanity-URLs-from-colliding-with-future-features | |
(Took out some company-specific terms at the top of the first one (e.g. imulus, stacks), added one term so far - 'edits'.) | |
NOTE: Does not include profanities. You may or may not want to add a list of those. | |
(See https://www.google.com/search?q=profanity+list, but don't try to apply regexp's here because Scunthorpe - http://en.wikipedia.org/wiki/Scunthorpe_problem) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export function j(strings: TemplateStringsArray, ...values: any) { | |
return strings | |
.map((string: string, i: number) => { | |
return Array.isArray(values[i]) | |
? string + values[i].join("") | |
: string + (values[i] || ""); | |
}) | |
.join(""); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Copied from https://sipb.mit.edu/doc/safe-shell/ | |
Writing shell scripts leaves a lot of room to make mistakes, in ways that will cause your scripts to break on certain input, or (if some input is untrusted) open up security vulnerabilities. Here are some tips on how to make your shell scripts safer. | |
Don't | |
The simplest step is to avoid using shell at all. Many higher-level languages are both easier to write the code in in the first place, and avoid some of the issues that shell has. For example, Python will automatically error out if you try to read from an uninitialized variable (though not if you try to write to one), or if some function call you make produces an error. | |
One of shell's chief advantages is that it's easy to call out to the huge variety of command-line utilities available. Much of that functionality will be available through libraries in Python or other languages. For the handful of things that aren't, you can still call external programs. In Python, the subprocess module is very useful for |