{"id":24408675,"url":"https://github.com/therustifyer/dotfiles","last_synced_at":"2025-07-01T22:31:55.772Z","repository":{"id":224097880,"uuid":"762388498","full_name":"TheRustifyer/dotfiles","owner":"TheRustifyer","description":"A Git bare repo for storing my general system and applications common configurations. OS independent (more on README.md)","archived":false,"fork":false,"pushed_at":"2025-03-22T08:00:24.000Z","size":334,"stargazers_count":3,"open_issues_count":3,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-19T10:30:11.926Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/TheRustifyer.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-02-23T17:15:03.000Z","updated_at":"2025-03-22T08:00:28.000Z","dependencies_parsed_at":"2024-07-22T08:31:01.071Z","dependency_job_id":"408f840b-eae5-463c-b267-aed3a6f50528","html_url":"https://github.com/TheRustifyer/dotfiles","commit_stats":null,"previous_names":["therustifyer/.dotfiles","therustifyer/alexvergara","therustifyer/dotfiles"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/TheRustifyer/dotfiles","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheRustifyer%2Fdotfiles","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheRustifyer%2Fdotfiles/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheRustifyer%2Fdotfiles/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheRustifyer%2Fdotfiles/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TheRustifyer","download_url":"https://codeload.github.com/TheRustifyer/dotfiles/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TheRustifyer%2Fdotfiles/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263046019,"owners_count":23405117,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-01-20T05:52:31.061Z","updated_at":"2025-07-01T22:31:55.703Z","avatar_url":"https://github.com/TheRustifyer.png","language":"Shell","readme":"# The Rustifyer dotfiles configuration\n\nHi there everyone! This is my GitHub's repository for storing my more beloved configuration on certain\nsystem or applications.\n\nThis allows me to quickly setup my full development environment (as I like to have it) just by cloning and pulling\nthis repository in any machine.\n\nAlso, I can share and have up-to-date all my configuration along my typically used machines.\n\n![image](https://github.com/TheRustifyer/dotfiles/assets/68871459/a4cad9b6-4aa3-405b-8bcd-55087a7a51e6)\n\n\u003e Two terms of `Alacritty` on the left, and one of `Wezterm` on the right natively multiplexed on *Windows*\n\n## Terminal emulators\n\nThe setup comes preparated for choose between `Wezterm` or `Alacritty` as your terminal emulators (or take both) .\n\nBoth are `Rust` based tools, known for their high speed and stability. Choose between them is a matter or your personal preference, so if you don't\nknow them, just go ahead, read their docs and pick your favourite one!\n\nIn the meantime, I am personally using `Wezterm` on Windows, so I take the opportunity to learn about it, and `Alacritty + Zellij` on `Linux`.\n\n\u003e [!NOTE]\n\u003e\n\u003e `Alacritty` and `Zellij` will be automatically download (if you want) with the setup script provided later. But if you plan to\n\u003e use `Wezterm`, you'll need to manually download it from their webpage for the moment on *Windows*, since I yet not found a nice\n\u003e solution to workaround its build from source due to some *Perl* build dependencies.\n\n### [Alacritty](https://alacritty.org/) + [ZelliJ](https://zellij.dev/)\n\n![image](https://github.com/TheRustifyer/dotfiles/assets/68871459/090d0d53-d50a-4de4-8dd6-c3b9dded6cc3)\n\n\u003e The terminal emulator `Alacritty` running a session of the terminal multiplexer `ZelliJ` on a `Manjaro` distro\n\n`Alacritty` is the terminal emulator that I've been using for years, using it in combination with `tmux`, having an incredible and powerful\nterminal environment. But `tmux` doesn't works on `Windows`, neither native, nor via `MSYS2` (the unique way is with `WSL`). That's why I\nswitch to `Zellij`. \n\nBoth, `tmux` and `Zellij` are *terminal multiplexers*, which allows you to have fancy features like tabs, panes and sessions. `Zellij`\nisn't usable on *Windows* natively, but at the time of writing, there's this [`PR`](https://github.com/zellij-org/zellij/pull/2926) which is implementing\nthe *Windows* native working. Fingers crossed that it will be merged soon.\n\nBut in the mean time, I forked the fork that is opening the `Windows` implementation *PR* and added some cleanup and custom niceties. So, you'll be able\nto use `Zellij` on *Windows*\n\n### [Wezterm](https://wezfurlong.org/wezterm)\n\n![image](https://github.com/TheRustifyer/dotfiles/assets/68871459/161e4c97-10e2-4e98-aa0b-5972db0c8c16)\n\n\u003e A multiplexed instance of `Wezterm` on *Windows*, using `bat` on the left pane to visualize the `zsh` config file\n\u003e and `lazygit` managing the dotfiles of the bare repo on the right.\n\n### Alacritty + tmux (legacy)\n\nI also provide the legacy configuration I've used for years, with `Alacritty` and `tmux`, for nostalgic `Linux` users.\n\n### Editor: Neovim\n\n`Neovim` is a command line editor and a project that seeks to aggressively refactor Vim in order to:\n\n  - Simplify maintenance and encourage contributions\n  - Split the work between multiple developers\n  - Enable advanced UIs without modifications to the core\n  - Maximize extensibility\n\n`Neovim` is incredible powerful and customizable. `Vim` motions (once you get use to them) will overpower the way you write (and even think) about\nyour code workflow.\n\n### Shell and Shell framework\n\n#### ZSH + Starship\n\n### Command line utilities\n\n// TODO list them here\n\n## Why?\n\nOn a regular job day (from Monday to Friday), I almost end using three different machines along the day. \nMy main coding workstation (for personal projects), which is just an **MSi** laptop running exclusively a *Manjaro*,\nmy gaming and secondary code workstation, that runs on *Windows*, and my job workstation, a corporative laptop\nthat runs on *Windows* using native programs and some tools via *WSL2*.\n\nSo I always liked the idea of using the same tools, regarding which operating system I am using at a particular moment.\nBut that's a hard thing to acomplish, because I also tend to be happier using community-driver open source tools (or at least, open source), and the tools have\nto be crossplatform by default or at least, be available in runtimes like `Cygwin` or `Msys2`, or at least, natively compilable in `Windows` via tools like `Mingw`.\n\nThe fact is that, all the tools presented below are easy to get, or they already come with your Linux installation. So simply.\nYet `Windows` is another thing.\n\n## How?\n\nThis is a git bare repo. The technique consists in storing a Git bare repository in a \"side\" folder (like $HOME/.cfg or\nwhatever) using a specially crafted alias so that commands are run against that repository and not the usual `.git`\nlocal folder, which would interfere with any other *Git* repositories around.\n\n### The alias `config`\n\nBy having the **config** alias set, now I can invoke *Git* from any place, and it will now that I am interacting\nwith my configuration bare repository. So I can be in any place an directly add anything that I want to be track by\nmy configuration repository.\n\n## Prerequisites:\n\nThese are the mandatory general prerequisites in order to succesfully install the dotfiles and all the tools described above\nthat conforms this setup\n\n- `Git`\n- `Rust` with `Cargo` and `Golang`\n\n\u003e [!CAUTION]\n\u003e\n\u003e Note for myself. Remember to create `Github` actions to check that the packages are installable without problem in\n\u003e all the supported OS\n\n## Linux machines (`pacman` based)\n\n\u003e [!WARNING]\n\u003e\n\u003e This documentation assumes that `Linux` distros will be any kind of `Arch` variants, or that they use (or they have installed)\n\u003e `Pacman` as package manager. If your distro doesn't have `pacman` you can download it.\n\nSince almost any `Linux` flavour comes with a `Git` installation\n\n\u003e [!CAUTION]\n\u003e\n\u003e Note for myself. Remember to check in the bash script for the presence of `pacman` in the system.\n\u003e If not present, just install it, so we can make more kind of distros compatibles with this *setup*\n\n\u003e [!TIP]\n\u003e\n\u003e If you plan to use this guide for install the *setup* only on `Linux`, just go to the `Installation` section\n\n## Windows\n\nWell, this setup is not exactly easy to replicate in a `Windows` machine. The fact is that requires a lot of configurations and tools that aren't\navailable in `Windows` by default, nor are easy to understand how to emulate it/natively compile them, since all the tools are `Unix` based.\n\nAs said, as developers we most of the time need the ***Microsoft's Visual Studio** tools at some point. And even that some of them are great tools\n(for example, `MSVC` and the `C++` tools are comfortable, and `MS Studio` is really a great editor) the idea of this setup is to have a unique set of\ntools sharable between any `OS` and completly **open source** based, as stated before.\n\n### The key in Windows, [MSYS2](https://www.msys2.org/)\n\n**MSYS2** is a collection of tools and libraries providing you with an easy-to-use environment for building, installing and running native Windows software.\n\nFor more details see ['What is MSYS2?'](https://www.msys2.org/docs/what-is-msys2/)\n\nSo basically, the first step to get everything running in Windows is to download the installer. So click on the hyperlink, download it\nand then double click on your installer.\n\n\u003e [!NOTE]\n\u003e\n\u003e Installation extremely fast-forward process, the unique doubt could be the installation location. `MSYS2` is typically well placed directly\n\u003e under `C:\\`. You can install it in other place, but this guide assumes that you will be using `C:\\msys64`, as recommended in their documentation.\n\nYou'll see the in latest slide of the installation prompt a ticked checkbox asking you for execute `msys2` now. Discard it and close the installation prompt.\n\nNow, on the `Windows` search bar, type msys2, and open the \"purple\" shell (msys2 msys), and type:\n\n```bash\npacman -Syu\n```\n\nObviously, type **[Y]** and hit `Enter`. This will update your `msys2` subsystem with the latest packages.\n\nWhen ends, open the `mingw64` *msys2* shell and do the same. When it ends, run the following:\n\n```bash\npacman -S --needed base-devel mingw-w64-x86_64-toolchain mingw-w64-clang-x86_64-llvm\n```\n\n\u003e Don't miss this by any chance, since it will be required later to fully complete our `Rust` installation targeting the `GNU` ABI.\n\n### Setting the **HOME** environmental variable and\n\nMost of the `POSIX` compliant tools available via `MSYS2` will look for an environmental variable known as `$HOME` to resolve some\nPATH when certain actions requires it. The quickest and universal way of solving this is to set a new `Windows` system variable\npointing directly to the user's root directory. Simply open a new `cmd` with administrator privileges and type:\n\n```cmd\nsetx HOME \"%USERPROFILE%\"\n```\n\nThis also will do a nice and neat thing, that will turbo overpower our `dotfiles` configuration. Use **HOME** as the *MSYS2* user's root directory.\nYes, this implies that now, instead of being `/home/user` the user's home directory from within `MSYS2`, it will be the *Windows* native\nuser's home directory.\n\nThat will allow us to avoid any kind of path conflicts with certain tools that are expecting to have their dotfiles at a certain place (based on Unix paths)\nnow pointing to the most logical place in Windows that are eventually the equivalent of the `Linux` ones.,lk\n\n### \nIn order to enhace how the dotfiles are easily shared among different `OS`, we can use our Windows *HOME* folder as the home folder for MSYS2\ninstead of the one that comes by default with the `MSYS2` installation. So, edit `/etc/nsswitch.conf` and write:\n\n```\ndb_home: windows\n```\n\n`%USERPROFILE% will be resolved to your user's Windows directory, and will be permanently added to the Windows **PATH**\n\n\u003e Don't close yet this cmd shell, since you'll need it again briefly\n\n### The `clang64` enviroment.\n\nNow, type `clang64` on the Windows search bar, and open such prompt. Then, run again `pacman -Syu`.\n\nYou can learn more about this `msys2` enviroment and more about all of them [here](https://www.msys2.org/docs/environments/). I'll recommend you\nto take your time to carefully read about them. Isn't an easy thing to grasp at first if you're not experienced in this kind of complex setups, \nso take a deep breath and just **read the docs**. // TODO pls insert meme here\n\nThe very key thing about here is that you'll have all the coolest environment configuration available to work with the `llvm-suite` compiler tech and build\namazing software with them. But for such thing we will need first to gather our `clang` compiling tools.\nOpen the `msys2 clang64` shell, and paste the following:\n\n```bash\npacman -S mingw-w64-clang-x86_64-{make,cmake,ninja,clang,libunwind,clang-tools-extra,gcc-compat,diffutils} \n```\n\n\u003e [!NOTE]\n\u003e\n\u003e // TODO can we change all the `clang` separated tools for the [`MSYS2 llvm-suite package`](https://packages.msys2.org/package/mingw-w64-x86_64-llvm)\n\u003e \n\u003e // TODO explain why what one of the few things that we change about the general recommendations of `MSYS2` official docs is to use a different\n\u003e shell rather than the default one of the mingw one\n\n### Git in Windows\n\n`Git` is the fastest and universal version control system out there. There's no other rival in terms of what `git` is capable of doing, and is widely\nadopted in all the open-source community as well as in the most of companies out there. Also, is the core \"trick\" of the *dotfiles* repo.\n\n\u003e [!WARNING]\n\u003e\n\u003e This step isn't easy to get it working. Be really cautious doing the steps described below, or you'll likely end running into issues and you'll\n\u003e need to start your work from scratch\n\n\u003e [!CAUTION]\n\u003e\n\u003e This guide is tested on fresh `Windows` installs and on `Windows` machines that already have a `Git` installation.\n\u003e If you already have `git` installed (most likely via `git-for-windows` and don't want to be scratching your head) you can skip it.\n\u003e If you plan to fully complete the guide, please remove any previous `Git` installation from your machine.\n\nIn order to install `git` on Windows from here, there's now three different options available:\n\n1. Install the `Git for Windows` project. This uses a custom `msys2` self-contained `msys2` environment, slightly different from the upstream one. But it has some advantages, like a GUI installer, based on *click, accept, next* and it is ready to go. It is nice, and if you don't want to complicate thing you may consider it as you option.\n2. Using the `msys2` git installation. Since we already have a `msys2` installation, and you don't care about performance, you could use the already embeed git (posix compliant) git installation on the `msys2 msys` base environment. But it has its flaws. Since is in the *msys* environemnt, it works on the *POSIX* emulation layer, using the `msys` runtime tools and shared libraries. This has the downside that it will introduce overheat to the git binary tools when you invoke it, specially noticeable when you work with medium to large *git* based projects.\n3. Use the `mingw` based *git* installation. This is far the most complicated one to set up, but it has the best of both worlds. It is performant (since is natively compiled for *Windows*) and you can't avoid to install yet another `git` tool on your system, polluting your development environment with more and more binaries, potentially running into **PATH** issues when invoking tools and other stuff. **This guide will use this approach**, but feel free to use the one that better suits your purposes.\n\n#### [Install GIT inside MSYS2 proper](https://github.com/git-for-windows/git/wiki/Install-inside-MSYS2-proper)\n\nFirst of all, follow the hyperlink on the header above. They will have the latest known working documentation to understand and efficiently install\n**Git** inside **MSYS2** properly. Is not exactly easy and you can run into some issues (even they are unlikely) so I warn you to read first all the documentation and then go again from the beggining, so you can jugde by yourself if this method really suits you.\n\nAfter you read the documentation, you can go back here, and start working in the installation.\n\n\u003e [!NOTE]\n\u003e\n\u003e There's only one minor difference, I'll skip the usage of the *32 bits* `mingw32` installation.\n\u003e So, open the `msys2 mingw64` shell, and start to work in the points of the list below:\n\n1. Make a backup for just in case if anything goes wrong, by typing:\n```bash\ncp /etc/pacman.conf /etc/pacman-bu.conf\n```\n\n2. Run:\n```bash\nsed -i '/^\\[mingw32\\]/{ s|^|[git-for-windows]\\nServer = https://wingit.blob.core.windows.net/x86-64\\n\\n|; }' /etc/pacman.conf\n```\n\n3. Ensure that everything went fine, by typing: ```cat /etc/pacman.conf``` and ensure that there's a new entry for `[git-for-windows]`\n4. To avoid the future signature related issues, run the following commands first\n\n```bash \nrm -r /etc/pacman.d/gnupg/\npacman-key --init\npacman-key --populate msys2\n```\n\n5. Authorize the signing key with:\n\n```bash\ncurl -L https://raw.githubusercontent.com/git-for-windows/build-extra/HEAD/git-for-windows-keyring/git-for-windows.gpg |\npacman-key --add - \u0026\u0026\npacman-key --lsign-key E8325679DFFF09668AD8D7B67115A57376871B1C \u0026\u0026\npacman-key --lsign-key 3B6D86A1BA7701CD0F23AED888138B9E1A9F3986\n```\n\n6. Then synchronize with new repositories with ```pacman -Syyuu```. This will install a different `msys2` runtime, and you'll probably see a `downgrade` version message. Don't worry at all, just press `[Y]` and proceed with the installation. Then, you'll be asked to shutdown your `msys2` tools, press `[Y]`.\n\n7. Open again the `mingw64` environment shell, and ```pacman -Suu``` to syncronize the remaining tools.\n\n8. And finally install the packages containing Git, its documentation and some extra things:\n\n```bash\npacman -S mingw-w64-x86_64-{git,git-doc-html,git-doc-man} mingw-w64-x86_64-git-credential-manager\n```\n\n\u003e [!CAUTION]\n\u003e\n\u003e I've modified the last step to remove the `git-extra` package, since it modifies the `MSYS2` instalation heavily, and doesn't bring any\n\u003e advantages to my workflow nor enhace my tools. Read the extra steps carefully if you think that is worth for you, and just run the installation\n\u003e command with `pacman`.\n\n\u003e [!TIP]\n\u003e\n\u003e Also, I added there the `git-credential-manager` package, since it's a **must have** for any comfortable workflow. \n\nAnd this would be all. Close you shell and re-open it again. Type:\n\n```bash\n  git --version\n```\nand if git shows version details without issues, the installation process will be complete.\n\n### Adding `MSYS2` shells to the Windows Path\n\nThis is a critical and crucial step. You see how easy where installing software, but what about using it?\n\nI won't use the `Mintty` term of `MSYS2` for anything but install software. I want to use other terminals, like `Wezterm` or `Alacritty`, and have\nall my tools on path available. This is an easy one step. You can add the `/bin` folders where your `MSYS2` gathered tools lives via the **Windows GUI**\napproach, or just open a `cmd` shell with **Administrator** privileges, and type the following:\n\n```cmd\nsetx PATH \"%PATH%;C:\\msys64\\mingw64\\bin;C:\\msys64\\clang64\\bin;C:\\msys64\\usr\\bin;C:\\msys64\\usr\\local\\bin;C:\\msys64\\opt\\bin;\"\n```\n\n\u003e [!NOTE]\n\u003e\n\u003e This is the magic step where everything makes sense. From now, any tool that you install via `MSYS2` (and should be any one available via *MSYS2* in this world)\n\u003e would be directly available from any point in your *Windows* installation. That's what will make you to be amazed, since you can have any tool that you like\n\u003e even the ones from `Linux` running natively or emulated if its only available in the msys2 runtime in your *Windows* installation.\n\n## Setting the `SSH` agent to authenticate over SSH\n\n\u003e [!NOTE]\n\u003e\n\u003e It is recommended to follow the `GitHub` documentation in order to use GitHub remote actions with authentication via `SSH`. If you plan to stick\n\u003e with the legacy `HTTPS` way, you can skip this step.\n\n\u003e [The steps below are obtained from here](https://docs.github.com/en/authentication/connecting-to-github-with-ssh/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent)\n\n1. Open a `cmd` shell without *elevated permissions* and paste the chunk below, replacing the email used in the example with your GitHub email address\n```cmd\nssh-keygen -t ed25519 -C \"your_email@example.com\"\n```\n2. When you're prompted to \"Enter a file in which to save the key\", you can press Enter to accept the default file location. Please note that if you created SSH keys previously, ssh-keygen may ask you to rewrite another key, in which case we recommend creating a custom-named SSH key. To do so, type the default file location and replace id_ALGORITHM with your custom key name.\n3. Open a new Powershell instance to ensure that the *ssh-agent* is active and running. If isn't the case, it will be spawned\n```powershell\nGet-Service -Name ssh-agent | Set-Service -StartupType Automatic\nStart-Service ssh-agent\n```\n4. Now come back to the previous `cmd` shell, and add the previous generated *ssh-key* to the *ssh agent*\n```cmd\nssh-add \"%USERPROFILE%\"/.ssh/id_ed25519\n```\n5. If everything went correct, you'll see a message like this one:\n```cmd\nC:\\Users\\\"YourWindowsUser\"\u003essh-add \"%USERPROFILE%\"/.ssh/id_ed25519\nEnter passphrase for C:\\Users\\\"YourWindowsUser\"/.ssh/id_ed25519:\nIdentity added: C:\\Users\\\"YourWindowsUser\"/.ssh/id_ed25519 (alex.vergara.dev@gmail.com)\n```\n\u003e Remember to use the same identifier that you used to generate the *ssh key*\n\n\u003e If you used a `bash` based shell instead of `cmd`, remember to change `%USERPROFILE%` for `$HOME`, to correctly expand the value of the user's root directory\n\n6. Copy the public ***SSH*** key to the clipboard\n\n`Unix shells`\n\n```bash\nclip \u003c ~/.ssh/id_ed25519.pub\n```\n`Windows CMD`\n\n```cmd\nclip \u003c \"%USERPROFILE%\"/.ssh/id_ed25519.pub\n```\n\n7. Now follow the remaining steps directly from the [GitHub SSH documentation](https://docs.github.com/en/authentication/connecting-to-github-with-ssh/adding-a-new-ssh-key-to-your-github-account) to add the generated key to your *GitHub* account\n\n## Installing Rust\n\nNo secret for anyone. I just love `Rust`. But not only the language, the full ecosystem. And that's includes my favourite tool, `Cargo`.\nAs you may notice, now we have available a `Unix` like environment within `Windows` thanks to `MSYS2`. Also, we have a `bash` like terminal,\nand all the typical command line utilities that we've expected to work, like `grep`, `awk`, `seed` and so on and so forth.\n\nThe thing is that, after years of using them, they are quite obsolete. They need hard syntax sometimes to acomplish a simple task, and they don't\nlook really modern nor are extremely productive to abrange a wide variety of levels of kwoledge of the command line utitiles.\n\nSo I thought one day, didn't someone rewrite these tools in `Rust`, make them modern, solving their issues, make them *cross-platform* by default\nand available directly with a simple command like `cargo install \"--args...\"?`\n\nThe answer is a tremendous ***YES***, but first we need to have `Cargo`, so we will install `Rust`.\n\nBut, for having the full advantage of open-source tools, we will go further. `Rust` installation is managed via a command line utility known as `rustup`.\n`rustup` let's you easily manage every aspect of your `Rust's` installation, and even install multiple different `toolchains` in your machine.\n\n### `Rust` on Linux\n\nJust go to the `Rust` home page, and follow the download/installation instructions. Accept everything by default. You're good to go.\n\n### `Rust` on Windows using the `GNU` ABI via the `windows-pc-gnu` target triple\n\nIn `Windows`, by default `Rust` will need to have the `MSVC` tools to work. That means to use the `Windows` native API, the `MSVC` linked and others.\nBut, since we've installed `MSYS2`, we have all the `GCC GNU` utilities, and `Rust` has first class support (even in Windows) for using them.\nAnd even more, we even can go further and avoid to use the `GCC` toolchain, and use the ones provided by the `llvm-project`, the umbrella project to which\n`clang` (for example) belongs and the tools that created the `Rust` compiler itself.\n\nOpen the `mingw64` terminal or any of the `MSYS2` terminals and run the following:\n\n```bash\ncurl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- --no-modify-path\n```\n\nA prompt will appear. Do this in order:\n\n    - choose \"Continue? (y/N)\" by typing y and hitting the Enter key.\n    - choose \"2) Customize installation\" using the keyboard.\n    - paste or type the option: `x86_64-pc-windows-gnu`.\n    - press enter for the `stable` version (unless you want other compiler version).\n    - I will select `complete` in the next step. Press enter to get the default, which probably fits your needs.\n    - then press Enter, to choose the option \"1 to proceed\" with the Current installation options.\n\n\u003e [!NOTE]\n\u003e\n\u003e Technically, there's packages for the different flavours of `MSYS2` to download `Rust`, like [this](https://packages.msys2.org/package/mingw-w64-x86_64-rust)\n\u003e The problem is that misses one key component, [`rustup`](https://rust-lang.github.io/rustup), which allows us to quickly download and interchange between *toolchains*\n\u003e among other niceties, like installing `nightly` versions of the compiler to test the latest and/or unstable features.\n\u003e If you plan to stick with the `gnu` variant triple and the `stable` channel, it could be a better option to consider.\n\n\u003e ***And that's all. We can compile `Rust` code in `Windows` without requiring any of the `MSVC` Microsoft tools!***\n\n\u003e [!TIP]\n\u003e\n\u003e When targeting the GNU ABI, no additional software is strictly required for basic use. However, many library crates will not be able to compile until the full `MSYS2`\n\u003e with MinGW has been installed. That's why we installed the full `mingw-w64-x86_64-toolchain` previously.\n\n## The ***dotfiles*** installation process\n\nAssuming that you're on the **ROOT** of your users directory. `~` on **Unix** or `%USERPROFILE%` on **Windows**\n\n### Make a backup of your *dotfiles*\n\nYou must do a full backup of any of your `dotfiles` before cloning and checkout the bare repo to avoid running into any merge conflict.\nTake a look at the root of this repo and see what files you have per duplicated, and directly move them to any other place.\nI recommend you to create a new folder in your home directory and move them there.\n\n\u003e The most important one that you must backup is your `.gitconfig` file, and later replace it again with the one cloned from this repo,\n\u003e or directly add your `user details` and save my configuration if it suits you\n\n### Cloning and installing:\n\n\u003e [!TIP]\n\u003e\n\u003e Optional:\n\u003e If you're on *Windows*, as the time of writing your system most likely come with `Windows Terminal` by default.\n\u003e So pick a `cmd` shell and run `C:\\msys64\\usr\\bin\\env MSYSTEM=MINGW64 MSYS2_PATH_TYPE=inherit C:\\msys64\\usr\\bin\\bash -i -l`\n\u003e and you'll have a login bash shell powered with the `mingw64` *git for Windows* but from the **MSYS2** installation\n\n1. [Windows only] Ensure that you did everything properly before and run ```bash pwd``` and check if your opened shell points to your native *Windows* home directory\n2. `git clone --bare git@github.com:TheRustifyer/dotfiles.git \"$HOME\"/.cfg` (replace the URL for the *HTTPS* variant if you need)\n3. `git --git-dir=\"$HOME\"/.cfg/ --work-tree=\"$HOME\" checkout`\n\n\u003e [!NOTE]\n\u003e\n\u003e Just copy and paste the second point for checkout and directly \"install\" the configuration files.\n\u003e Other tutorials configure again the alias for the bare repo and the gitignore, which will cause merge conflicts, and it's completely unnecesary.\n\u003e As stated, use the provided commands above to cleanly install the dotfiles. The `config` alias will be set up later automatically.\n\n## Completing the setup\n\nIn your checked-out bare repo there's a *shell* script, named `build.sh` that is ready to install all the\ntools required to have the setup working. There's a lot of things here, but the script is ready to accept command line arguments, so we can better choose what\ntools and suites we installed on our machine. So, instead of running the full setup, I'll be listing below the logical steps in order and invoking in different\niterations every set of tools, so we can better know what is happening and better understanding our final configuration.\n\n\u003e [!TIP]\n\u003e\n\u003e Take a moment to read the `build.sh` script and see what tools are available and how\n\n### Getting the font\n\nMy default font is the [`JetBrains Mono`](https://www.jetbrains.com/lp/mono/), that you can download for the hyperlink but if you plan to use `Wezterm`, it already comes\nbundled by default on `Wezterm`.\n\nFor `Alacritty` I have configured [FiraCode Nerd Font](https://www.nerdfonts.com/font-downloads), so you'll need it to make it work properly.\n\n### Terminal tools\n\nRemember when I told you about the `Unix` like tools that could have been rewrite in `Rust`? And that they look modern, have better cmd syntax and that they are\n***extremely performant***? Well, it's time to install them and have them in action.\n\nFrom your user's root directory, invoke the `build` script passing as argument:\n\n```bash\n./build.sh -tt\n```\n\n### Changing the default shell to the `Z` shell\n\n`ZSH`, also called the ***Z shell***, is an extended version of the Bourne Shell (sh), with new features and support for plugins and themes. Since it's based on the same shell as Bash, ZSH has many of the same features, and a lot of new ones no present in `bash` shells.\n\n```bash\n./build.sh -zsh\n```\n\n\u003e [!NOTE]\n\u003e\n\u003e My shell configuration is using [**starship**](https://starship.rs/) as the shell prompt. Take a look at their docs, they're great!\n\n### Getting the terminals\n\nNow is time to complete our setup. And time to choose our core tool, the terminal. You can choose between the alternatives above (or take them all if you like)!\n\n#### Alacritty + Zellij (optional)\n\n1. Download it directly with `Cargo` (the recommened approach):\n\n```bash\n./build.sh -ia\n./build.sh -iz\n```\n2. Build it from source with the git submodule included in the setup\n\n```bash\n./build.sh -ba\n./build.sh -bz\n```\n\n\u003e [!CAUTION]\n\u003e\n\u003e If you're using `Zellij` on `Windows`, you'll need to invoke it with the `-bzw` flag, not with `-bz`\n\n#### Wezterm\n\nJust go to their [downloads page](https://wezfurlong.org/wezterm/installation.html) and choose the installer you need based on your *operating system*\n\n#### Windows Terminal (with the MSYS2 shells configuration) // TODO add the JSON config file to the dotfiles\n\n`Windows Terminal` comes installed by default on any up to date `Windows` installation at the time of writing. If isn't your case, just\ngo to the *Windows store* and download it from there.\n\nI've included in the *dotfiles* a custom configuration that fits better my need, and also added to the dropdown buttom where you can choose the shell\nyou want to open all the `MSYS2` ones.\n\n### The editor: Neovim\n\nWe will gather a fresh installation of `Neovim`. For such purpose, you have two ways, as usual until this point:\n1. With the `mingw64` package installation.\n\n```bash\n./build.sh -ian\n```\n\n2. submodule\n\n```bash\n./build.sh -bnv\n```\n\n\u003e [!TIP]\n\u003e\n\u003e Remember that the advantage of building the tools via the submodules is that you'll have the latest changes implemented in the project, but it could be a less stable\n\u003e tool, if they have an active development workflow.\n\n## Conclusion\n\nIf everything went correctly, you'll have now an incredible, flexible, powerful and modern setup environment. I put a lot of effort on configuring this setup, specially for those who\nuses different OS frequently.\n\nEven if you don't install this *dotfiles* configuration, you'll find a lot of valuable information, and probably some inspiration for do your own! So I'll be happy if I contribute to make your\ndeveloper life easier!\n\n## ADVANCED and mostly optional\n\n### The `llvm-suite` from the last commit on main from upstream\n\nIn the `third-party` folder you'll encounter the `llvm-suite` submodule, which is pointing to the `main` branch of the project. I do love `llvm`. I've been using their technologies\nin the `C++` world for quite a while, and they just made my life easier. Also, they were the inspiration for create [`Zork++`](https://github.com/ZeroDayCode/Zork), among other things.\n\nIf you're an active `C++` developer, and you're following the latest implementations of the standard, or involved in quite modern projects, this will definitly help you.\nFor example, `clangd` the `LSP` server for `C++` and other languages provided with `llvm`, have a lot of incredible updates and fixes from the release of the `v19.x.x`, which will\nallow you having better days using any code editor for a `C++` modules based project.\n\n### The UASM assembler: Cross-Platform Assembly for x86-64\n\nUASM (Universal Assembler) is a versatile assembler that allows you to write assembly code for x86-64 architectures regardless of your operating system. This eliminates the need to rely on platform-specific tools like Visual Studio on Windows or dealing with incompatibility issues between Windows PE files and Linux environments.\n\nKey benefits of using UASM:\n\n- Cross-platform compatibility: Write assembly code once and assemble it on both Windows and Linux using the same toolchain\n- MASM syntax support: UASM supports MASM (Microsoft Macro Assembler) syntax, making it familiar for those comfortable with Windows assembly development\n- Flexibility: UASM offers the ability to target different object file formats depending on your needs, including Windows PE and Linux ELF.\n\n```bash\n./build.sh -uasm\n```\n\n## Extra INFO\n\n### Starting from scratch your *own* `dotfiles` bare repo\n\nIf you haven't been tracking your configurations in a Git repository before, and you want to do it on your own from scratch, or copying the parts of this guide that you're interested, you can start using this technique easily with these lines:\n\n```bash\ngit init --bare $HOME/.cfg\nalias config='git --git-dir=$HOME/.cfg/ --work-tree=$HOME'\nconfig config --local status.showUntrackedFiles no\necho \"alias config='git --git-dir=$HOME/.cfg/ --work-tree=$HOME'\" \u003e\u003e $HOME/.zshrc\n```\n\n## More screenshots\n\nHere you have a collection of screenshots that I like to share, so from time to time I end uploading some new content\nfor people knowing in advance if they would like to steal some of the configurations (or all of them!)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftherustifyer%2Fdotfiles","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftherustifyer%2Fdotfiles","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftherustifyer%2Fdotfiles/lists"}