You are not logged in.

#1 2009-01-03 10:10:19

ArchArael
Member
Registered: 2005-06-14
Posts: 504

alternative shells: fish, hotwire, rush ecc

A topic for CLI lovers. wink

I just assume that major part of us are using bash and zsh and was wondering about the minority of alternative shells users.

I know that many alternative shells are not as flexible as standard shells but some of them are pretty good. So my questions are:

Do you use any alternative shell? (for instance not bash or zsh)

What do you think about them?

Could any other shell substitute your bash or zsh and if not what are they missing?

Did you tried hard or you just dropped the alternatives because of your habits?

Thank you for all answers and considerations. smile

Last edited by ArchArael (2009-01-03 20:48:19)

Offline

#2 2009-01-03 12:25:57

badboy
Member
Registered: 2009-01-02
Posts: 32

Re: alternative shells: fish, hotwire, rush ecc

I have rush, the ruby shell, installed.
From time to time I use it to replace code in multiple files or to rename/move them. It's perfect for this, because it uses pure ruby syntax.
But bash is my primary shell.
I think it's the best to use the power of both.

Offline

#3 2009-01-03 19:55:10

cardinals_fan
Member
From: /dev/null
Registered: 2008-02-03
Posts: 248

Re: alternative shells: fish, hotwire, rush ecc

I just use Zsh.  Rush sounds [very] interesting though...


Segmentation fault (core dumped)

Offline

#4 2009-01-03 20:50:35

ArchArael
Member
Registered: 2005-06-14
Posts: 504

Re: alternative shells: fish, hotwire, rush ecc

cardinals_fan wrote:

I just use Zsh.  Rush sounds [very] interesting though...

Ok...what makes zsh better than bash in your opinion? It's just the tab completion or there is something else?

badboy...how do you deal with interactive rush use? I found it quite basic...no tab completion for example.

Last edited by ArchArael (2009-01-03 21:01:04)

Offline

#5 2009-01-03 20:53:03

andre.ramaciotti
Member
From: Brazil
Registered: 2007-04-06
Posts: 649

Re: alternative shells: fish, hotwire, rush ecc

Hotwire seems to be nice, too. I'll take a better look at it.


(lambda ())

Offline

#6 2009-01-03 21:07:42

ArchArael
Member
Registered: 2005-06-14
Posts: 504

Re: alternative shells: fish, hotwire, rush ecc

andre.ramaciotti wrote:

Hotwire seems to be nice, too. I'll take a better look at it.

Yes it's really interesting. What I missed is a keyboard shortcut for command line focus.
If you give the focus to some other widget and you want to go back to the command line widget you have to use tab or you have to click with mouse.
I searched in the official documentation but it seems to me that there isn't such combination.

Last edited by ArchArael (2009-01-03 21:08:13)

Offline

#7 2009-01-03 21:11:21

szymon_g
Member
Registered: 2008-11-24
Posts: 36

Re: alternative shells: fish, hotwire, rush ecc

ArchArael wrote:
cardinals_fan wrote:

I just use Zsh.  Rush sounds [very] interesting though...

Ok...what makes zsh better than bash in your opinion? It's just the tab completion or there is something else?

1. better completion
2. its lighter and faster than bash
3. it have got kind of mime-type recognition :~

btw, i'm not on arch at this moment, so i cant check it, - have much Arch is bash-addicted? is it possible to use other shell (i'm thinking about zsh) without need of rewriting half of all scripts?

Offline

#8 2009-01-03 21:25:09

fwojciec
Member
Registered: 2007-05-20
Posts: 1,411

Re: alternative shells: fish, hotwire, rush ecc

All official Arch scripts are written explicitly in bash:

$ cat /etc/rc.sysinit | head -1
#!/bin/bash

So you either need bash installed or a shell that's fully compatible with bash.
Also, /etc/profile has basic infrastructure to distinguish between different shells: http://repos.archlinux.org/viewvc.cgi/f … iew=markup

Last edited by fwojciec (2009-01-03 21:25:44)

Offline

#9 2009-01-03 21:26:55

ArchArael
Member
Registered: 2005-06-14
Posts: 504

Re: alternative shells: fish, hotwire, rush ecc

szymon_g wrote:
ArchArael wrote:
cardinals_fan wrote:

I just use Zsh.  Rush sounds [very] interesting though...

Ok...what makes zsh better than bash in your opinion? It's just the tab completion or there is something else?

