Travis

Travis

这里支持的小组件太少,写不下😂,欢迎查看我的个人 blog <blog.lxythan2lxy.cn>

Arch Linux Personal Notes

This article is also published on Arch Linux Personal Notes | Travis' Blog. Feel free to check it out.

Overall Configuration#

I have Arch Linux installed on my laptop, while my desktop has a dual boot of Windows 11 and Linux. My laptop is a 13-inch Xiaoxin Pro, and luckily, I haven't encountered any compatibility issues so far.
My desktop uses an Nvidia RTX 2080Ti graphics card, and it works smoothly with the official drivers. Currently, there are no unresolved issues except for the GTK4 problem.

  • Distribution: Arch Linux
  • Window Manager: i3wm
  • Terminal: kitty
  • Application Launcher: albert (rofi, dmenu)
  • Dock: polybar
  • Compositor: picom-jonaburg-git

2023-01-10-09-53-53.webp

Why Tinker with Arch#

2023-01-10-10-33-57.webp

  1. Tinkering is a kind of fun
  2. Windows is not Linux, MacOS is just a Unix-like system
  3. Linux allows you to see some lower-level aspects of an operating system

KISS: Keep It Simple, Stupid

First, let's talk about "tinkering". If I need to use Linux, tinkering is inevitable. It doesn't matter which distribution I use. In this case, it's better to start with a clean system like Arch, which makes it easier to explore and play around.
For example, a typical out-of-the-box distribution is like a fully furnished model house. You can move in right away, but it's hard to figure out the wiring and furniture settings all at once. If a component breaks and I have to fix it myself, it becomes even more challenging.
Arch, on the other hand, is like a blank canvas. The plumbing and wiring are already in place, and all I need to do is find the furniture I want from the IKEA catalog (Arch Wiki) and gradually furnish my own little nest.
This feeling is unparalleled because everything is configured according to my preferences. It feels like I truly own it.
On a clean Arch Linux system, I can slowly adjust my desktop layout on a lightweight window manager, manage my workflow with key mapping software or shortcut managers, and explore various customization options waiting to be discovered, as seen on unixporn.

Now, let's talk about Linux systems. Most of the backend software we develop is ultimately deployed on Linux systems, so coding on Linux has its native advantages.
Of course, there are solutions for Windows and MacOS as well, such as using virtual machines, Docker, or VSCode remote to code on a server. There are plenty of options.
Those who have tinkered with the Windows environment should understand that Windows and Unix-like systems have many subtle differences, and more importantly, Windows is not globally UTF-8, which can lead to strange issues.
Furthermore, as the name suggests, Windows is a graphical operating system, and MacOS is too. Linux has better support for the command line.

Linux is only free if your time has no value

All of the above are just personal preferences. I often work with Kubernetes-related things, and the ecosystem I interact with is closer to Linux. Those who don't need Linux can avoid the hassle.

Advantages#

Understanding Linux#

Arch Linux has a comprehensive ArchWiki for reference.

Learning anything comes with a cost, even with user-friendly Windows systems. Beginners need time to get used to the logic of operations. During my undergraduate studies, my first encounter with Linux was in the bomb lab of the CSAPP course. At that time, I didn't even know how to use the shell and had to use the gdb debugger to defuse bombs in the command line. That was my initial impression of Linux.
After practical experience, theoretical learning is necessary to internalize the knowledge. To learn Linux, besides learning various tricks, a lot of practice is needed to become familiar with the operations.
Between "familiarity" and "understanding," there is still a long way to go. This is where theoretical knowledge comes into play, and the process repeats in a spiral of continuous improvement.

To gain practical experience with Linux, using it as a daily driver is a choice—not using virtual machines or remote servers but installing a system on physical storage and configuring it step by step from the bootloader. In this process, it's not uncommon to encounter setbacks and struggle with problems that seem difficult to solve. However, by consulting the RTFM (Read The F***ing Manual) and STFW (Search The F***ing Web), you can solve 90% of the problems.

Package Manager#

