๐ŸŽญ HyperShell: Unifying Windows and Linux

10/15/2024โ€ขStefanie Jane
terminalwindowslinuxwsldevelopmentproductivitycustomization

๐ŸŒŸ Introduction

Introducing HyperShellโ€”a meticulously crafted terminal setup that unites the best of Windows and Linux. If you love Linux's flexibility but still value some of what Windows offers, HyperShell is here to provide a seamless, powerful working environment.


๐ŸŒˆ The Hybrid Approach: Windows + WSL2

As a long-time Linux enthusiast who also appreciates certain aspects of Windows, I created HyperShell to blend the best of both worlds. Here's why this hybrid setup fits my workflow:

FeatureDescription
๐Ÿง Linux Development EnvironmentWith WSL2, you get a full-fledged Linux environment, perfect for all your development needs.
๐ŸŽต Music ProductionWindows excels in audio drivers and support for music production software. I use it for DAWs like Ableton Live, making it an essential part of my creative process.
๐ŸŽฎ Gaming and GraphicsLeverage Windows' extensive support for gaming and graphics tools. HyperShell lets you easily switch gears without rebooting.
๐Ÿ”ง Tool FlexibilityThe ability to switch between Linux and Windows tools is key, whether you're debugging code, editing videos, or tinkering with hardware.

๐Ÿงฐ Key Components of HyperShell

HyperShell combines a carefully curated set of tools that make it both powerful and enjoyable to use:

  1. ๐Ÿ–ฅ๏ธ Windows Terminal: A sleek, customizable command-line interface.
  2. ๐Ÿง WSL2 with Ubuntu: A fully integrated Linux experience right inside Windows.
  3. ๐Ÿ”ง PowerShell: Enhanced for smoother interactions with the Windows system, including useful keybindings and productivity enhancements.
  4. ๐Ÿ“ AstroNvim: A turbocharged Neovim setup (more on this below).
  5. ๐Ÿš€ Starship: A cross-shell prompt that's as customizable as it is beautiful.
  6. ๐Ÿ” FZF: A fuzzy finder that makes searching files and history lightning fast.
  7. ๐ŸŒˆ LSD: A modern replacement for ls, with lots of visual enhancements.
  8. ๐Ÿ™ Git: Version control with custom aliases for quick operations.
  9. ๐Ÿณ Docker: Containerization, plus helpful aliases and integrations.
  10. ๐Ÿ”‘ Keybindings and Custom Aliases: Configured in both PowerShell and Zsh to boost efficiency.

๐Ÿ› ๏ธ Setting Up HyperShell

Getting started with HyperShell is a breeze:

  1. Clone the repository:

    1git clone https://github.com/hyperb1iss/dotfiles.git %USERPROFILE%\dev\dotfiles
  2. Run the installation script (you'll need admin privileges):

    1cd %USERPROFILE%\dev\dotfiles
    2install.bat

This script takes care of:

  • Installing essential tools via Chocolatey (PowerShell Core, Windows Terminal, Git, VS Code, Node.js, Python, Rust, Docker, and more).
  • Setting up PowerShell modules for extended functionality.
  • Configuring Git with custom aliases for a smoother workflow.
  • Installing VS Code extensions commonly used by developers.
  • Setting up WSL2 for seamless Linux integration.
  • Installing and configuring Starship for a consistent prompt across shells.
  • Setting up AstroNvim with pre-configured settings.

๐ŸŒ  AstroNvim: Elevating the Neovim Experience

AstroNvim is my go-to Neovim configurationโ€”it's a powerful, feature-rich setup that brings out the best of Neovim without much hassle.

Key Features:

  • ๐Ÿš€ Blazing fast startup time
  • ๐Ÿ“ฆ Easy plugin management
  • ๐ŸŽจ Beautiful and functional UI
  • ๐Ÿ“Š Built-in dashboard
  • ๐Ÿ” Fuzzy finding with Telescope
  • ๐ŸŒณ File explorer with Neo-tree
  • ๐Ÿ‘จโ€๐Ÿ’ป Powerful LSP integration

With HyperShell, AstroNvim is automatically installed and configured. To start using it, simply open Neovim:

1nvim

For customization, head over to ~/AppData/Local/nvim/lua/user/init.lua. AstroNvim comes with a ton of features out of the box, and you can tweak it to your heart's content.


๐Ÿค– Using HyperShell: Key Features and Commands

HyperShell comes packed with features to supercharge your terminal experience. Here are some key commands and keybindings to get you started:

๐Ÿ” Fuzzy Finding with FZF

  • Ctrl+f: Fuzzy find files in the current directory and subdirectories
  • Alt+c: Fuzzy find and change to a directory
  • Ctrl+r: Fuzzy find and execute a command from history

๐Ÿ“‚ Enhanced Directory Navigation

  • cd -: Go back to the previous directory
  • mkcd <dir>: Create a directory and change into it
  • lt: List files and directories in a tree structure

๐ŸŽ›๏ธ Linux-style Aliases

  • ls, ll, la: Colorful directory listings with LSD
  • cat, less: Use bat for syntax highlighting
  • grep, find, sed, awk: Use GNU versions for extended functionality
  • touch, mkdir: Create files and directories
  • which: Find the location of a command

๐Ÿง WSL Integration

  • wsld: Switch to the WSL environment
  • wslopen <path>: Open a WSL directory in Windows Explorer
  • wgrep, wsed, wfind, wawk: Run Linux commands from PowerShell

๐Ÿ™ Git Shortcuts

  • gst: Git status
  • ga: Git add
  • gco: Git commit
  • gpp: Git push
  • gcp: Git cherry-pick

๐Ÿณ Docker Shortcuts

  • dps: List running Docker containers
  • di: List Docker images

๐Ÿ”„ Reloading HyperShell

  • reload: Reload the PowerShell profile to apply changes

These are just a few examplesโ€”explore the HyperShell dotfiles to discover more custom functions and aliases to speed up your workflow.


๐Ÿ’ช Leveraging HyperShell: Tips and Tricks

Here are some tips to help you make the most of HyperShell:

  1. Customize Key Bindings: Modify keybindings in the PowerShell profile ($PROFILE) to suit your preferences.
  2. Extend Functionality: Add your own aliases, functions, and scripts to the profile files to further tailor HyperShell to your needs.
  3. Explore Tools: Dive deeper into the capabilities of tools like FZF, LSD, and bat. They have a lot to offer!
  4. Leverage WSL: Make full use of WSL for Linux-specific tasks. You can easily switch between Windows and Linux environments.
  5. Learn Keybindings: Commit the custom keybindings to muscle memory. They're designed to minimize hand movement and boost efficiency.
  6. Stay Updated: Pull the latest changes from the dotfiles repo regularly to get updates and improvements.

๐ŸŽฌ Wrap-Up

HyperShell is all about creating a seamless, flexible terminal experience for those who love both Windows and Linux. It's perfect for developers, sysadmins, and creatives who want the best of both worlds without the hassle of juggling two separate setups.

If you're ready to level up your terminal game, check out the GitHub repository and give HyperShell a try. I'd love to hear how it works for youโ€”feel free to open an issue or share your thoughts!