my_storm() {
bash $HOME/WebStorm-162.1812.21/bin/webstorm.sh &!
}
alias my_storm="bash $HOME/WebStorm-162.1812.21/bin/webstorm.sh &!"
With GNU or FreeBSD find, you can use the -quit predicate:find . ... -print -quit
The NetBSD find equivalent:find . ... -print -exit
VAR=$(cat <<'END_HEREDOC'
abc'asdf"
$(dont-execute-this)
foo"bar"''
END_HEREDOC
)
echo "$VAR"
SYNOPSIS
checkproc [-v] [-L] [-k] [-p pid_file] [-c root] [-z]
/full/path/to/executable
checkproc [-v] [-k] [-n] name_of_kernel_thread
pidofproc [-k] basename_of_executable
DESCRIPTION
checkproc checks for running processes that use the speci
fied executable.
`which ${PROCESS_NAME}`
killall -15 ${PROCESS_NAME}
sleep 1
pgrep ${PROCESS_NAME} && { echo "what a pain"; killall -9 ${PROCESS_NAME} }
#!/bin/bash
# отправить в бекграунд
source /path/to/sub_script.sh &
# отправить в бекграунд и отвязаться от текущей консоли
source /path/to/sub_script.sh &!
# man exec
exec /path/to/sub_script.sh
# man nohup
nohup /path/to/sub_script.sh
# cat << EOF | nohup sh
# cat << EOF | exec sh
# cat << EOF | sh &!
cat << EOF | sh &
# content of my sub_script.sh
echo `date` > /tmp/123
EOF
# замечание
# sh != bash
# если у тебя скрипт оттестирован на баше, то делай cat << EOF | nohup bash
cat << EOF | psql ---params
BEGIN;
`pg_dump ----something`
update table .... statement ...;
END;
EOF
stackoverflow.com/questions/2500436/how-does-cat-e... setxkbmap -option 'caps:escape,caps:shift_nocancel' -layout us
Ctrl key position
┌───────────────────────────────────────────────────────────────────────────────────┐
│Option Description │
├───────────────────────────────────────────────────────────────────────────────────┤
│ctrl:nocaps Caps Lock as Ctrl │
│ctrl:lctrl_meta Left Ctrl as Meta │
│ctrl:swapcaps Swap Ctrl and Caps Lock │
│ctrl:ac_ctrl At left of 'A' │
│ctrl:aa_ctrl At bottom left │
│ctrl:rctrl_ralt Right Ctrl as Right Alt │
│ctrl:menu_rctrl Menu as Right Ctrl │
│ctrl:ctrl_ralt Right Alt as Right Ctrl │
│ctrl:swap_lalt_lctl Swap Left Alt key with Left Ctrl key │
│ctrl:swap_lwin_lctl Swap Left Win key with Left Ctrl key │
│ctrl:swap_rwin_rctl Swap Right Win key with Right Ctrl key │
│ctrl:swap_lalt_lctl_lwin Left Alt as Ctrl, Left Ctrl as Win, Left Win as Alt │
│ │
└───────────────────────────────────────────────────────────────────────────────────┘