20 votes

Ars Asks: Share your shell and show us your tricked-out terminals

13 comments

  1. rustbucket
    (edited )
    Link
    Extensive shell customization is just one of those things I never really got into. (Its a little funny considering how much time I used to spend configuring Fluxbox in the past) All I have is a...

    Extensive shell customization is just one of those things I never really got into. (Its a little funny considering how much time I used to spend configuring Fluxbox in the past) All I have is a simple prompt that shows the user, hostname, and working directory. The prompt also turns red if the user is root. I guess the only somewhat unique thing about it is I use ksh 93u+m as my shell.

    In regards to terminal emulators, I'm similar to the author. I just stick with what works, in my case that would be xterm.

    11 votes
  2. [2]
    dutchwitch
    Link
    I use the Fish Shell and call it a day. Works well for my use case.

    I use the Fish Shell and call it a day. Works well for my use case.

    10 votes
    1. shrike
      Link Parent
      Fish + Starship is pretty a pretty doable baseline as-is.

      Fish + Starship is pretty a pretty doable baseline as-is.

      4 votes
  3. Boojum
    Link
    I use Zshell, but keep it pretty simple with a .zshrc that's about 100 lines and doesn't use any frameworks. About half of my .zshrc lines are just aliases or little functions. Perhaps the most...

    I use Zshell, but keep it pretty simple with a .zshrc that's about 100 lines and doesn't use any frameworks. About half of my .zshrc lines are just aliases or little functions.

    Perhaps the most interesting things:
    REPORTTIME=3
    

    I love this one so much. If a process takes longer than 3 seconds of CPU time, Zsh automatically reports the total times, much as though I'd prepended the command with time. But I don't have to pre-emptively prepend it, and it's omitted for short tasks.

    PROMPT="%B%F{8}[%D{%-l:%M}]%f%n@%m:%~%(?.%F{green}.%F{red})%#%f%b "
    

    Basically just [h:mm]user@host:dir% with some coloration. The user, host, and dir are listed scp-style to make it easy to copy and paste for scp commands. Time of day (de-emphasized with dimmer grey) so that I know when the command was run or the shell was last used when I have many of them. And the % at the end flips between green and red based on the exit status of the previous command. No fancy multi-line monstrosities, no Git status checks, no shelling out to some program that generates the prompt elements dynamically.

    setopt auto_cd
    setopt auto_pushd
    setopt pushd_ignore_dups
    setopt complete_in_word
    setopt glob_complete
    setopt no_case_glob
    setopt list_packed
    setopt list_rows_first
    setopt extended_glob
    setopt no_no_match
    setopt hist_fcntl_lock
    setopt hist_ignore_all_dups
    setopt hist_ignore_space
    setopt hist_reduce_blanks
    setopt hist_save_no_dups
    setopt share_history
    setopt correct
    setopt emacs
    

    My favorite here has got to be auto_pushd. It effectively turns every cd into a pushd, so I can just popd back up the stack as I navigate around.

    source /usr/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
    

    My most recent addition. I wasn't sure how I was going to like this at first. I had concerns that it might be too tacky or that it might hurt performance. But I haven't noticed any performance hit, and I've come to really like it. Commands are green if they are valid and bold red if not, valid paths are underlined, quoted strings are yellow, globs are blue.

    6 votes
  4. kovboydan
    Link
    I can’t remember life before oh-my-zsh/9k. I know I wasted countless hours, but I can’t remember why it was so important to me.

    I can’t remember life before oh-my-zsh/9k. I know I wasted countless hours, but I can’t remember why it was so important to me.

    5 votes
  5. arqalite
    Link
    I'm a default Bash and PowerShell guy. I always like the idea of customizing my shell, but none of the changes ever stick, so I stopped bothering over time. Defaults are also sufficiently...

    I'm a default Bash and PowerShell guy. I always like the idea of customizing my shell, but none of the changes ever stick, so I stopped bothering over time.

    Defaults are also sufficiently productive for my needs and I've felt like the gains from configuring stuff are never worth the effort, but that is my personal experience.

    5 votes
  6. [2]
    vord
    Link
    My terminal config itself is pretty boring these days, esp since I use drop-down no-frills ones now. Cool Retro Term is really fun though, and if you find yourself having to have 4-8 different...

    My terminal config itself is pretty boring these days, esp since I use drop-down no-frills ones now.

    Cool Retro Term is really fun though, and if you find yourself having to have 4-8 different windows open to different hosts, is a great way to distinguish between them without needing to futz. IIRC, it's GPU accelerated too, so it's pretty snappy.

    4 votes
    1. mxuribe
      Link Parent
      I LOVE Cool Retro Term! I don't use it as much as I did in the past (mostly due to laziness in installing and configuring it when i nuke and pave my machines)...but still have much love for it!

      I LOVE Cool Retro Term! I don't use it as much as I did in the past (mostly due to laziness in installing and configuring it when i nuke and pave my machines)...but still have much love for it!

      2 votes
  7. [4]
    Eji1700
    Link
    My "general" setup, which is not as complex as it looks is: Terminal if on windows Shell is Nushell Editor is Helix (or vs code) and then the main supporting tools are Zoxide, for darting around...

    My "general" setup, which is not as complex as it looks is:

    Terminal if on windows
    Shell is Nushell
    Editor is Helix (or vs code)

    and then the main supporting tools are
    Zoxide, for darting around directories
    Yazi, for much the same and mass file manipulation. Plus all the recommended installs for yazi that come with that
    Lazygit for easy git management in a pane

    My only issues so far have been:

    1. Figuring out if I can take the output of a zoxide search and just pipe it to a command. For example rather than code <path to file> i'd love code z <keyword for file>. I assume this is possible but I haven't looked.

    2. Yazi just does not have an easy way to use it on ubuntu, which is wild to me? I don't know if there's some other tool people are using but i've kinda got it working but still have all sorts of fonts/characters that don't show right.

    2 votes
    1. [2]
      Boojum
      Link Parent
      I'm not familiar with zoxide, but it looks like it takes a -l to output a list of matches. So then backticks or $(command) substitution? I.e., something like: code `z -l <keyword for file>` code...

      I'm not familiar with zoxide, but it looks like it takes a -l to output a list of matches. So then backticks or $(command) substitution? I.e., something like:

      code `z -l <keyword for file>`
      code $(z -l <keyword for file>)
      

      But in general, backticks or the $() syntax are your friend here.

      2 votes
      1. golk
        Link Parent
        Not too far off. zoxide query -l <pattern> work here. If you want an interactive session, zoxide query -i <pattern> do the work.

        Not too far off. zoxide query -l <pattern> work here.
        If you want an interactive session, zoxide query -i <pattern> do the work.

    2. mantrid
      Link Parent
      You can use a handy alias: nu alias zq = zoxide query code (zq myproj) zq myproj | code $in code (zq -i) Note that z query does not work. You need zoxide query. You can also set it up an alias for...

      You can use a handy alias:

      nu
      alias zq = zoxide query
      code (zq myproj)
      zq myproj | code $in
      code (zq -i)
      

      Note that z query does not work. You need zoxide query. You can also set it up an alias for an interactive query: alias zqi = zoxide query -i

      Then just save the alias(es) you want in config.nu.

      1 vote
  8. mxuribe
    Link
    I really like playing with the themes, look-and-feel, and custom prompts of the shell/terminal...but i discovered that it blocks me from getting stuff done. So, i tend to use some very minimal...

    I really like playing with the themes, look-and-feel, and custom prompts of the shell/terminal...but i discovered that it blocks me from getting stuff done. So, i tend to use some very minimal prompt customizations, and store them in my .bashrc, and call it a day. When i really, really feel like changing my theme/look-and-feel, i use the available themes in konsole, and then swap between them every few months...but don't get too hung up on things anymore, and don;'t spend time implementing them permanently in my .bashrc file.

    I have to keep reminding myself that life is too short to fiddle around with "customization p0rn"! :-D

    1 vote