About 1,090,000 results
Open links in new tab
  1. What is the meaning of $? in a shell script? - Unix & Linux Stack …

    Feb 20, 2011 · When going through one shell script, I saw the term "$?". What is the significance of this term?

  2. Difference between ${} and $() in a shell script - Super User

    Difference between $ {} and $ () in a shell script Ask Question Asked 10 years, 5 months ago Modified 10 months ago

  3. Shell scripting: -z and -n options with if - Unix & Linux Stack …

    Jan 16, 2014 · You can find a very nice reference for bash's [ aka test builtin's operators here, or by running help test in a bash shell or info bash test or info bash '[' from any shell¹. If you are …

  4. What does $# mean in shell? - Unix & Linux Stack Exchange

    What does $# mean in shell? I have code such as if [ $# -eq 0 ] then I want to understand what $# means, but Google search is very bad for searching these kinds of things.

  5. shell script - How to iterate a CSV file in bash? - Unix & Linux Stack ...

    Nov 28, 2019 · First of all, avoid doing text-parsing with shell loops. It is hard to do, easy to get wrong and very hard to read. And slow. Very, very, slow. Instead, use something like awk …

  6. Precedence of the shell logical operators - Unix & Linux Stack …

    This has confused me a lot in trying to write shell script pipelines with different logic based on some test (e.g. exiting if a file doesn't exist vs continuing the pipeline).

  7. looping through `ls` results in bash shell script - Super User

    Sep 6, 2017 · 169 Does any one have a template shell script for doing something with ls for a list of directory names and looping through each one and doing something? I'm planning to do ls …

  8. Shell script echo new line to file - Super User

    Shell script echo new line to file Ask Question Asked 14 years, 4 months ago Modified 12 years, 4 months ago

  9. Passing named arguments to shell scripts - Unix & Linux Stack …

    $ ./my_script -p '/some/path' -a5 Argument p_out is /some/path Argument arg_1 is 5 There is a helpful Small getopts tutorial or you can type help getopts at the shell prompt. Edit: The …

  10. What does -f mean in an if statement in a bash script?

    Jul 5, 2018 · The relevant man page to check for this is that of the shell itself, bash, because -f is functionality that the shell provides, it's a bash built-in. On my system (CentOS 7), the fine …