3 ms·
The CLI lets me find the file once and pass it between things pretty much endlessly A magic var: "$_" I made another post in this thread about it... I'm tired
by bravetraveler 3y ago
The CLI lets me find the file once and pass it between things pretty much endlessly
A magic var: "$_"
I made another post in this thread about it... I'm tired/on mobile, so apologies if I'm terse.
tldr: get in the habit of arranging the file to be the last argument. Subsequent use is entirely free
Or, really, anything you want to pass around. Not just files.
- eternityforest 3y agoThat's pretty cool actually, never heard of that one before! Seems more suited for smaller projects than larger ones, usually I'm always jumping between HTML template, server code, JS, browser, and some badly documented library I suspect is buggy. I don't often do multiple different things in a row to one file, but for those times I do this will probably double or triple my speed. Thanks for making us all aware of it!
- bravetraveler 3y agoHappy to share! This sequence is more regular with multiplexed terminals - one window, many panes. Many people like 'tmux'. I ended up stuck with my terminal handling it (Kitty)... I learned this way first. Anyway, if I'm iterating a lot on something, I end up using two or three panes at least. One pane as the ringer/wildcard while others are more static - an editor, the interpreter, etc. Reserving the 'ringer' pane protects that last argument for quick use. This reservation is aided by having the other static panes for my editor and such