Desk: A lightweight workspace manager for the shell
github.com
github.com
From what I can tell, though, desk's design allows for slightly different uses: namely (because desk consolidates configuration into one directory), desk configuration is more easily shareable across computers. In order to recreate your direnv setup on another machine, you'd have to go and symlink all your direnv files manually (unless they're somehow embedded in the repos or folders you're working in).
Direnv doesn't (AFAICT) attempt to surface documentation for the shell files it executes, whereas a lot of desk's value is in displaying a quick reference for common tasks within a workspace.
. path/to/ez_lisp.sh
----------------------
or use an alias like:
desk() {
. path/to/$1
}I'm a newb. So sorry if this is just over my head.
In the nearterm I'm going to be working on supporting imports -- i.e., you `git clone` down a project that has a deskfile at its root, then you're able to import it (maybe as a fancy symlink) into your own deskfiles. That'd give you immediate, programmtic context for working on the project.
"I have a hard time calling this a "workspace manager" with a straight face -- it's basically just a shell script that sources another shell script in a new shell."
Please, to save your own time and energy (if not the time and energy of other people) search for a solution before you build one. Only if you have found the two or three solutions that the community likes most and you are still unsatisfied, only then start coding. And set yourself a real goal about what your tool should be doing that the others don't.
In this example tmux is quite interesting. Screen was around for ages. But a few things were not possible with the screen code base, like splitting your screen in whatever way you want. And some things simply were not really user friendly, like the config. With this in mind a guy named Nicholas Marriott sat down and started coding his alternative.
That's how you do it. Stick his picture on your wall. Follow his path. Start with googling for your problem, not with coding.
PS: I think the idea of having different desktops in graphical shells in fact came from people wanting to have the terminal multiplexing feature in their graphical environment as well. So Desk is like taking your calculator apart to develop a method to calculate with pen and paper.
That's great. But even if you don't, the beauty is that the code is out there now.
> Only if you have found the two or three solutions that the community likes most and you are still unsatisfied, only then start coding.
Nah. I mean, sure, if it was for an actual business decision or for something that directly affects productivity workflow, due diligence is warranted.
But I'm never going to tell someone that they shouldn't have made something. Tell them there's something better, yes. Tell them that a different project does it in a more intuitive or robust way, certainly.
This nose-thumbing trend of not just ignoring code you don't like, but actively discouraging the release of code you might not approve of?
Yeah, no.
I hope no-one reading this thread gets the impression that most open-source software engineers would agree with this. That's one of the beauties of the ecosystem -- everyone can code and publish what they damn well want.
> I really want to support open source efforts. But I really can't if there's a project developed without any googling before the first line of code.
How is your "support" of open source software negatively impacted by this, as you perceive it, malpractice? It makes choice of OSS solutions harder for you?
Could you say the author didn't care about what he adds to the community? Sure you could. But then one had to wonder why he added his project to HN or wrote a Readme in the first place.
Wheb i boot up, i still have to ^R to cd to the right location, and then ^R again to "compile" etc.
I'm looking forward to trying this out, direnv (mentionned above) seems like an even better idea.
So first of all, I have a bash function declared in my bashrc which takes one argument -- the domain -- and sets a few evironment variables such as GIT_AUTHOR_EMAIL and GIT_COMMITER_EMAIL.
Next I have one two-letter alias and three three-letter aliases which all cd to their respective paths and call the function to set the env vars.
Finally, I have two-letter aliases to git add, git diff, git commit, git push and so on.
Dead simple and works great. All I need is my bashrc.
Hope you could learn something, because that's the reason I'm writing here.
Regardless, this solves a very different problem to screen/tmux and they don't compete in any way. In fact IMO both would work best when used together.
Does tmux improve over screen's `C-a S` / `C-a |` ?
Those two commands bisect one pane two either horizontally or vertically, and they can be called repeatedly.