Linux package managers are very convenient and efficient. Looking back at the various software installation processes on Windows—visiting the official website, downloading the installer, and double-clicking to install—it's much simpler on Linux with package managers like yum, apt, and pacman. Moreover, this process is easily automated and recorded, ensuring that software is kept up to date.
Compared to Ubuntu's package manager, Arch Linux's package manager pacman is even more convenient.
This convenience comes from the Arch User Repository (AUR), a community-driven software repository that contains packaging scripts for various software. With AUR helpers like yay or paru, you can easily install a wide range of software without the hassle of dealing with Ubuntu PPAs.

For example, if I want to install the popular fd, ripgrep, and my favorite key mapping software, keyd [^keyd], I only need to run the following commands:

yay -S fd ripgrep
yay -S keyd

2023-01-16-17-13-41.webp

By the way, Windows now has package managers like scoop, chocolaty, and winget.

Tiling Window Manager#

Unlike floating window managers on MacOS and Windows, Linux offers a whole new window management experience—tiling window managers 1.

linux.webp

In general, floating window managers allow windows to overlap within a desktop. On the other hand, tiling window managers prefer to tile all windows on the desktop, meaning the desktop is always fully occupied. In this case, if I open dozens of windows, I won't be able to see anything on the desktop. That's where workspaces come in—a concept similar to virtual desktops in other operating systems. Switching between workspaces is as simple as using win+number to quickly switch. Typically, I bind the browser to ws2, instant messaging apps to ws3, note-taking software to ws4, RSS readers to ws6, and coding environments to ws10+ positions. These configurations are personal and can be easily set up.

The main advantage of tiling window managers is that they allow me to focus within a workspace, with the main software occupying the entire screen. However, if a task requires opening many windows, this type of window management can be cumbersome, but windows can be rearranged as needed.

Disadvantages#

Software Ecosystem#

Due to the relatively small number of Linux desktop users and the various Linux distributions, major vendors do not prioritize Linux users. This is especially true for domestic software. Tencent's QQ, Tim, WeChat, and other applications did not have official Linux versions for a while.
In terms of document editing, Microsoft Office has become a standard, and various miscellaneous documents need to be written using Office, which is not possible on Linux. WPS Office and LibreOffice cannot fully replace Microsoft Office.
In recent years, due to development costs, many have embraced Electron applications, which allow writing once and running everywhere. Perhaps this is the breakthrough for the future of Linux software ecosystem.

As for gaming, Valve's Steam Deck runs on SteamOS [^steamos], which is an Arch-based system. Valve has made significant optimizations for compatibility, and I believe the gaming ecosystem on Linux will improve.

However, at present, Linux still has a significant gap in terms of software ecosystem. While it meets the needs of programmers, there is no compelling reason for the general public to engage with this operating system, which has a high learning curve.

Requires Tinkering#

Arch Linux is not as plug-and-play as other distributions. Although it allows for customization of many components, it requires tinkering.
For beginners, the most troublesome aspect is troubleshooting. Without encountering various strange problems, it's difficult to identify which component is causing the issue.
Personally, I have encountered GRUB boot errors, X server startup failures, and other issues. I always keep a ventoy USB drive with the latest Arch Live ISO, ready to repair the system at any time.

Arch Linux is a rolling release distribution, unlike Ubuntu's point release model. Arch Linux updates frequently, and there is a phenomenon known as "rolling hang."

Conclusion#

What suits you best is the best choice. Arch Linux provides a way to build a workflow that suits you.

If you've read this far and want to try Linux for yourself, you can start with Ubuntu Desktop to get your feet wet, and then try Manjaro, an Arch-based operating system that offers an out-of-the-box experience and allows you to easily experience the Arch ecosystem.
If you want to dive straight into Arch Linux, you can start with the Installation Guide on the official website or use the ArchTutorial provided by Arch Linux Studio.

Regardless of the distribution, always remember to RTFM, STFW, and seek community help if you can't solve the problem yourself or submit an issue to the repository.


Footnotes#

  1. tiling windows manager

Loading...
Ownership of this post data is guaranteed by blockchain and smart contracts to the creator alone.