<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Marco Peluso</title>
    <link>https://marcopeluso.com/</link>
    <description>Recent content on Marco Peluso</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en</language>
    <lastBuildDate>Tue, 15 Oct 2024 20:43:05 +0200</lastBuildDate><atom:link href="https://marcopeluso.com/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>About</title>
      <link>https://marcopeluso.com/about/</link>
      <pubDate>Tue, 15 Oct 2024 20:43:05 +0200</pubDate>
      
      <guid>https://marcopeluso.com/about/</guid>
      <description>&lt;h1 id=&#34;hey-im-marco&#34;&gt;Hey, I&amp;rsquo;m Marco.&lt;/h1&gt;
&lt;p&gt;I&amp;rsquo;m a Software Engineer and aspiring content creator interested in note-taking, personal knowledge management and workflow optimization, among other things. I love to learn and share knowledge with others.&lt;/p&gt;
&lt;p&gt;Here I share some of the things that spark my interest, mostly tech stuff.&lt;/p&gt;</description>
      <content>&lt;h1 id=&#34;hey-im-marco&#34;&gt;Hey, I&amp;rsquo;m Marco.&lt;/h1&gt;
&lt;p&gt;I&amp;rsquo;m a Software Engineer and aspiring content creator interested in note-taking, personal knowledge management and workflow optimization, among other things. I love to learn and share knowledge with others.&lt;/p&gt;
&lt;p&gt;Here I share some of the things that spark my interest, mostly tech stuff.&lt;/p&gt;
</content>
    </item>
    
    <item>
      <title>Level Up Your macOS Terminal With Wezterm Starship and Eza</title>
      <link>https://marcopeluso.com/posts/level-up-your-macos-terminal-with-wezterm-starship-and-eza/</link>
      <pubDate>Tue, 01 Oct 2024 20:51:31 +0200</pubDate>
      
      <guid>https://marcopeluso.com/posts/level-up-your-macos-terminal-with-wezterm-starship-and-eza/</guid>
      <description>&lt;p&gt;Hello and welcome to my first blog post (we&amp;rsquo;re not counting posts further than 15 years in the past 😉). As a software developer I spend a considerable amount of time on the command-line in my terminal emulator. In this post we are going to take the plain old default terminal setup you get with macOS to a beautiful and more functional terminal setup. We&amp;rsquo;re assuming our starting point is a fresh install of macOS Sonoma.&lt;/p&gt;</description>
      <content>&lt;p&gt;Hello and welcome to my first blog post (we&amp;rsquo;re not counting posts further than 15 years in the past 😉). As a software developer I spend a considerable amount of time on the command-line in my terminal emulator. In this post we are going to take the plain old default terminal setup you get with macOS to a beautiful and more functional terminal setup. We&amp;rsquo;re assuming our starting point is a fresh install of macOS Sonoma.&lt;/p&gt;
&lt;p&gt;Enough prolog, let&amp;rsquo;s dive right into it!&lt;/p&gt;
&lt;h2 id=&#34;accompanying-youtube-video&#34;&gt;Accompanying YouTube Video&lt;/h2&gt;
&lt;p&gt;I made a &lt;a href=&#34;https://www.youtube.com/watch?v=LnZdaNfQ86o&#34;&gt;YouTube video&lt;/a&gt; in which I take you through all the steps of this blog post and also demonstrate some of the cool functionality you get. Feel free to watch it and leave me a comment, if you want to.&lt;/p&gt;


    
    &lt;div style=&#34;position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;&#34;&gt;
      &lt;iframe allow=&#34;accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share&#34; allowfullscreen=&#34;allowfullscreen&#34; loading=&#34;eager&#34; referrerpolicy=&#34;strict-origin-when-cross-origin&#34; src=&#34;https://www.youtube.com/embed/LnZdaNfQ86o?autoplay=0&amp;controls=1&amp;end=0&amp;loop=0&amp;mute=0&amp;start=0&#34; style=&#34;position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;&#34; title=&#34;YouTube video&#34;
      &gt;&lt;/iframe&gt;
    &lt;/div&gt;

