Home > Linux > Some bash stuff

Some bash stuff

I just need a cheat sheet because I keep forgetting all these bash things.

Number of parameters: $#
All parameters: $@
String length: ${#foo}
Remove trailing slash: ${foo%/}
Check return value from last command: $?
Categories: Linux Tags:
  1. No comments yet.
  1. No trackbacks yet.

Time limit is exhausted. Please reload CAPTCHA.