Download raw body.
[rfc] stash command in got
On Fri, Jun 17, 2022 at 01:38:33AM +1000, Mark Jamsek wrote: > You've given me something to think about. At present, the best I can > come up with is that stash is a convenient, quick context-switch for > small tasks. 'got stash' and 'got stash pop' is pretty convenient. But, > you're right, there is a workaround; however, till I try it, I don't > know that it would be as quick and simple. Whether that convenience is > worth the code cost is another question. If we were to implement a stash feature, it would be reasonable to build the implementation as syntactic sugar on top of the features we already have. I believe all the building blocks are already there. The next trade-off would then be if this should be a wrapper script, (fewer lines of code, won't add any maintenance cost to the C code base), or a new command in got.c (more lines of code, adds maintenance cost). If the scripted approach turns out to be really simple in practice, perhaps we could even just add a section to the EXAMPLES section of the man page which explains how the concept of stashing changes can be made to work with the existing commands. This might be best in order to help people improve their skillset in using the tool most effectively. Adding too much abstractions and syntactic sugar could end up obfuscating the basics.
[rfc] stash command in got