1

How can I run several commands in succession when a key is pressed? For example,

"Command 1"
"Command 2"
"Command 3"
   Hotkey

Doesn't seem to work.

George
  • 1,809

1 Answers1

6

Associate a single command which runs the three commands successively. The command is always executed via a shell (specifically, via /bin/sh).

"Command 1; Command 2; Command 3"
  Control+F42
  • 1
    && can be used as well if the following command depends on the previous one to run (conditional succession) - it is the logical AND operator - if the first results in true the second runs, else not –  Dec 30 '17 at 18:30