

This can be changed as needed, and I can also change the make directory as needed. I can move around at will in vim or MacVim, run any number of them, and “,m” will run “make”.īy temporarily setting a value in the “MAKING” shell variable, I can alter the make target. So all I have to do is leave that terminal window open – set to the proper directory. it will receive this command line: clear date make $MAKING.there needs to be a “Terminal” app running, with a window named “⌘1” open.“ m“) initiates a make, without leaving my vim context The following is what I came up with, and it works really well for me: Using as few “moving parts” as possible, because the more components take part in these custom automation tricks, the sooner they’ll break. But that’s not optimal: you need to have tmux running locally, you need to type in the session, window, and pane to send the make command to (once after every vim restart), and things … break at times (occasional long delays, wrong tmux pane, etc). For quite some time, I’ve used the Vim Tmux Navigator for this.


So I have a keyboard shortcut in vim which saves all the changes and runs make in a shell window. It may not be everyone’s favourite, but I keep coming back to vim as my editor of choice, or more specifically the GUI-aware MacVim (when I’m not working on some Linux system).Īnd some tasks need to be really fast. Anything related to editing, building, testing, uploading – if I can shave off a little time, or better still, find a way to automate more and get tasks into my muscle memory, I’m game. I’m regularly on the lookout for ways to optimise my software development workflow.
