Live data from Hacker News

Ask HN: Best Command-Line Applications?

news.ycombinator.com

341–350 of 393 posts

Re: Ask HN: Best Command-Line Applications?

#341

byobu ( http://byobu.co/ ) is an amazing thing to have on your remote server, sessions and switchable windows + splits make this a must-have tool. Think of it as tabs but for your SSH session, plus many more features.

People might be more familiar if you would describe it as a t-mux alternative.

Just a quick note on this - byobu isn't a tmux alternative exactly. It actually uses tmux (or screen) on the back-end. So it's more like a nicely configured tmux.conf/.screenrc with standardized bindings.

Re: Ask HN: Best Command-Line Applications?

#342
post #188

Some great contributions here ... some that are missing (or at least scarce) which deserve more attention: units - for a broad range of conversions without having to resort to Wolfram Alpha or a search engine bc -l - the -l option really empowers this awesome little calculator. mpv - awesome media player - point it at a media URL (it uses youtube-dl in the background, so perfect for viewing or listening with no ads,)…

>Some great contributions here ...

Agreed.

>bc -l - the -l option really empowers this awesome little calculator.

Right. Since bc is a Unix filter, you can also pipe expressions into it, to be evaluated, so it can be used in general Unix pipelines. E.g.:

  echo *arithmetic_expression* | bc -l
and the output comes on stdout, so it can be further piped.

Edit: You have to quote any shell special characters in arithmetic_expression with single quotes, or better, just enclose the entire arithmetic_expression in single quotes. If asterisk (for multiplication) is not quoted, for example, it will be treated as a filename wildcard instead, and likely lead to an error. A wrong and a right example:

  $ echo 2 + 3 * 4 | bc -l
  (standard_in) 1: syntax error

  $ echo '2 + 3 * 4' | bc -l
  14

Re: Ask HN: Best Command-Line Applications?

#343

I'm a cli junkie but I've gone from using very minimal tiling WMs to vanilla Gnome. So I've stopped using bitlbee for example, but bitlbee is something I'd use a lot in the days of 100% terminal. It's an IRC proxy for other protocols like Skype or Slack. I have no idea how it stands up today but I always liked the concept of having one service that handled conversion of all the modern protocols to text based. Other t…

Curious what made you leave tiling WMs? I think about switching back occasionally, but still use dwm. I also used to use bitlbee, but once AIM died I dropped it. Slack dropped their irc gateway a while ago. I recommend wee-slack[1] which is a weechat[2] python plugin that uses the Slack API instead of the old IRC gateway, which also means it is a lot more feature rich than the IRC gateway was. 1 - https://github.com/…

My focus has always been on being able to work without issue. Without OS locking up or without tools malfunctioning.

Used to have laptops with 256MB RAM for example, or 1024x768 pixel resolution. So I'd do anything to cram as much as possible into a tiny screen using as little resources as possible.

Now my laptop has 8G of RAM and an i7 CPU at 2.5GHz and 4 virtual cores. On top of that Linux and Gnome have made a lot of advances so it runs like a dream and I can work without having ~100 lines of configuration in my WM.

More seamlessly go from my own to someone elses computer without forgetting that caps lock is my Meta key. It all pretty much resembles Windows and Mac OS more.

I just don't see any purpose with torturing myself using a minimal resource desktop environment when I don't have to.

The main program is still gnome-terminal and tmux, I still do a majority of my work there. Habitually use cli for as much as possible, even simple operations that I could do in the Gnome file browser.

But I do it all with a vanilla Gnome configuration and I still don't miss a thing.

Re: Ask HN: Best Command-Line Applications?

#345
post #16

httpie + jq is a great duo for exploring and manually probing APIs. Gron (grep JSON) is handy when you get a massive API response and quickly need to figure out what subkeys interest you. The silver searcher (ag) is my go-to code search tool. I'll have to try ripgrep to compare. Pass is neat for injecting personal secrets into bash scripts securely.

Here's a feature comparison chart of the various grepalike tools:

https://beyondgrep.com/feature-comparison/

Re: Ask HN: Best Command-Line Applications?

#346
Various grepalike tools like ack, ag and rg have been mentioned. Most comments seem to be based on which tool runs simple searches faster, but note that their feature sets vary widely.

Here's a handy chart that compares the features of each of these tools, along with git grep and plain ol' GNU grep.

https://beyondgrep.com/feature-comparison/

Re: Ask HN: Best Command-Line Applications?

#347
post #23

rg (ripgrep): https://github.com/BurntSushi/ripgrep I used to use ag (the silver searcher) [1] before, and `ag` was practically a muscle memory to me, but then I came across ripgrep and it was so much faster. I've now installed a static binary of ripgrep in every machine I have SSH access to. [1] https://github.com/ggreer/the_silver_searcher

Note that rg and ag don't have the same feature sets. Here's a handy chart that shows the differences.

https://beyondgrep.com/feature-comparison/

Re: Ask HN: Best Command-Line Applications?

#348
post #312

Earlier quoted context omitted.

> what matters for most is the fact that i can run the application in a text only terminal, on any machine (remote or local), from any device (be it linux, windows, mac or even a mobile phone (ok, that's rarely practical, but it's possible)) > a GUI does not offer that advantage Sure, not in the terminal, but X forwarding is a thing and works on every system I've had to use it on.

it doesn't work on the majority of systems i have to work with, which is servers that don't have the necessary tools installed. it's also very susceptible to latency and most applications don't handle slow connections in a usable manner. (they are designed with the expectation that the gui always responds instantly) to get something of a tmux/screen like experience, xpra is available, which is an awesome piece of wor…

Oh, I never said I _enjoyed_ X forwarding, or even use it frequently. My point was just that remote access in a similar way to a shell is possible with a GUI, and could be made even better if X had a means of not having to draw everything but left it up to the toolkit on the other end.

But yes, in general, a shell is just much better:)

Re: Ask HN: Best Command-Line Applications?

#349
post #242

Earlier quoted context omitted.

Um; I feel it's kinda as if you asked if a dog is like rhinoceros... How do I even answer that? Simplest answer is: "no, it's not"; though if you squint your eyes super hard, you could see some kind of vague resemblance, maybe? Have you seen the readme? There's an animated gif showing how it works, and a more detailed description.

Yeah, have you seen the readme? > interactively and incrementally explore textual data Just like less. > This is achieved by boosting any typical Linux text-processing utils such as grep, sort, cut, paste, awk, wc, perl, etc., etc., by providing a quick, interactive, scrollable preview of their results. Yep, that's less. > use PgUp/PgDn and Ctrl-[←]/Ctrl-[→] for basic browsing through the command output; Sure that's…

Ahahah, lol, ok, get it :D So, apparently I totally reinvented less, I concede :)

To say even more, it's actually very much a crippled less (not all of its functions available!). With just one feature added, namely:

> in the input box at the top of the screen, start writing any bash pipeline; then press Enter to execute the command you typed, and the Ultimate Plumber will immediately show you the output of the pipeline in the scrollable window.

At least for me personally, it was painfully worth reimplementing the crippled less functionalities for this single little addition. Though I do admit I felt the lack of the slash-to-search feature of less already yesterday when using up...

And, to explain myself a bit, I really tried my best at explaining the tool in the readme... it's just that I can't currently think of any better wording :( If by any chance you had some idea/suggestion how you think I could improve it, I'd be super eager to hear it! I'm kinda too deep in the trenches to be able to look at it from a distance, so even seemingly obvious (to you) comments (as the one with the comparison to less, after you explained it) are sincerely valuable to me!

Post reply on HN