Every day I do the following commands:
[0] Start terminal
memcached
redis-server
memcached
devo
cd /some/path
rails s --port=3002
cd /other/path
rails s --port=3000
Can these steps be accomplished in a single script? I'm losing my mind doing these steps every time I restart my system
Create an applescript. You will just need to run the applescript and it'll do all that for you :
tell application "Terminal"
activate
do script "memcached" in window 1
do script "redis-server" -- Each do script opens a new window
do script "memcached"
do script "devo"
do script "cd "
do script "rails s --port=3002" in window 1 -- does script in last opened window
do script "cd "
do script "rails s --port=3000" in window 1 -- does script in last opened window
end tell
Save it as an Application so you can double click it to run it. You could also assign it to start on system start or even to a shortcut with a necessary third party program.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With