Filter by tags:
265 cards matching
Showing cards 1-20 of 265
Front
execute the string str as a command
Front
"everything except file1"
Front
how do you redirect to standard error?
Front
How do you make your script clean up itself after it receives a termination signal?
Back
create a clean_up() function that cleans things up, and write at the beginning of the program:
trap clean_up SIGNALS TO INTERCEPT
(e.g. trap clean_up SIGHUP SIGINT SIGTERM)
Front
What does (command) mean?
Back
command is run in a subshell. Variable declarations and directory changes won't persist in the current shell.
Front
run a command in a subshell
Front
find: execute command1 and command2
Back
find ... -exec command1 \; -exec command2 \;
Front
given variable string, with spaces, retrieve its first word
Back
echo $string | awk '{print $1;}'
Front
for i in ...; do
iterate over range [1, 100]
Front
for i in ...; do
iterate over range [100, 1] (decreasing)
Front
difference between chmod and chown
Back
chmod: changes the permission for user, group, other
chown: changes who is the user and the group
Front
what happens to errors in scripts by default?
Back
here document. Used like this:
<< UNIQUE
...
UNIQUE
Back
here string.
command <<< string
is equivalent to
echo string | command
Front
difference between << and <<<
Back
<< begins a here document (multi-line, unique token)
<<< begins a here string (one line)
Front
reuse the last command in current command
Back
!! (then space or tab to expand)
Front
show all environment variables
Back
redirect both stdout and stderr
Front
loop over a range (e.g. a-z)
Showing cards 1-20 of 265