Action - Execute Command
The action Execute Command executes a shell command and stores the output in variables.
ls -lto list all files in the working directory
psto store the running processes in the defined variable
ps > file.txtto store the running processes in a file
cat file1.txt > file2.txtto copy a file
cat /proc/wakelocksto show the wake locks preventing your device from sleeping
You can use this for example to create a filename based on the current date:
ps > file-.
Special characters in the command have to be escaped using backslash or placed in quotes as appropriate:
cat 'Test File1.txt' > 'Test File2.txt'
cat Test\ File1.txt > Test\ File2.txt
/bin/shto be interpreted. The available commands vary from device to device. Variables are supported.
See action Script for a description.