jmcantrell / bashful Goto Github PK
View Code? Open in Web Editor NEWA collection of modules to simplify writing bash scripts.
License: Do What The F*ck You Want To Public License
A collection of modules to simplify writing bash scripts.
License: Do What The F*ck You Want To Public License
Hi thanks for this helpful libraries,
Please, can't figure out the usage of the helper functions :
https://github.com/jmcantrell/bashful/blob/master/bin/bashful-utils#L605-L639
Do you have more examples (input/output)?
Best regards
Sometimes it would be very handy to have a function like this:
check_rc()
{
if [[ $? -gt 0 ]]; then
if [[ ${1} != "" ]]; then
echo -e "${@}"
fi
exit 1
fi
}
I've used it a couple of times now in my own coding, allowing critical actions to abort scripts very handy.
startup_server 2> error.log
check_rc "Error: Could not start server, please check error.log!"
Accepts input separated with enter until the value is empty.
Sometimes it would be good to allow several choices. (Separated by comma?)
A new arg for minimal and maximal amount would be handy too!
Something that suggests values like choice, but also allows for a completely user-input.
(One more choice for custom)
Request
Could we get documentation in github as part of READMEs or a Wiki?
I find it easier to read documentation that way and I think people would find the project more appealing if they could read about the libraries functions before cloning.
What license are these wonderful libraries under?
Hey... Is there a wiki or blog post on this collection? I've got a bunch of small questions and wasn't sure where to ask them:
Thanks!
See title
It would be great to have the possibility to enable 2> && > redirection with a parameter for all execution commands. This allows to write all errors or output to a target file without needing to keep putting it in the command or function call. (something like execute_output or execute_error, without argument gets the current destination (defaults to stdout and stderr) and with sets the new target).
@jmcantrell First of all, thank you for sharing your work!
Could you please give a pretty detailed example of usage
command?
I guess I have to manually check if each parameter/option has been passed or not, then call usage accordly, isn't it?
Thank you
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.