4 ms·
You should do a screencast of such infinitely useful classics as tac, tsort, and sl. (Actually, I have found use for those first two on occasion. ;)
by jlgreco 13y ago
You should do a screencast of such infinitely useful classics as tac, tsort, and sl.
(Actually, I have found use for those first two on occasion. ;)
- WestCoastJustin 13y agoThanks for the suggestion! Actually, I initially wanted to do one on more advanced commands, but I thought I'd better lay a foundation first. I also want to cover using pipe (|) to chain these commands together. I'll make sure to include these.
- nileshtrivedi 13y agoDon't miss xargs.
- jfb 13y agotsort is one of my favorites, mostly because it's totally pointless until you need it and then it works exactly right. I love it.
- sambeau 13y agoWow. I just read the man page for tsort and I am none the wiser. tsort takes a list of pairs of node names representing directed arcs in a graph and prints the nodes in topologi-cal order on standard output. It's not often I understand nothing on a man page. But this time, I'm stumped!
- tod222 13y agohttp://en.wikipedia.org/wiki/Topological_sorting http://en.wikipedia.org/wiki/Topological_sorting
- jfb 13y agoSay you have a set of tasks you need to do, and some of those depend on others. Now, you want to perform those tasks in order. The question then becomes: in which order? That's the problem that tsort (1) solves. It's a way to do some of what make does without having to write a Makefile. 99.9% of the time, it never comes up, but when it does, it is very, very handy to be able to this in a shell pipeline. HTH.
- Nick_C 13y agoMe too. Then I read the info, it gives an interesting historical perspective of why tsort came about. On a system with GNU utils installed: info coreutils 'tsort invocation'