3 ms·
Ask HN: What do you use to manage Terminal commands?
Hello good people of HN,
Started programming a bit recently and found myself having to copy paste bash commands into my Terminal to restart servers, databases, etc every time I close my Terminal window/restart my Mac. So I wanted to ask you - is there a tool that can automatically run my scripts?
Thanks a bunch!
- humbleMouse 11y agoI write scripts for things that I do a lot. The rest of the commands I used I keep in documents that are labeled and organized.
- wiml 11y agoA shell alias/function, a tiny shell script (which can also serve as documentation of the reasons for a procedure), or just finding the last invocation in my shell history with ^R.
- viraptor 11y agoIt sounds like you're using some specific commands to manage your services. I'd say that's not the best way to do it. Configure each of your services so they can be managed by `launchd`. Then all of those operations are reduced to `launchctl start/stop some_service`. Have a look at http://launchd.info/ http://launchd.info/ for some more information. Then if you don't want to type the line, you can probably get it from your history by using ctrl-r and typing the service name.