<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Andrei Vasilev</title>
    <description>The latest articles on DEV Community by Andrei Vasilev (@arekko).</description>
    <link>https://dev.to/arekko</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F184365%2F74a521bf-ea8e-42f2-ad21-1b5cf94e25e6.jpeg</url>
      <title>DEV Community: Andrei Vasilev</title>
      <link>https://dev.to/arekko</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/arekko"/>
    <language>en</language>
    <item>
      <title>How to Set Up Your Terminal for Maximum Productivity in Development</title>
      <dc:creator>Andrei Vasilev</dc:creator>
      <pubDate>Wed, 22 May 2024 09:52:15 +0000</pubDate>
      <link>https://dev.to/arekko/how-to-set-up-your-terminal-for-maximum-productivity-in-development-5ao1</link>
      <guid>https://dev.to/arekko/how-to-set-up-your-terminal-for-maximum-productivity-in-development-5ao1</guid>
      <description>&lt;p&gt;The internet is flooded with articles on configuring a &lt;strong&gt;terminal for productive work&lt;/strong&gt;, and this guide is another drop in that ocean. It’s designed to be useful for complete beginners or for those looking to try something different.&lt;/p&gt;

&lt;p&gt;Following the steps in this guide, you will end up with a terminal that looks similar to the screenshot below.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fdl2ilc90fqplnr3nych3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fdl2ilc90fqplnr3nych3.png" alt="Image description" width="800" height="489"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Let’s start from defining the software we will use:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;The &lt;a href="https://alacritty.org/"&gt;Alacrity&lt;/a&gt; terminal is incredibly fast and customizable. Try working with a large project in Vim using, for example, iTerm. You might be pleasantly surprised.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://fishshell.com/"&gt;Fish&lt;/a&gt; shell&lt;/li&gt;
&lt;li&gt;Plugins for fish:

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://github.com/oh-my-fish/oh-my-fish"&gt;oh-my-fish&lt;/a&gt; — packet manager for the fish shell&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://github.com/oh-my-fish/theme-bobthefish"&gt;bobthefish&lt;/a&gt; — nice powerline style theme&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://github.com/jhillyerd/plugin-git"&gt;git&lt;/a&gt; — provides a efficient shortcuts for git&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://github.com/edc/bass"&gt;bass&lt;/a&gt; — allows to use bash script/utilities in fish&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;How to install and setup&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Install the Alacritty terminal emulator using your machine’s packet manager or by following the instructions provided in the manual installation guide.
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;brew &lt;span class="nb"&gt;install&lt;/span&gt; &lt;span class="nt"&gt;--cask&lt;/span&gt; alacritty &lt;span class="c"&gt;# for macOS&lt;/span&gt;
&lt;span class="c"&gt;# or &lt;/span&gt;
&lt;span class="nb"&gt;sudo &lt;/span&gt;snap &lt;span class="nb"&gt;install &lt;/span&gt;alacritty &lt;span class="nt"&gt;--classic&lt;/span&gt; &lt;span class="c"&gt;# for unix based os&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;To configure Alacritty, we need to create a configuration file.
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;touch&lt;/span&gt; &lt;span class="nv"&gt;$HOME&lt;/span&gt;/.config/alacritty/alacritty.toml
&lt;span class="c"&gt;# or&lt;/span&gt;
&lt;span class="nb"&gt;touch&lt;/span&gt; &lt;span class="nv"&gt;$HOME&lt;/span&gt;/.alacritty.toml
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;and put an initial configs into it&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;import &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="o"&gt;[&lt;/span&gt;
  &lt;span class="s2"&gt;"~/.config/alacritty/catppuccin-mocha.toml"&lt;/span&gt; &lt;span class="c"&gt;# use a nice looking theme&lt;/span&gt;
&lt;span class="o"&gt;]&lt;/span&gt;

&lt;span class="o"&gt;[&lt;/span&gt;font]
normal &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt;&lt;span class="nv"&gt;family&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"JetBrains Mono"&lt;/span&gt;&lt;span class="o"&gt;}&lt;/span&gt; &lt;span class="c"&gt;# Good programming font from JetBrain&lt;/span&gt;
size &lt;span class="o"&gt;=&lt;/span&gt; 12.0

&lt;span class="o"&gt;[&lt;/span&gt;window]
&lt;span class="c"&gt;#decorations = "None"&lt;/span&gt;
dynamic_padding &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;true
&lt;/span&gt;dimensions &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt; columns &lt;span class="o"&gt;=&lt;/span&gt; 160, lines &lt;span class="o"&gt;=&lt;/span&gt; 45 &lt;span class="o"&gt;}&lt;/span&gt; &lt;span class="c"&gt;# dimensions of the terminal window&lt;/span&gt;

