# How i can install the Fish Shell ?



## christhegeek (May 8, 2020)

1)  I tried to install fish  , tried to set the user to this shell with pw command and it says there is no fish shell how i install fish shell ?
2) How i can configure it for typing greek characters too (alongside with english-us) ?  
Is there  a keyboard configuration file in /etc/defaults like linux ?


----------



## memreflect (May 8, 2020)

If you want to use the fish shell (or any other shell) as your login shell, it must exist in /etc/shells.  Once it is in that file, you can use chsh(1) to change your shell (e.g. `chsh -s fish`).
*Console/TTY (not a terminal emulator)*

kbdmap(1) is the "easy" way.  However, I think only one can be active at a time, meaning you cannot easily switch between them.  Also, `kbdmap` is just a simple frontend for kbdcontrol(1).  Unlike `kbdmap`, you can use `kbdcontrol -k` to configure two different keyboards to have different keymaps, allowing you to use one Greek keyboard and one English keyboard.  See rc.conf(1) if you want a certain keymap used automatically.

*Xorg*

Many desktop environments such as KDE provide a way for you to do this already.  Otherwise, see xkeyboard-config(7) for configuration possibilities, and you would use setxkbmap(1) to set your desired configuration.  For example, I use this in my ~/.xinitrc to make it automatic every time I `startx`:

```
# us(dvorak-alt-intl) is the default layout with a secondary layout us(alt-intl) available.
# Ctrl-Shift switches between layouts.
setxkbmap \
    -layout us,us \
    -variant dvorak-alt-intl,alt-intl \
    -option grp:ctrl_shift_toggle
```


----------



## Minbari (May 8, 2020)

christhegeek said:


> 1)  I tried to install fish  , tried to set the user to this shell with pw command and it says there is no fish shell how i install fish shell ?


If you are using pkg just type `pkg install fish`


christhegeek said:


> 2) How i can configure it for typing greek characters too (alongside with english-us) ?
> Is there  a keyboard configuration file in /etc/defaults like linux ?


Follow this tutorial to have multiple keyboard layouts.


----------

