Workflow to quickly open projects using Alfred
There are times when I'm working on 5-6 projects at a time and I want to be able to quickly open a new one up. I also love Alfred and so set out to make this.
- Set your IDE and working directory by writing
proj setand the top options will drop down:
- Right now the only two IDEs that I know that will work are Sublime & Macvim. If you are using Sublime you should have set a symlink so as seen here so the shortcut will be "subl"
- The IDE should by typed in "Macvim" or "Sublime"
- This must be done first. It defaults to "Sites" for a directory and "Macvim" for an IDE
- Initiate with
- Shows you which projects are located in the directory that you specified
- You can optionally set what part of the project you want to launch. For example
proj Sites assetswill then launch in your IDE the assets folder. You could also use
- Scroll down to select a project to launch
- It will then launch that project in your IDE and cd to that project in the terminal, run a git status for you, and open the Github app for that repository. Note: Install "Command Lines Tools" on the Github app if you want this to work.
If you use MAMP it will also look up the domain of the project and open it in the browser
If you want to open a project only in your IDE of choice, initiate with
idewhich will bring up your projects and selecting one will then quickly open it in your IDE.
- No arguments are accepted for this option
Heavily influnced by gharlan / alfred-github-workflow