&lt;span class="o"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;env&lt;/span&gt;&lt;span class="o"&gt;]&lt;/span&gt;
TERM &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"xterm-256color"&lt;/span&gt;

&lt;span class="o"&gt;[&lt;/span&gt;selection]
save_to_clipboard &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;true&lt;/span&gt; &lt;span class="c"&gt;# save selected text to the clipboard&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Install a &lt;strong&gt;Fish shell&lt;/strong&gt; using available package manager or one of some different options from &lt;a href="https://medium.com/b68bbda4d0a04669937edd670cba8e1a?pvs=25"&gt;here&lt;/a&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;brew &lt;span class="nb"&gt;install &lt;/span&gt;fish &lt;span class="c"&gt;# for macOS&lt;/span&gt;
&lt;span class="c"&gt;# or use following commands for Debian system&lt;/span&gt;
&lt;span class="nb"&gt;sudo &lt;/span&gt;apt-add-repository ppa:fish-shell/release-3
&lt;span class="nb"&gt;sudo &lt;/span&gt;apt update
&lt;span class="nb"&gt;sudo &lt;/span&gt;apt &lt;span class="nb"&gt;install &lt;/span&gt;fish
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Set Fish as a default shell
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; /usr/local/bin/fish | &lt;span class="nb"&gt;sudo tee&lt;/span&gt; &lt;span class="nt"&gt;-a&lt;/span&gt; /etc/shells
chsh &lt;span class="nt"&gt;-s&lt;/span&gt; /usr/local/bin/fish
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Restart your terminal and install oh-my-fish package manager
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl https://raw.githubusercontent.com/oh-my-fish/oh-my-fish/master/bin/install | fish

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;After that, you will be able to manage your Fish plugins using the following commands:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;omf list &lt;span class="c"&gt;# List all installed plugins&lt;/span&gt;
omf &lt;span class="nb"&gt;install&lt;/span&gt; &lt;span class="o"&gt;[&lt;/span&gt;plugin name] &lt;span class="c"&gt;# Install plugin&lt;/span&gt;
omf update &lt;span class="o"&gt;[&lt;/span&gt;plugin-name]  &lt;span class="c"&gt;# Update plugin&lt;/span&gt;
omf remove &lt;span class="o"&gt;[&lt;/span&gt;plugin-name]  &lt;span class="c"&gt;# Remove plugin  &lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Let’s install some &lt;strong&gt;plugins&lt;/strong&gt; mentioned in the beginning, you can use full repository url with plugin to install iLet’s install some plugins mentioned in the beginning. You can use the full repository URL with the plugin to install it.
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;omf &lt;span class="nb"&gt;install &lt;/span&gt;https://github.com/jhillyerd/plugin-git
omf &lt;span class="nb"&gt;install &lt;/span&gt;bobthefish
omf &lt;span class="nb"&gt;install &lt;/span&gt;bass
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;To get everything out from the bobthefish theme, we need to install a &lt;a href="https://powerline.readthedocs.io/en/master/overview.html"&gt;powerline&lt;/a&gt; font.
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;port &lt;span class="k"&gt;select &lt;/span&gt;python python27-apple
brew &lt;span class="nb"&gt;install &lt;/span&gt;python

pip &lt;span class="nb"&gt;install&lt;/span&gt; &lt;span class="nt"&gt;--user&lt;/span&gt; powerline-status
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Download and install JetBrains Mono font, following &lt;a href="https://www.jetbrains.com/lp/mono/#how-to-install"&gt;this&lt;/a&gt; instructions.&lt;/li&gt;
&lt;li&gt;Download a catppuccin-mocha theme. You can find more theme options in the &lt;a href="https://github.com/catppuccin/alacritty"&gt;GitHub repo&lt;/a&gt;.
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-LO&lt;/span&gt; &lt;span class="nt"&gt;--output-dir&lt;/span&gt; ~/.config/alacritty https://github.com/catppuccin/alacritty/raw/main/catppuccin-mocha.toml

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;p&gt;At this point, you should have the fast and beautiful modern terminal in use. There are millions of different Fish plugins and Alacritty settings that you can set up to customize the terminal for your particular needs. This is just an initial setup, which can be infinitely modified.&lt;/p&gt;

</description>
      <category>terminal</category>
      <category>bash</category>
      <category>shell</category>
      <category>tools</category>
    </item>
  </channel>
</rss>
