Back to Home

How to install and configure ridiculous fish shell in Debian Squeeze

fish · shell · debian · squeeze

How to install and configure ridiculous fish shell in Debian Squeeze

    Most recently, I discovered the Ridiculous fish shell , which is fundamentally different from the bash and zsh that I worked with earlier. On my MacBook Pro under Mac OS X, the shell installed without any problems and worked great. Having mastered the new shell, I decided it was time to install and configure it the same way on the servers on which the 64-bit Debian Squeeze is installed. Then I came across the fact that the 32-bit deb package that is on their site is not installed on the 64-bit Debian. And I decided to build my favorite shell from the source. This process will be described in the article.

    Download the source from the site and unpack them.
    wget http://ridiculousfish.com/shell/files/fishfish.tar.gz
    tar xzf fishfish.tar.gz
    

    The search for the necessary dependencies caused some difficulty; I could not quickly find the place where they were described. It’s possible that the dependencies are not correct, but everything is going for me with such dependencies.
    sudo apt-get install autoconf g++ libncurses5-dev libncursesw5-dev gettext
    

    After the dependencies are installed, we proceed with the assembly of the shell itself.
    autoconf
    ./configure --without-xsel
    

    When configuring, I specify the option --without-xsel. If you do not specify it, then during assembly the script will not find some libraries from X11. I had no desire to install X11 on the Severre. If everything went well, you will see:
    fish is now configured.
    Use 'make' and 'make install' to build and install fish.
    

    We start assembly.
    make
    

    If the assembly completed successfully, then you will see:
    fish has now been built.
    Use 'make install' to install fish.
    

    After assembly, install fish.
    sudo make install
    

    If all is well, you will see:
    fish is now installed on your system.
    To run fish, type 'fish' in your terminal.
    To use fish as your login shell:
    * add the line '/usr/local/bin/fish' to the file '/etc/shells'.
    * use the command 'chsh -s /usr/local/bin/fish'.
    To set your colors, run 'fish_config'
    To scan your man pages for completions, run 'fish_update_completions'
    Have fun!
    

    Add the line / usr / local / bin / fish to / etc / shells, as the installer recommends.
    sudoedit /etc/shells 
    

    Select fish as a shell.
    chsh -s /usr/local/bin/fish
    

    After the installation was completed, I still had some problems: the annoying blinking of commands and tips and the broken generation of completions due to the manpath. I solved the problem with blinking by removing the “extra” settings in the colors that the shell of the team paints. You can choose the one you like using the set fish_color_ * parameters.
    set fish_color_autosuggestion yellow
    set fish_color_command green
    set fish_color_param cyan
    

    The problem with broken generation of completions was also solved using a terrible trick. Edit the file:
    sudoedit /usr/local/share/fish/tools/create_manpage_completions.py
    

    We go to line number 744 and, as described here, edit this line so that instead of
    proc = subprocess.Popen(['man', '--path'], stdout=subprocess.PIPE)
    

    happened
    proc = subprocess.Popen(['manpath'], stdout=subprocess.PIPE)
    

    Then we start generation completions
    fish_update_completions 
    

    If everything is correctly received in response, something like
    Parsing man pages and writing completions to /home/rp/.config/fish/completions/
    


    Voila! Enjoy the wonderful shell.

    Read Next