1. better completion
2. its lighter and faster than bash
3. it have got kind of mime-type recognition :~

btw, i'm not on arch at this moment, so i cant check it, - have much Arch is bash-addicted? is it possible to use other shell (i'm thinking about zsh) without need of rewriting half of all scripts?

Could you explain the third point please?

The Arch default shell is bash and probably most of the system scripts use dash and bash in bourn shell mode. But I don't think it's a good idea convert these scripts to any other shell language if you mean that. That would be a futile effort. Every update would overwrite your system scripts.

I have a bunch of my scripts and they are all in bash because this is my main shell. I could convert most of them easily because they are not so long and complex. But as bash shell is a system dependence this also would be a futile effort. Bash is always there so why bother.  smile
I used zsh and fish as main and login shells for some time.
You need to configure the .zshrc and .config/fish/config.fish properly to have a complete variable environment but it's doable quite easily.

Last edited by ArchArael (2009-01-03 21:32:29)

Offline

#10 2009-01-03 21:41:44

andre.ramaciotti
Member
From: Brazil
Registered: 2007-04-06
Posts: 649

Re: alternative shells: fish, hotwire, rush ecc

With zsh, you can set an app to open a particular type of file, so you can run something like this:

code.c

and it'll be as you typed:

vim code.c

You can set it by putting this in your .zshrc, (ie. this will open any file that ends with pdf in evince):

alias -s pdf=evince

I did a little search and found this: The VimShell
Actually, it's a patch to vim. With it, you can use vim to control some shell sessions. It's not a shell, but you can split the window and have some running at the same time.

Edit: a little more search and I found this two shells: scsh, a shell written in scheme with a scheme sintax for the lispers, and psh, the perl shell, self-explanatory name.

Last edited by andre.ramaciotti (2009-01-03 21:47:56)


(lambda ())

Offline

#11 2009-01-03 21:44:31

ArchArael
Member
Registered: 2005-06-14
Posts: 504

Re: alternative shells: fish, hotwire, rush ecc

andre.ramaciotti, really interesting.

Pity that the vimshell patch is only for 7.0 vim trunk. hmm

Last edited by ArchArael (2009-01-03 21:57:07)

Offline

#12 2009-01-03 22:45:59

szymon_g
Member
Registered: 2008-11-24
Posts: 36

Re: alternative shells: fish, hotwire, rush ecc

fwojciec wrote:

All official Arch scripts are written explicitly in bash:

$ cat /etc/rc.sysinit | head -1
#!/bin/bash

So you either need bash installed or a shell that's fully compatible with bash.
Also, /etc/profile has basic infrastructure to distinguish between different shells: http://repos.archlinux.org/viewvc.cgi/f … iew=markup

