Package: yakstack
A command-line utility to help you stack your yaks.Err… What?“Yak Shaving” is a common term in the tech industry. Asoriginally described:You see, yak shaving is what you are doing when you’re doing somestupid, fiddly little task that bears no obvious relationship to whatyou’re supposed to be working on, but yet a chain of twelve causalrelations links what you’re doing to the original meta-task.In other words, Yak Shaving is the series of distractions and/or necessary tasks you find yourself doing while you weremeantto be doing something else. Each progressive step is logical, but when you end up doing something completely different from what you intended, it’s easy to lose track of how you got there. When you realise you’re getting further and further away from the primary task, you’re yak shaving.This phenomenon is so common that it has become the source of meta-jokes about stacks of yaks (where one instance of yak shaving isn’t enough), and more detailed involvement (“I’m not just shaving the yak, I’m grooming it as well”).This script helps you keep track of your “yak frames”, or context switches. Got distracted from a task? Add it to the yak stack. Got distracted from the new task? Also add it to the yak stack. Once you’ve finished, shave the yak and go back to the previous task. Originally inspired by this usage of the term:yak frame - n. a yak shaving stack frame. ex: “I’m currently 3-4 yak frames deep”— Charlie Somerville (@charliesome)August 19, 2013(archived version)yakstackis not a todo list, or a task management solution. It’s simply a way to keep track of your context switches, so you don’t end up thinking “what was I meant to be doing again?”Installationyakstackrequires Python withpip:pipinstallyakstackPython 2.7 and 3+ are supported.UsageOn first usage,yakstackwill have an empty yak stack. You have no tasks in the list.$yakstackNoyakstoshaverightnow!Adding yak framesAny arguments toyakstackare added as frames on your yak stack.$yakstack"Work on super-important project"Youarecurrently1yakframedeepWorkonsuper-importantproject$yakstack"Show yak script to a colleague"Youarecurrently2yakframesdeepWorkonsuper-importantproject⤷ShowyakscripttoacolleagueYou can add multiple yak frames in one command.$yakstack"Write a README for yakstack""Argument on Twitter"Youarecurrently4yakframesdeepWorkonsuper-importantproject⤷Showyakscripttoacolleague⤷WriteaREADMEforyakstack⤷ArgumentonTwitterRemoving yak framesToremovean item from the stack, use the--shave(or-s) option.$yakstack--shaveYouarecurrently3yakframesdeepWorkonsuper-importantproject⤷Showyakscripttoacolleague⤷WriteaREADMEforyakstack# THIS ALSO WORKS$yakstack-sYou can also remove multiple yak frames in one command. Use multiple--shaveor-soptions.$yakstack--shave--shaveYouarecurrently1yakframedeepWorkonsuper-importantproject# THIS ALSO WORKS$yakstack-ssManaging multiple yak stacksSometimes you might have different yak stacks running at the same time, to track distractions from different projects. Perhaps you want to track things separately for your personal projects when you’re not at work.To switch to a different profile, use the--profile(or-p) option with a profile name. Once you have more than one profile,yakstackwill always tell you which profile you’re using.$yakstackYouarecurrently1yakframedeepWriteREADMEforyakstack$yakstack--profileworkNoyakstoshaverightnowforprofile"work"!The default profile used byyakstackis called, unsurprisingly, “default”.You can switch profiles while adding new yak frames.$yakstack-pdefault"Find out latest sports scores"Youarecurrently2yakframesdeepforprofile"default"WriteREADMEforyakstack⤷FindoutlatestsportsscoresOther notesThe arguments toyakstackfollow standard Unix command-line patterns. This means that space characters separate multiple arguments (and therefore multiple yak frames). To add a sentence containing spaces to your yak stack it must be surrounded by quotes.# With quotes$yakstack'A single sentence with quotes'"And another one"Youarecurrently2yakframesdeepAsinglesentencewithquotes⤷Andanotherone# Without quotes$yakstackThisaddsawholebunchofframesYouarecurrently9yakframesdeepAsinglesentencewithquotes⤷Andanotherone⤷This⤷adds⤷a⤷whole⤷bunch⤷of⤷framesOh, and one more thing:$yakstack--saxYou’re welcome.