shunit2
pure-sh-bible
shunit2 | pure-sh-bible | |
---|---|---|
4 | 29 | |
1,549 | 6,281 | |
- | - | |
3.5 | 0.0 | |
3 months ago | 4 months ago | |
Shell | Shell | |
Apache License 2.0 | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
shunit2
-
Pure Bash Bible
> or something that would proper unit testing
<https://github.com/kward/shunit2>
-
First time writing bash scripts for work, not sure if this is true elsewhere
https://github.com/kward/shunit2 is your friend here.
-
AWK an old-school tool today
And in case you are thinking how powerful this is and like me trying to take it further to create small AWK powered "apps" to do the monotonous tasks while wondering how can you verify if what you are coding is valid, you can execute any number of unit tests for shell scripts, and therefore, AWK scripts using shunit2
-
ShellCheck: A static analysis tool for shell scripts
Alongside ShellCheck, I also use shUnit2 as my unit testing framework. Yes, you should test your bash.
https://github.com/kward/shunit2
pure-sh-bible
-
Kiss Package Manager
The guy who wrote it, also wrote a POSIX Shell bible: https://github.com/dylanaraps/pure-sh-bible
-
Pure Bash Bible
Do you have any specific examples to cite? The snippets are meant to be run in POSIX-compliant shells like dash/yash/ash/etc, not just Bash in compatibility mode.
In fact, there used to be a section which listed workarounds[1] for bugs in dash, but they have since been fixed[2]. If you are still using an old version of dash, you may need to use them.
[1] https://github.com/dylanaraps/pure-sh-bible/commit/70f410ebb...
[2] https://github.com/dylanaraps/pure-sh-bible/issues/13
- Pure Sh Bible
-
"Immortal" Bash scripts, using inline Nix and a special header block
Personally, I would steer clear of a script that installs dependencies on it's own. Us sysadmins prefer to manage our own dependencies, generally speaking. Instead consider a README that outlines how to meet/install dependencies for the script, or try to find ways to write your script in pure Shell or Bash without using tools like awk, jq, etc. Consider having a look at the Pure Sh Bible for examples of how to do many useful things in pure Sh.
- r/posixshell Lounge
-
Shell in a nutshell
POSIX Shell Tutorial POSIX shell cheat sheet GitHub - dylanaraps/pure-sh-bible: ๐ A collection of pure POSIX sh alternatives to externalโฆ Shell Scripting Tutorial
-
Just: A Command Runner
There is the "pure bash bible" but it seems less than maintained these days: https://github.com/dylanaraps/pure-sh-bible
Otherwise you're stuck reading the POSIX standard: https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V...
- Unix shell script tactics - a style guide
-
Posix shell compliant
Look at this: https://github.com/dylanaraps/pure-sh-bible
What are some alternatives?
bats-core - Bash Automated Testing System
pure-bash-bible - ๐ A collection of pure bash alternatives to external processes.
shellspec - A full-featured BDD unit testing framework for bash, ksh, zsh, dash and all POSIX shells
awesome-bash-commands - A curated list of awesome Bash useful commands. Inspired by awesome-shell and bash-handbook.
ShellCheck - ShellCheck, a static analysis tool for shell scripts
bfetch - ๐ Dynamic fetch displayer that SuperB
sh - A shell parser, formatter, and interpreter with bash support; includes shfmt
scripts-to-rule-them-all - Set of boilerplate scripts describing the normalized script pattern that GitHub uses in its projects.
shellharden - The corrective bash syntax highlighter
snake-bash - Command Line Snake Game written in BASH
etc - Things that are too small to keep in a separate repo, but too important not to version them.
clh-bash - Arcade game to show your Command Line Hero skills! The game challenges you to enter as many valid commands as you can in 60 seconds!