Reprinted please indicate the source: http://blog.csdn.net/horkychen
In addition to the Apple Script, Mac OS also provides a simpler automation tool, automatic or, which can be used properly to improve work efficiency.
The following is a simple example. For example, if you want to run the android simulator on Mac OS and do not want to use AVD to select another one, but want to directly run the simulator you want, you can execute it on the command line:
Emulator-AVDAvd_name
I am too lazy and don't want to open AVD or terminal and execute it again. Instead, I want to run it directly from the dock. The solution is in Automator.
1. Open Automator and select workflow:
2. Create a new run shell command and set the shell and specific commands:
3. Save as application.
The command has just been packaged into an application.
4. Drag it to the dock and execute it later.
In another case, I always need to execute a test script, but I need to specify a target directory. You only need to select "Pass input: as arguments" on the command settings. You can simply accept the parameters using the common shell script as follows:
During use, you can drag the directory to be tested to the new program.
Well, that's all! You should be able to do better!
* Put the programs set up by Automator in a unified manner, which makes it easier to call!
Refer:
List of software used in development
Lazy users can use automation to improve work efficiency.
Simplify work with scripts
Programmers must learn to be lazy-correct use of automation technology
How to use search techniques to become an efficient programmer