Switching to Linux
Notes from a former Windows user
February 16, 2023 Ā· Felipe Vogel Ā·- Why Linux?
- Installing Linux Mint
- Payoff #1: a lovely terminal
- Payoff #2: more time spent on the keyboard, less on the mouse
- What about AutoHotkey?
- Conclusion: an educational change
- Next steps
I did it. I finally switched to Linux š§ Hereās how it went and what I learned!
Why Linux?
Until a few days ago, I was a longtime Windows user. Recently at work Iāve been using an obligatory MacBook Pro, but otherwise I still preferred my PC with Windows, mainly because I was used to it, but also because Windows provides WSL (Windows Subsystem for Linux), which Iāve found to be less troublesome for development than MacOS.
But WSL has limitations. Running graphical Linux apps, while possible, is not pretty. Worse, WSL uses a lot of memory, and lately Iāve been having to restart it after a few hoursā use due to what seems to be a memory leak. Yikes!
Plus, Windows itself is a pain. To point to a well-known example, itās been increasingly difficult to find where to change a simple setting in Windows, amid the proliferation of new and half-finished settings UIs.
So I thought, why not switch to pure, unadulterated Linux?
Installing Linux Mint
I chose Linux Mint because it has a familiar Windows-like UI, and itās right up there with Ubuntu as one of the commonly-recommended distros for beginners.
As I installed it on my Alienware m15 R4, I had to do only a few things out of the ordinary:
- The Mint installer complained about Intel RST. To disable it, I opened up BIOS settings and switched from RAID to AHCI. I still wanted to use both my physical drives as one logical unit (i.e. RAID0), so I installed Mint using LVM, following this guide.
- After installation, I decided to go into BIOS settings and disable Secure Boot, because itās a pain to have to enter a password when I install certain drivers. See here and here on why for the average Linux desktop user, Secure Boot is more trouble than itās worth.
- To prevent screen tearing on my external monitor, I had to open up NVIDIA settings via the tray icon and switch to āPerformance Modeā.
- Bash was having issues wrapping lines, so I installed Zsh and that fixed the problem.
- I fixed a few other annoyances with my startup scripts. (See all the rest of my Linux scripts here.)
So the switch took some time, but Iām already seeing a payoff in two areas: a lovely terminal, and more time spent on the keyboard. Of course, neither of these is unique to Linux, and Iām bringing these lessons back to MacOSābut somehow it was easier for me to make these discoveries in Linux.
Payoff #1: a lovely terminal
Along with Zsh, I installed Oh My Zsh and a bunch of handy plugins:
- copybuffer
- copyfile
- copypath
- gitfast
- rake-fast
- sudo
- thefuck
- zsh-autosuggestions
- zsh-navigation-tools
- zsh-z
I also copied some aliases from the git and rails plugins.
Next, I cobbled together key bindings to enable Shift selection on the command line. Just this one improvement takes a lot of the pain out of the terminal for me, because now I can edit text on the command line much as I do everywhere else.
Payoff #2: more time spent on the keyboard, less on the mouse
I have a history of wrist pain from being on the computer all day long. Taking breaks and stretching helps, but ultimately I need to use the mouse less, and keyboard shortcuts more.
Switching to a new OS is the perfect time to look for more ways to stay on the keyboard, and in Linux itās actually pretty easy since nearly everything is customizable.
Besides Mintās keyboard shortcut settings UI and my now-likable terminal, Iāve found a few other tools that help me stay on the keyboard:
- My Keyboardio Atreus keyboard. Iāve had it for a while now, but itās worth mentioning because I love it so much, and now Iāve further customized its layout to make keyboard-only navigation easier.
- Vimium Chrome/Firefox extension. Navigate the web with your keyboard!
- Caret browsing (F7 in most browsers). Vimium also has a visual mode if you prefer vim-style shortcuts.
- Espanso text expander.
- Porcellite clipboard manager. Despite being apparently unmaintained (the last update was in 2017), itās my favorite one. Its search function is not as good as in Ditto (which is Windows-only), but otherwise Porcellite is perfect.
- The compose key for typing Unicode characters.
Soon Iāll have to challenge myself to see how long I can go without my mouse. Maybe stick it in a drawer on the other side of the house? š
What about AutoHotkey?
On Windows I was a big fan of AutoHotkey. Thereās no equivalent in Linux, except for in-progress projects (AHK_X11 and Keysharp).
But you know what? Iām not missing AutoHotkey. Most of what I did in AutoHotkey, I can now do via keyboard shortcuts and/or scripts. And anyway, most of my AutoHotkey shortcuts were for my mouse, which (as I now see in retrospect) did more harm than good.
Conclusion: an educational change
There are a few things that itāll take me a long time to get used to in Linux, such as the confusing filesystem hierarchy. (At least Iām comforted in seeing Iām not the only one who is unimpressed by the common rationalizations for it. Thereās even a Linux distro that abandons the standard filesystem hierarchy altogether.)
But on the whole itās been a surprisingly enjoyable switch. Not because it was a perfect experience out of the box, but because as Iām customizing and fixing things, Iām improving my scripting skills and learning how Linux works under the hood.
MacOS and (especially) Windows are more opaque, in my experience. In Windows my tools of customization were AutoHotkey and other free utilities, and in Mac I use an assortment of (usually) paid apps to get a similar effect. But I donāt gain anything from these tools beyond the immediate problem being fixed. I donāt learn very much from them.
But in Linux I get to customize the OS in the same way that I do programming. (By Googling for hours and tweaking what I copy-paste until something works š) And in the end, as I look with pride on the barely-significant thing that Iāve fixed or adjusted, I realize that the tidbits of Linux knowledge Iāve picked up along the way may be just as valuable as end result. Already Iāve had a few ālightbulb momentsā when some Unix-related features of Ruby finally made sense, and Iām sure more of those moments are to comeāthe whole Internet runs on Linux servers, after all, so learning more about Linux can only help me as a developer.
Next steps
Where to go from here? My plan is to keep using Linux and to get started on my Linux/command-line reading list as well as my Ruby scripting list. (A few hours of Bash scripting was enough to make me want to use a friendlier language for all but performance-intensive tasks.)
And now that I have a graphical Linux environment for development, the way is open for me to try out the DragonRuby Game Toolkit⦠(cue ominous music).