ok, thats good that they don't 'invoke' bash through #!/bin/sh symlined to /bin/bash :)
but i really dont think so its good that they require a specified shell... (official) scripts should run on something posix shell compatible, not bash compatible. thanks that, scripts could be at least partially compatible with other unices (bsd's, solaris etc) (not to mention that they could be a bit faster- but i wont give you a 'hard' benchmarks on it, unfortunatelly :/)
i know, i know- i can always have bash installed (but use only zsh)- but this is rather a semi-solution, not to mention that this isn't (AFAIK) 'compatible' with KISS...

Offline

#13 2009-01-04 00:07:39

dagle
Member
Registered: 2009-01-04
Posts: 13

Re: alternative shells: fish, hotwire, rush ecc

http://192.220.96.201/es/es-usenix-winter93.html kinda intressting too. To bad that development seems to be zero at this point.

Offline

#14 2009-01-04 00:08:38

fwojciec
Member
Registered: 2007-05-20
Posts: 1,411

Re: alternative shells: fish, hotwire, rush ecc

szymon_g wrote:

but i really dont think so its good that they require a specified shell... (official) scripts should run on something posix shell compatible, not bash compatible. thanks that, scripts could be at least partially compatible with other unices (bsd's, solaris etc) (not to mention that they could be a bit faster- but i wont give you a 'hard' benchmarks on it, unfortunatelly hmm)
i know, i know- i can always have bash installed (but use only zsh)- but this is rather a semi-solution, not to mention that this isn't (AFAIK) 'compatible' with KISS...

But bash has arrays which are used heavily everywhere in Arch; things like this in rc.conf (main configuration file):

MODULES=(ath5k powernow-k8)

Offline

#15 2009-01-04 14:34:52

badboy
Member
Registered: 2009-01-02
Posts: 32

Re: alternative shells: fish, hotwire, rush ecc

ArchArael wrote:

badboy...how do you deal with interactive rush use? I found it quite basic...no tab completion for example.

no tab completion? Tab-completion works for local files but not for code, that's right. But for simple tasks it's easier to use rush than irb.

Offline

#16 2009-01-04 16:13:44

rine
Member
From: Germany
Registered: 2008-03-04
Posts: 217

Re: alternative shells: fish, hotwire, rush ecc

szymon_g wrote:
ArchArael wrote:
cardinals_fan wrote:

I just use Zsh.  Rush sounds [very] interesting though...

Ok...what makes zsh better than bash in your opinion? It's just the tab completion or there is something else?

1. better completion
2. its lighter and faster than bash
3. it have got kind of mime-type recognition :~

btw, i'm not on arch at this moment, so i cant check it, - have much Arch is bash-addicted? is it possible to use other shell (i'm thinking about zsh) without need of rewriting half of all scripts?

Yea, well the first line of the scripts is important. If its #!/bin/bash and bash is installed, bash will always be called, no matter which shell you use.

Offline

#17 2009-01-04 17:45:31

alex_anthony
Member
From: UK
Registered: 2007-09-25
Posts: 344

Re: alternative shells: fish, hotwire, rush ecc

I've used fish from time to time
It's nice and has good colours, the completion is really nice (e.g. if I type pacman -Q then hit tab, it lists all the options like -Qi -Qo etc and says what each does. It highlights pairs of brackets, unknown commands and other things like this

But the configuration annoys me sometimes:
making functions is a bit more work, you don't just type alias ... into a file
I can't get as complex a piece of text before my PS1 (yet - I'm working on it)

The help page calls configurability the root of all evil, so this may be the root of my problems

Also, fish doesn't work with nautilus-open-terminal

Last edited by alex_anthony (2009-01-04 18:02:18)

Offline

#18 2009-01-04 18:27:55

Square
Member
Registered: 2008-06-11
Posts: 435

Re: alternative shells: fish, hotwire, rush ecc

I literally just found this before I read this thread.
http://shython.sourceforge.net/
It looks really interesting. A merge of bash and python.
Too bad there's not a package in the AUR. Guess I'll have to quit being lazy for a while. big_smile

EDIT: Seems it's just a python script. Also seems that there's an issue for me trying to execute it, however.
Hopefully I can get it to work!

EDIT AGAIN: The last reported activity was one year ago. hmm

EDIT: Good news! I made it work with minor corrections. If you're interested let me know.

Last edited by Square (2009-01-04 18:54:39)


 

Offline

#19 2009-01-04 20:48:50

ArchArael
Member
Registered: 2005-06-14
Posts: 504

Re: alternative shells: fish, hotwire, rush ecc

alex_anthony wrote:

I've used fish from time to time
It's nice and has good colours, the completion is really nice (e.g. if I type pacman -Q then hit tab, it lists all the options like -Qi -Qo etc and says what each does. It highlights pairs of brackets, unknown commands and other things like this

But the configuration annoys me sometimes:
making functions is a bit more work, you don't just type alias ... into a file
I can't get as complex a piece of text before my PS1 (yet - I'm working on it)

The help page calls configurability the root of all evil, so this may be the root of my problems

Also, fish doesn't work with nautilus-open-terminal

I also use fish shell from time to time. I also had some minor drawbacks with the configurations.
For instance I tried to add some bindings like these:

bind \cp history-search-backward
bind \cn history-search-forward
bind \e. history-token-search-backward
bind \e: history-token-search-forward

The first two are working directly and the second two works only when I type them as command. That's strange so I submitted a question in the mailing list and I'm waiting for a response.
I like fish ideas and I find it powerful. You're right about the configurability though, it's harder to configure than bash. I have some habits from bash and once i fix al bindings in fish I will try to use it as main shell for some time. The fish developer it's really a smart guy...you can find his articles on web. I like his ideas.
I also missed aliases in fish but the ability to edit functions directly from the prompt is nice and makes the aliases feature missing pretty painless.
For gnome-open-terminal you could add the command fish at the beginning or at the end of your .bashrc. wink That would make fish work with nautilus-open-terminal for sure.

Last edited by ArchArael (2009-01-04 20:52:42)

Offline

#20 2009-01-05 00:56:40

