Viewing profile — rustshellscript
rustshellscript
HN member- Joined
- Fri, Sep 27, 2019, 5:34 PM UTC
- HN karma
- 115
- Public activity
- 19 items
- HN profile
- View on Hacker News ↗
About rustshellscript
Recent public activity
- story
-
comment
Comment #38022631
You can check https://github.com/rust-shell-script/rust_cmd_lib
-
comment
Comment #38022616
Here: https://github.com/rust-shell-script/rust_cmd_lib
-
comment
Comment #29065625
Here is the rust library with the “the only good parts” of bash/shell script: https://github.com/rust-shell-script/rust_cmd_lib
-
comment
Comment #26777492
The only good part of sh/bash script is to run commands with piping/redirection support IMO,other than that I saw posts like this to explain sh/bash script’s puzzles/pitfalls all t…
-
comment
Comment #26683536
zsh is also doing the variable substitution better than bash. FYI, I just released rust_cmd_lib 1.0 recently, which can do variable substitution without any quotes: https://github.…
-
comment
Comment #25431342
I have developed a similar library before: https://github.com/rust-shell-script/bash_cmd_lib/blob/maste... which can do temp files cleanup, different levels ofreporting and redirec…
-
comment
Comment #25296266
Thanks Steve. I have studied the "200 lines" book a few days ago, but was still confused. Only after seeing your talks, everything becomes so much clearer. These talks should reall…
- story
-
comment
Comment #24403571
I have created a similar library for bash. However, there are more pitfalls related to errexit, see [1] and even shellcheck can not help there. I have tried to solve the pitfalls i…
-
comment
Comment #24252873
Unquoted argument is not an issue here, see some examples here: https://github.com/rust-shell-script/rust_cmd_lib/issues/10
-
comment
Comment #24252822
since run_cmd! and run_fun! are returning result type, you can always do let _ = run_cmd!(ls nofile); to ignore single command error. The “xxx || true” is for ignoring error within…
-
comment
Comment #24252040
It can be supported with internal APIs, even without macros: Cmds::from_cmd(Cmd(...).current_dir(..)) .pipe(Cmd(...).current_dir(...)) .run_cmd(...) As you can see, it is very verb…
-
comment
Comment #24251537
Thanks, yes since I just finished the core functionality of this project and I am not surprised if it is still missing some critical features when converting bash script. Pls file …
-
comment
Comment #24251502
You can consider it was enabled by default, and any failed command would return error unless you mask it with “xx || true”.
-
comment
Comment #24251481
Yes, I also use this for automatically capturing command error messages with timestamps into logs: https://github.com/rust-shell-script/bash_cmd_lib/blob/0b0a6... However this can …
-
comment
Comment #24251372
Author here, thanks for your feedback. This library is calling std::process::command underneath without any shell dependency, which I believe is the same as plumbum’s run* APIs and…
- story
-
comment
Comment #21094323
I am recently working on a hobby programming language: https://github.com/rust-shell-script/rust-shell-script , which could compile to either rust code or shell script. This book h…