&lt;h2 id=&#34;installing-homebrew&#34;&gt;Installing Homebrew&lt;/h2&gt;
&lt;p&gt;To install the Terminal app, the font and some other tools, we&amp;rsquo;re going to use a package manager. &lt;a href=&#34;https://brew.sh&#34;&gt;Homebrew&lt;/a&gt; is a very popular package manager for macOS. Installation is very easy. We just open a terminal emulator and paste the command below into it and start the installation by pressing &amp;ldquo;return&amp;rdquo;. macOS comes with a pre-installed terminal emulator, that listens to the really simple but extremely fitting name: &amp;ldquo;Terminal.app&amp;rdquo;.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-sh&#34; data-lang=&#34;sh&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;/bin/bash -c &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;$(&lt;/span&gt;curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh&lt;span style=&#34;color:#66d9ef&#34;&gt;)&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;We&amp;rsquo;ll be prompted for our password during installation. Don&amp;rsquo;t worry, if you see nothing happening, while typing in your password. It&amp;rsquo;s very common on the command-line to not show any kind of feedback, during password dialogs. Also, we will have to confirm the installation of the &amp;ldquo;Xcode Command Line Tools&amp;rdquo;, if you haven&amp;rsquo;t installed them already. Depending on the speed of your computer and your internet connection, this can take a few (or many) minutes.&lt;/p&gt;
&lt;p&gt;To add Homebrew to your PATH, every time you startup your shell we do the following:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-sh&#34; data-lang=&#34;sh&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;echo &amp;gt;&amp;gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;$HOME&lt;span style=&#34;color:#e6db74&#34;&gt;/.zprofile&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;echo &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;eval &amp;#34;$(/opt/homebrew/bin/brew shellenv)&amp;#34;&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt; &amp;gt;&amp;gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;$HOME&lt;span style=&#34;color:#e6db74&#34;&gt;/.zprofile&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;eval &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;$(&lt;/span&gt;/opt/homebrew/bin/brew shellenv&lt;span style=&#34;color:#66d9ef&#34;&gt;)&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Now we are ready to run Homebrew&amp;rsquo;s command-line interface &lt;code&gt;brew&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;After the installation is finished, the first thing I always do, is to turn of Homebrew&amp;rsquo;s analytics:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-sh&#34; data-lang=&#34;sh&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;brew analytics off
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;You can of course leave them enabled, if you want to.&lt;/p&gt;
&lt;p&gt;At this point, we should have a fully functioning &lt;a href=&#34;https://brew.sh&#34;&gt;Homebrew&lt;/a&gt; installation. Yay, congratulations! From now on, we can easily install all kinds of software using the &lt;code&gt;brew&lt;/code&gt; command. And that&amp;rsquo;s exactly what we&amp;rsquo;re going to do to level up our terminal setup.&lt;/p&gt;
&lt;h2 id=&#34;installing-wezterm&#34;&gt;Installing WezTerm&lt;/h2&gt;
&lt;p&gt;That&amp;rsquo;s where the foundation of our command-line setup comes into play: a better terminal emulator. There are quite a few possible candidates: the tried and true &lt;a href=&#34;https://marcopeluso.com/&#34;&gt;iTerm2&lt;/a&gt; or some more modern and very popular alternatives like &lt;a href=&#34;https://alacritty.org/&#34;&gt;Alacritty&lt;/a&gt; or &lt;a href=&#34;https://sw.kovidgoyal.net/kitty/&#34;&gt;kitty&lt;/a&gt;. There&amp;rsquo;s also the new kid on the block: &lt;a href=&#34;https://mitchellh.com/ghostty&#34;&gt;Ghostty&lt;/a&gt; written in &lt;a href=&#34;https://ziglang.org/&#34;&gt;Zig&lt;/a&gt;. It is developed by &lt;a href=&#34;https://mitchellh.com/&#34;&gt;Mitchell Hashimoto&lt;/a&gt;, a co-founder of &lt;a href=&#34;https://hashicorp.com/&#34;&gt;HashiCorp&lt;/a&gt;. I really want to try this out, but as the time of writing Ghostty is still in private beta and unfortunately I&amp;rsquo; didn&amp;rsquo;t score an invite, yet. We&amp;rsquo;ll probably take it for a spin in the near future. Stay tuned for it!&lt;/p&gt;
&lt;p&gt;But there&amp;rsquo;s no need to be upset. We will use the awesome &lt;a href=&#34;https://wezfurlong.org/wezterm/index.html&#34;&gt;WezTerm&lt;/a&gt; as our new terminal emulator. WezTerm is a fast, GPU-accelerated powerful cross-platform terminal emulator that runs on macOS, but also on Linux, FreeBSD and even Windows. It is written in &lt;a href=&#34;https://www.rust-lang.org&#34;&gt;Rust&lt;/a&gt; and boasts cool and super-useful features like a built-in terminal multiplexer, support for ligatures, a searchable scrollback just to name a few. It even supports multiple image protocols. It features relatively sane keybindings out of the box, is highly configurable via a &lt;a href=&#34;https://lua.org&#34;&gt;Lua&lt;/a&gt; configuration file and even offers hot reloading of config changes. It&amp;rsquo;s a great piece of kit!&lt;/p&gt;
&lt;p&gt;Enough praise for WezTerm. We&amp;rsquo;re going to put Homebrew to good use for the first time now and install WezTerm right from our current terminal. Run the following command:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-sh&#34; data-lang=&#34;sh&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;brew install --cask wezterm
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;After the installation is finished we can finally close Terminal.app and start our shiny new terminal emulator. So let&amp;rsquo;s launch WezTerm to go on with the setup.&lt;/p&gt;
&lt;p&gt;As a security measurement macOS wants us to confirm, that we really want to open WezTerm. We sure do, and so we confidently click on the &amp;ldquo;Open&amp;rdquo; button. Time to enjoy using your new terminal emulator!&lt;/p&gt;
&lt;p&gt;You might think: &amp;ldquo;This doesn&amp;rsquo;t look much better than Terminal.app after all&amp;hellip;&amp;rdquo; and I would totally agree with you. But WezTerm is very customizable. Let&amp;rsquo;s start configuring it. But first we are going to install the font we want to use in our setup.&lt;/p&gt;
&lt;h2 id=&#34;installing-jetbrains-mono-nerd-font&#34;&gt;Installing JetBrains Mono Nerd Font&lt;/h2&gt;
&lt;p&gt;Let&amp;rsquo;s leverage Homebrew again. A quick &lt;code&gt;brew install --cask font-jetbrains-mono-nerd-font&lt;/code&gt; and we&amp;rsquo;re ready to use our newly installed font.&lt;/p&gt;
&lt;h2 id=&#34;configuring-wezterm&#34;&gt;Configuring WezTerm&lt;/h2&gt;
&lt;p&gt;WezTerm is configured using a Lua configuration File. We&amp;rsquo;ll create this file at &lt;code&gt;~/.config/wezterm/wezterm.lua&lt;/code&gt;. Here&amp;rsquo;s what I have in my config with some comments for further explanation:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-lua&#34; data-lang=&#34;lua&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;-- Helper function:&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;-- returns color scheme dependant on operating system theme setting (dark/light)&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;local&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;function&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;color_scheme_for_appearance&lt;/span&gt;(appearance)
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; appearance:find &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Dark&amp;#34;&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;then&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Tokyo Night&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Tokyo Night Light (Gogh)&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  &lt;span style=&#34;color:#66d9ef&#34;&gt;end&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;end&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;-- Pull in WezTerm API&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;local&lt;/span&gt; wezterm &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; require &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;wezterm&amp;#39;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;-- Initialize actual config&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;local&lt;/span&gt; config &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; {}
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; wezterm.config_builder &lt;span style=&#34;color:#66d9ef&#34;&gt;then&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  config &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; wezterm.config_builder()
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;end&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;-- Appearance&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;config.font &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; wezterm.font &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;JetBrainsMono Nerd Font&amp;#39;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;config.font_size &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;14.0&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;config.color_scheme &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; color_scheme_for_appearance(wezterm.gui.get_appearance())
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;config.window_decorations &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;RESIZE&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;config.hide_tab_bar_if_only_one_tab &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;true&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;config.native_macos_fullscreen_mode &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;false&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;-- Keybindings&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;config.keys &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; {
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  &lt;span style=&#34;color:#75715e&#34;&gt;-- Default QuickSelect keybind (CTRL-SHIFT-Space) gets captured by something&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  &lt;span style=&#34;color:#75715e&#34;&gt;-- else on my system&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  {
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    key &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;A&amp;#39;&lt;/span&gt;,
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    mods &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;CTRL|SHIFT&amp;#39;&lt;/span&gt;,
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    action &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; wezterm.action.QuickSelect,
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  },
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;}
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;-- Return config to WezTerm&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; config
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;This config is relatively small, because I like most of WezTerm&amp;rsquo;s default keybindings and settings. For those shiny icons in the terminal prompt, we use &lt;code&gt;JetBrains Mono&lt;/code&gt; in the patched &lt;code&gt;Nerd Font&lt;/code&gt; version, which we installed before with font size 14. This is currently my favorite monospace font. You can of course install any other &lt;a href=&#34;https://www.nerdfonts.com/&#34;&gt;Nerd Font&lt;/a&gt; and use that, if you want to. A quick&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-sh&#34; data-lang=&#34;sh&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;brew search --cask nerd
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;will give you a list of installable fonts that you can easily install with the &lt;code&gt;brew&lt;/code&gt; command.&lt;/p&gt;
&lt;p&gt;I just have set up the beautiful color scheme &lt;a href=&#34;https://github.com/folke/tokyonight.nvim&#34;&gt;Tokyo Night&lt;/a&gt; and it&amp;rsquo;s light counterpart, respectively. Configured like this, WezTerm dynamically switches between the light and dark themes, depending on the theme setting on the operating system level. So if I switch between &lt;code&gt;Dark&lt;/code&gt; and &lt;code&gt;Light&lt;/code&gt; in macOS&amp;rsquo; Appearance settings, Wezterm&amp;rsquo;s theme automatically switches, too. I often use this feature during changing lighting conditions. When it&amp;rsquo;s really bright and the sun is shining, I switch to &lt;code&gt;Light&lt;/code&gt; mode and when it gets a little bit more gloomy, I prefer the &lt;code&gt;Dark&lt;/code&gt; setting.&lt;/p&gt;
&lt;p&gt;We remove the default window decorations but are keeping the window resizable with the value &lt;code&gt;RESIZE&lt;/code&gt; for the &lt;code&gt;window_decorations&lt;/code&gt; setting and hide the tab bar, if we only have one tab open. Also we don&amp;rsquo;t want to use macOS&amp;rsquo; native fullscreen mode.&lt;/p&gt;
&lt;h2 id=&#34;wezterm-in-action&#34;&gt;WezTerm in Action&lt;/h2&gt;
&lt;p&gt;I want to show you a few of WezTerm&amp;rsquo;s features. I use these all the time and find them very useful.&lt;/p&gt;
&lt;h3 id=&#34;splitting-windows&#34;&gt;Splitting Windows&lt;/h3&gt;
&lt;p&gt;WezTerm enables you to split your terminal windows. When you open a new WezTerm window it contains exactly one pane, that takes up all of the available space inside the window. You can then split this pane into smaller panes, either horizontally or vertically. These newly created panes can then be split times and times again. WezTerm&amp;rsquo;s default keybinds for splitting are the following:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;ALT-CTRL-SHIFT-&amp;quot;&lt;/code&gt;: Splits pane vertical&lt;/li&gt;
&lt;li&gt;&lt;code&gt;ALT-CTRL-SHIFT-%&lt;/code&gt;: Splits pane horizontal&lt;/li&gt;
&lt;li&gt;&lt;code&gt;CTRL-SHIFT-Z&lt;/code&gt;: Toggles pane&amp;rsquo;s zoom state, which means you can toggle the pane between taking up the complete window or just being it&amp;rsquo;s actual size&lt;/li&gt;
&lt;li&gt;&lt;code&gt;CTRL-SHIFT-LeftArrow/DownArrow/UpArrow/RightArrow&lt;/code&gt;: Switches focus to from currently active pane to pane in given direction&lt;/li&gt;
&lt;li&gt;&lt;code&gt;ALT-CTRL-SHIFT-LeftArrow/DownArrow/UpArrow/RightArrow&lt;/code&gt;: Resizes the currently active pane in the given direction&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;quick-select-mode&#34;&gt;Quick Select Mode&lt;/h3&gt;
&lt;p&gt;Quick Select mode let&amp;rsquo;s you quickly highlight text in your terminal, that matches commonly copied patterns and prefixes them with a prefix of one or two characters. Typing these characters copies the corresponding text into your clipboard.&lt;/p&gt;
&lt;p&gt;To see how this looks in practice, I encourage you to take a look at the &lt;a href=&#34;https://www.youtube.com/watch?v=LnZdaNfQ86o&#34;&gt;YouTube video&lt;/a&gt; I made related to this blog post or visit &lt;a href=&#34;https://wezfurlong.org/wezterm/quickselect.html&#34;&gt;WezTerm&amp;rsquo;s official documentation on Quick Select Mode&lt;/a&gt;. A quick summary of the default shortcuts:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;CTRL-SHIFT-Space&lt;/code&gt;: Activate Quick Select Mode (I&amp;rsquo;ve bound this to &lt;code&gt;CTRL-SHIFT-A&lt;/code&gt; in our config file earlier).&lt;/li&gt;
&lt;li&gt;&lt;code&gt;character-prefix&lt;/code&gt;: Copy corresponding highlighted pattern&lt;/li&gt;
&lt;li&gt;&lt;code&gt;ESC&lt;/code&gt;: Deactivate Quick Select Mode&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;copy-mode&#34;&gt;Copy Mode&lt;/h3&gt;
&lt;p&gt;Copy mode enables you to select and copy text to the clipboard all while just using your keyboard. Some relevant default keybindings are:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;CTRL-SHIFT-X&lt;/code&gt; Activate CopyMode
in CopyMode &lt;code&gt;Esc&lt;/code&gt; exits CopyMode&lt;/li&gt;
&lt;li&gt;&lt;code&gt;h&lt;/code&gt;, &lt;code&gt;j&lt;/code&gt;, &lt;code&gt;k&lt;/code&gt;, &lt;code&gt;l&lt;/code&gt; or &lt;code&gt;LeftArrow&lt;/code&gt;,&lt;code&gt;DownArrow&lt;/code&gt;,&lt;code&gt;UpArrow&lt;/code&gt;, &lt;code&gt;RightArrow&lt;/code&gt;, to move around by character&lt;/li&gt;
&lt;li&gt;&lt;code&gt;w&lt;/code&gt;, &lt;code&gt;e&lt;/code&gt;, &lt;code&gt;b&lt;/code&gt; to move by word&lt;/li&gt;
&lt;li&gt;Other Vim motion keybinds to move around like &lt;code&gt;CTRL-U&lt;/code&gt; or &lt;code&gt;CTRL-D&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Toggle selection modes, like visual modes in vim &lt;code&gt;v&lt;/code&gt;, &lt;code&gt;SHIFT-V&lt;/code&gt;, &lt;code&gt;CTRL-V&lt;/code&gt;,&lt;/li&gt;
&lt;li&gt;Move to other ends of selection: &lt;code&gt;o&lt;/code&gt;, &lt;code&gt;SHIFT-O&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;y&lt;/code&gt; to copy to system clipboard&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The full list of default keybinds can be found in &lt;a href=&#34;https://wezfurlong.org/wezterm/copymode.html&#34;&gt;WezTerm&amp;rsquo;s official documentation on Copy Mode&lt;/a&gt; or you can of course create your own keybinds.&lt;/p&gt;
&lt;h3 id=&#34;installing-zsh-plugins-using-homebrew&#34;&gt;Installing Zsh Plugins Using Homebrew&lt;/h3&gt;
&lt;p&gt;We&amp;rsquo;ll just install two plugins, that I think are essential. These are &lt;a href=&#34;https://github.com/zsh-users/zsh-autosuggestions&#34;&gt;zsh-autosuggestions&lt;/a&gt; and &lt;a href=&#34;https://github.com/zsh-users/zsh-syntax-highlighting&#34;&gt;zsh-syntax-highlighting&lt;/a&gt;. We&amp;rsquo;re not even going to use a special plugin manager for Zsh. Instead we&amp;rsquo;re using Homebrew again to install the plugins:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-sh&#34; data-lang=&#34;sh&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;brew install zsh-autosuggestions zsh-syntax-highlighting
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Then we&amp;rsquo;ll add the following lines to the end of our &lt;code&gt;.zshrc&lt;/code&gt;:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-zsh&#34; data-lang=&#34;zsh&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;source /opt/homebrew/share/zsh-autosuggestions/zsh-autosuggestions.zsh
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;source /opt/homebrew/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;After that we have to restart WezTerm or we can manually &lt;code&gt;source ~/.zshrc&lt;/code&gt; to activate the plugins.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;[!NOTE]
If you receive the &amp;ldquo;highlighters directory not found&amp;rdquo; error message,
you may need to add the following to your ~/.zshenv:&lt;/p&gt;
&lt;p&gt;&lt;code&gt;export ZSH_HIGHLIGHT_HIGHLIGHTERS_DIR=/opt/homebrew/share/zsh-syntax-highlighting/highlighters&lt;/code&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2 id=&#34;installing-starship&#34;&gt;Installing Starship&lt;/h2&gt;
&lt;p&gt;To enhance our terminal experience even further, we need a better prompt. &lt;a href=&#34;https://starship.rs/&#34;&gt;Starship&lt;/a&gt; is a really fast and very customizable shell prompt, that works on most common shells and operating systems. It is written in &lt;a href=&#34;https://www.rust-lang.org/&#34;&gt;Rust&lt;/a&gt; and comes with a nice default configuration. To install it we once again use our trusty friend Homebrew and cast the following spell:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-sh&#34; data-lang=&#34;sh&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;brew install starship
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;After installing Starship, we need to add following line to the end of our &lt;code&gt;.zshrc&lt;/code&gt;:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-zsh&#34; data-lang=&#34;zsh&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;eval &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;$(&lt;/span&gt;starship init zsh&lt;span style=&#34;color:#66d9ef&#34;&gt;)&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Now just restart your Terminal and you have your new prompt! To see Starship in action, I shamelessly point you to the &lt;a href=&#34;https://marcopeluso.com/&#34;&gt;related YouTube video&lt;/a&gt; I made again.&lt;/p&gt;
&lt;h2 id=&#34;installing-eza&#34;&gt;Installing eza&lt;/h2&gt;
&lt;p&gt;To finish up for today, we are going to replace the good old &lt;code&gt;ls&lt;/code&gt; command with a modern alternative called &lt;a href=&#34;https://eza.rocks/&#34;&gt;eza&lt;/a&gt;. You probably know the drill by now:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-sh&#34; data-lang=&#34;sh&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;brew install eza
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;That&amp;rsquo;s all you really have to do, to now use &lt;code&gt;eza&lt;/code&gt;. I like to add a few aliases to my &lt;code&gt;.zshrc&lt;/code&gt;, to keep using the muscle memory I built up over the years and effortlessly use of the icons and built-in tree-functionality:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-zsh&#34; data-lang=&#34;zsh&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;# eza (better `ls`)&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;alias l&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;eza --icons&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;alias ls&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;eza --icons&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;alias ll&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;eza -lg --icons&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;alias la&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;eza -lag --icons&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;alias lt&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;eza -lTg --icons&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;alias lt1&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;eza -lTg --level=1 --icons&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;alias lt2&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;eza -lTg --level=2 --icons&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;alias lt3&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;eza -lTg --level=3 --icons&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;alias lta&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;eza -lTag --icons&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;alias lta1&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;eza -lTag --level=1 --icons&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;alias lta2&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;eza -lTag --level=2 --icons&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;alias lta3&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;eza -lTag --level=3 --icons&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h2 id=&#34;where-to-go-from-here&#34;&gt;Where To Go From Here&lt;/h2&gt;
&lt;p&gt;This was just the tip of the iceberg. We barely scratched the surface of everything that&amp;rsquo;s possible in the terminal.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://github.com/junegunn/fzf&#34;&gt;fzf&lt;/a&gt; is a powerful and very flexible &lt;a href=&#34;https://en.wikipedia.org/wiki/Approximate_string_matching&#34;&gt;fuzzy finder&lt;/a&gt; for the command-line. &lt;a href=&#34;https://github.com/ajeetdsouza/zoxide&#34;&gt;zoxide&lt;/a&gt;, &lt;a href=&#34;https://github.com/sharkdp/bat&#34;&gt;bat&lt;/a&gt; and &lt;a href=&#34;https://github.com/sharkdp/fd&#34;&gt;fd&lt;/a&gt; are just a few examples of modern replacements for standard command-line tools like &lt;code&gt;ls&lt;/code&gt;, &lt;code&gt;cat&lt;/code&gt; and &lt;code&gt;find&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;There are terminal multiplexers out there, that are independent of the terminal emulator you use.&lt;a href=&#34;https://github.com/tmux/tmux&#34;&gt;tmux&lt;/a&gt; is probably the most popular, but there&amp;rsquo;s also &lt;a href=&#34;https://github.com/zellij-org/zellij&#34;&gt;zellij&lt;/a&gt; written in &lt;a href=&#34;https://www.rust-lang.org&#34;&gt;Rust&lt;/a&gt; that is gaining more followers. You could also take a look at good old &lt;a href=&#34;https://www.gnu.org/software/screen/&#34;&gt;GNU Screen&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Cool &lt;a href=&#34;https://en.m.wikipedia.org/wiki/Text-based_user_interface&#34;&gt;TUIs&lt;/a&gt;) like &lt;a href=&#34;https://github.com/jesseduffield/lazygit&#34;&gt;lazygit&lt;/a&gt; or the awesome terminal JSON viewer &lt;a href=&#34;https://github.com/antonmedv/fx&#34;&gt;fx&lt;/a&gt; can really make your work easier and more enjoyable.&lt;/p&gt;
&lt;p&gt;And then there&amp;rsquo;s &lt;a href=&#34;https://neovim.io/&#34;&gt;Neovim&lt;/a&gt;, a &lt;a href=&#34;https://www.vim.org/&#34;&gt;Vim&lt;/a&gt;-fork, that is very extensible with plugins written in &lt;a href=&#34;https://www.lua.org/&#34;&gt;Lua&lt;/a&gt; and can be configured to exactly match your needs.&lt;/p&gt;
&lt;p&gt;I will be posting more content about some of those things. I hope you enjoyed this little journey and we&amp;rsquo;ll meet again, soon.&lt;/p&gt;
</content>
    </item>
    
  </channel>
</rss>