alex_anthony
Member
From: UK
Registered: 2007-09-25
Posts: 344

Re: alternative shells: fish, hotwire, rush ecc

ArchArael wrote:

For gnome-open-terminal you could add the command fish at the beginning or at the end of your .bashrc. wink That would make fish work with nautilus-open-terminal for sure.

nice idea on nautilus-open-terminal, but it isn't loading bash, it loads fish but always to $HOME, not to the directory i wanted to open

Any idea on how to get a complex welcome message? - I want the output of some commands to be displayed but using set fish_greeting just prints the commands, not the output

Offline

#21 2009-01-05 03:51:17

ArchArael
Member
Registered: 2005-06-14
Posts: 504

Re: alternative shells: fish, hotwire, rush ecc

I misunderstood your problem with nautilus-open-terminal. Sorry. May I suggest you to use nautilus-actions?

http://www.grumz.net/?q=taxonomy/term/5/9

http://www.grumz.net/?q=node/227&size=_original

As you can see from the screenshots you can use %d and pass it to gnome-terminal this way:

gnome-terminal --working-directory=%d

You could even make two actions:

Open bash:

gnome-terminal --working-directory=%d

Open fish:

PWD=%d gnome-terminal --working-directory=%d -e fish

Apparently PWD=%d is necessary.

This way you could use both shells without start fish from .bashrc or make it the login shell. smile

alex_anthony wrote:

Any idea on how to get a complex welcome message? - I want the output of some commands to be displayed but using set fish_greeting just prints the commands, not the output

For the complex welcome message I suggest you a subshell. It's working. Maybe you could make a function so any time you need to change your greeting message you could do it inline with funced. wink

set fish_greeting ( echo 'fish shell rocks' )

result:

arael[~]$fish
fish shell rocks
arael@infinity ~>

Last edited by ArchArael (2009-01-05 06:31:18)

Offline

#22 2009-01-05 05:32:32

cardinals_fan
Member
From: /dev/null
Registered: 2008-02-03
Posts: 248

Re: alternative shells: fish, hotwire, rush ecc

ArchArael wrote:
cardinals_fan wrote:

I just use Zsh.  Rush sounds [very] interesting though...

Ok...what makes zsh better than bash in your opinion? It's just the tab completion or there is something else?

* Superior tab completion
* Greater configurability
* Lighter resource usage [I think]
* Using something less common makes me feel like a 1337 rebel


Segmentation fault (core dumped)

Offline

#23 2009-01-05 11:56:13

dr_te_z
Member
From: Zoetermeer, the Netherlands
Registered: 2006-12-06
Posts: 154

Re: alternative shells: fish, hotwire, rush ecc

In the past I've worked with HP/UX & AIX machines, forcing me to use the korn-shell. In that time I tried to use a simular shell on my linux machine, to get used.
Now there is no need anymore, so i am very happy with the mix linux/bash.


Somewhere between "too small" and "too large" lies the size that is just right.
- Scott Hayes

Offline

#24 2009-01-05 16:00:32

sokuban
Member
Registered: 2006-11-11
Posts: 412

Re: alternative shells: fish, hotwire, rush ecc

Everytime I read one of those old unix books they all talk about ksh as if it is one of the most popular shells, but nowadays everyone seems to use bash. What happened to ksh? (And I thought zsh was an "alternative shell")

Also I use zsh. Mainly for the tab completion and the vim mode.

Offline

#25 2009-01-05 16:15:04

ArchArael
Member
Registered: 2005-06-14
Posts: 504

Re: alternative shells: fish, hotwire, rush ecc

sokuban wrote:

Everytime I read one of those old unix books they all talk about ksh as if it is one of the most popular shells, but nowadays everyone seems to use bash. What happened to ksh? (And I thought zsh was an "alternative shell")

Also I use zsh. Mainly for the tab completion and the vim mode.

Considering that usually who does not use bash in this forum usually uses zsh I didn't consider it alternative. The topic was about other esoteric shells that are not so widespread like bash and zsh.

I don't know ksh much but reading books about bash I learned that bash has all best features of ksh. Maybe is this the motivation of korn shells minor popularity nowadays.

By the way...maybe you will appreciate this interview. It's old but still interesting: http://slashdot.org/articles/01/02/06/2030205.shtml

big_smile http://kornshell.com/fun/

Last edited by ArchArael (2009-01-05 16:30:30)

Offline

Board footer

Powered by FluxBB