Live data from Hacker News

Love Your Terminal

blog.andrewhays.net

101–110 of 137 posts

Re: Love Your Terminal

#101

I typically SSH into my boxes, but it isn't really a shell - you don't have dynamic fonts/colors per application and stuck to 256 colors. Maybe I will have to run a linux distro in order to share the love.

Actually, applications can control colors in the same way over SSH as they can on a local distro.

Re: Love Your Terminal

#102
post #76

I wrote a little script to display the battery status (in a nice format) that should work on Bash & ZSH. I use it on my Tmux bar too... Check it out :) https://github.com/Goles/Battery

Would have loved it, if worked on linux too.

You can always pull request on it.

Linux support is on the roadmap, I would need some beta-testers though

Re: Love Your Terminal

#103

I typically SSH into my boxes, but it isn't really a shell - you don't have dynamic fonts/colors per application and stuck to 256 colors. Maybe I will have to run a linux distro in order to share the love.

Actually, applications can control colors in the same way over SSH as they can on a local distro.

So, would my SSH client just map the colors to the closest available one in its' palette?

I'm kind of naive - I figured every application run within command line (not terminal) was restricted to a specific 256 palette.

Re: Love Your Terminal

#104
post #65
post #56

Earlier quoted context omitted.

> So much junk in a prompt... I clicked on the link to Steve Losh's page and had a heck of a time figuring out what commands he had actually typed The point of configuring your prompt is it has to be easy for you to read. Whether someone else finds it readable or not is a non issue. Though not as verbose as Steve Losh's, I use a similar prompt which looks like this: rahul@mean-machine: ~/musings (git::master) ± $ The…

A whole extra line above the working prompt? That just seems unnecessary. If you need that info at any particular moment, make a command. I used to have one called wi (short for Where am I?) that threw out similar info. But displayed constantly? Yuck!

Everything is unnecessary. Some things are nice. Some of the nicest things are those which reduce cognitive load. Anything that makes it easier for my brain to "lex" the wall of text in front of my face is very nice indeed.

The fact that my prompt shows additional information is a secondary thing. (It's sometimes nice to scroll back through output and be able to see what directory I was in.) The _important_ thing is that the color and extra space make it exceedingly easy to visually chunk commands and output.

Re: Love Your Terminal

#106
post #61

YA post about making fancy prompts - at least its not about how to make a ssh tunnel ;-) Personally I'm never using anything, or adding any fancy setting, if it doesn't serve any direct purpose and/or is not clear, simple and efficient. It's not because I believe "simple" and "efficient" are "cool" or "better". It's just because it's always what made _me_ efficient. I don't lose much time digging configs either, and…

Yup. Everybody and their dog want fancy prompts with lots and lots of info, and I never understood why. Most of the time I don't need any information on my bloody prompt. I just need it to sit there and alert me if something is unusual, maybe, but not to get into my hair otherwise.

A couple of years ago I settled on one minimalist prompt, and I've used it ever since. I've even written my own post about fancy prompts[1] … I guess everybody has to have one!

[1] http://a-dimit.blogspot.de/2010/12/perfect-prompt.html

Re: Love Your Terminal

#107

Yet another article proclaiming bash as garbage and zsh as the best thing since sliced bread.

The biggest features I use from zsh is awesome tab completion. For example, partial tab completion:

    $ ls
    ./
    ../
    project-foo/
    project-bar/
    $ cd foo  ----> cd project-foo
Expand paths:

    $ cd /ho/wti/Drop  ----> cd /home/wting/Dropbox
Fuzzy matching:

    $ cd /tpm/blh  ----> cd /tmp/blah
Also expanding remote paths.

Re: Love Your Terminal

#108
I'm going to plug a small CLI program I maintain -- autojump: https://github.com/joelthelion/autojump/#name

It tracks which directories used most often so you can simply use `j ` to jump to that directory rather than type / tab-complete the full path name. It also does some fuzzy matching for mistyped names. For example:

    ~ $ j au
    ~/code/autojump $ j donw
    ~/Download $ j scra
    /scratch/03158/wting $

Re: Love Your Terminal

#109
post #65

Earlier quoted context omitted.

A whole extra line above the working prompt? That just seems unnecessary. If you need that info at any particular moment, make a command. I used to have one called wi (short for Where am I?) that threw out similar info. But displayed constantly? Yuck!

> A whole extra line above the working prompt? Because it's frequently useful, and thus the tradeoff of a bit of space for simplicity, speed and familiarity is worth it. > If you need that info at any particular moment, make a command. Right, so your prompt is composed of nothing but the hardcoded character `>`? (you obviously don't need the $/# toggle as you can use `whoami`, and you don't need the previous command'…

Setting your prompt to ";" can be useful, because then if you want to select a command with the mouse and paste it into another window, it's still valid even if you select the whole line--you don't have to worry about stopping at the prompt character, just triple-click the line (in X).

Re: Love Your Terminal

#110
post #92
post #24

Earlier quoted context omitted.

I used to take this approach. One day I found I had no choice but to remap CapsLock as a second Ctrl key because my little finger was in constant agony otherwise. I've never had a second's trouble from the finger since then, but you should see me try to type on other peoples' computers now. I TEND TO WRITE IN ALL-CAPS A LOT BY ACCIDENT! So for me there's no longer much point in caring about portability, and I have al…

I've run into the same issues. My solution is to reach a sort of balance between portability and usability. My xmodmap + XMonad config is designed to be reproducible on Windows via AutoHotkey and OS X via SizeUp + PCKeyboardHack, that way I'm always in my home environment no matter the OS!

How do you handle window-switching on OSX? I haven't found anything that satisfactorily reproduces the simple mod-j/k keys of xmonad.
Post reply on HN