LinuxPlan/LinuxPlan.md

73 KiB

Linux

Steps

  1. Installation
    • Nixos-KDE/Plasma
    • Rufus-iso (to flash NixOS)
    • Use all the disk
    • Create a boot partition (2GB-vfat), mount it to /boot, add flag boot and name it boot
    • Create a root partition (200GB-ext4), mount it to /, add flag root and name it nixos
    • Create a home partition (720GiB-ext4), mount it to /home and name it home
  2. Su permissions [unecessary]
    • su -
    • usermod -a -G sudo $USER
  3. Apps
    • Nixpkgs
      • 7zip (p7zip)
      • Airshipper/Veloren (airshipper) (airshipper manages veloren)
      • Amd radeon (radeontop)
      • aria2 (aria2, ariang, persepolis) [AB Download Manager alternative]
      • Audacity (audacity)
      • BleachBit (bleachbit) [Eraser alternative]
      • Blender (blender)
      • Bottles (bottles)
      • BoxBuddyRS (boxbuddy)
      • Caprine (caprine) (open source fb messenger client)
      • chattr/lsattr/touch [built-in commands] [Attribute Changer alternative]
      • Codeblocks (codeblocksFull)
      • Cpu-X/Resources (cpu-x/resources) [Cpu-z alternative]
      • Czkawka (czkawka)
      • Darktable (darktable)
      • DB Browser (SQLite) (sqlitebrowser)
      • dd [Built-in command] [Rufus alternative]
      • Deno (deno)
      • Discord (discord) [not_open-source]
      • DiscordChatExporter/Discord-Data-Package-Parser (discordchatexporter-cli)
      • Distrobox (distrobox)
      • dnsmasq (dnsmasq)
      • Double commander (doublecmd)
      • Easy Effects (easyeffects)
      • Eclipse IDE (eclipses.eclipse-sdk)
      • eduVPN (eduvpn-client)
      • Fastfetch (fastfetch) [Neofetch alternative]
      • ffmpeg (ffmpeg_6-full)
      • Filezilla (filezilla)
      • Firefox Beta (firefox-beta)
      • Flatpak (flatpak) #Add repo
      • freac (freac)
      • Freecad (freecad-wayland)
      • GCC (gcc)
      • Gimp (gimp-with-plugins)
      • GMic plugin for Krita (krita-plugin-gmic)
      • GNUmake (gnumake)
      • gocryptfs (gocryptfs,cryptor,sirikali,vaults) [Encfsw alternative]
      • Godot (godot_4)
      • Gparted (gparted)
      • Gsmartcontrol/Smartmontools (gsmartcontrol/smartmontools) [Hard Disk Sentinel/CrystalDiskInfo alternative]
      • HandBrake (handbrake)
      • Hugin (hugin)
      • Inkscape (inkscape-with-extensions)
      • IProute2 (iproute2)
      • Jellyfin media player (jellyfin-media-player)
      • Jellyfin server (jellyfin)
      • K3b (kdePackages.k3b) [Nero burning rom alternative]
      • Kate (kdePackages.kate)
      • KDEconect (kdePackages.kdeconnect-kde)
      • KDevelop (kdevelop)
      • KeepassXC (keepassxc)
      • Krita (krita)
      • Krusader (krusader)
      • Kubernetes (kubernetes)
      • LibreOffice (libreoffice-qt6)
      • libvirt (libvirt)
      • LRCGET (lrcget)
      • Luanti (minetest)
      • Ludusavi (ludusavi)
      • Lutris (lutris)
      • Mindustry (mindustry-wayland)
      • Minimal adb and fastboot (android-tools)
      • Mpv (mpv)
      • Neovim (neovim)
      • netcat (netcat)
      • Nicotine (nicotine-plus)
      • Nil (nil)
      • NodeJS 22 (nodejs_22)
      • nomacs (nomacs)
      • OBS Studio (obs-studio)
      • Octave (octaveFull)
      • Okular (kdePackages.okular)
      • Olive (olive-editor)
      • OnionShare (onionshare-gui)
      • openjdk-23-jdk (jdk23)
      • OpenRGB (openrgb-with-all-plugins)
      • PDFsam Basic (pdfsam-basic)
      • PhotoRec (testdisk-qt) [Recuva alternative]
      • Piper (piper) [Logitech G HUB alternative]
      • Piper TTS (piper-tts)
      • Piperwire [built-in option (services.pipewire)]
      • Podman (podman)
      • Podman Compose (podman-compose)
      • Podman Desktop (podman-desktop)
      • Prism (prismlauncher) [TLauncher alternative]
      • Protonup-qt (protonup-qt)
      • ProtonVPN (protonvpn-gui)
      • PSPP (pspp) [SPSS alternative]
      • Python3 (python3Full)
      • Qalculate (qalculate-qt)
      • qBittorrent (qbittorrent)
      • QDirStat (qdirstat) [WinDirStat alternative]
      • Qemu (qemu)
      • QtSpim (qtspim)
      • Quod Libet (quodlibet-full)
      • Rclone (rclone)
      • Restic (restic)
      • Rsync (rsync)
      • Ruffle (ruffle)
      • Rustic (rustic)
      • screego (screego) [screentask altrnative]
      • Show Me The Key (showmethekey) [Keyviz alternative]
      • Signal (signal-desktop)
      • SignalBackup (signalbackup-tools)
      • Siril (siril)
      • Spectacle (kdePackages.spectacle)
      • Spek (spek)
      • Spicetify (spicetify-cli) #spicetify update
      • Spotify (spotify)
      • Stirling (stirling-pdf)
      • Sunshine (sunshine) [Rustdesk alternative]
      • SuperTuxKart (superTuxKart)
      • Syncplay (syncplay)
      • Syncthing (syncthing)
      • Syncthing Tray (syncthingtray)
      • Tenacity (tenacity)
      • Thunderbird (thunderbird)
      • TIPP 10 (tipp10)
      • Tor (tor-browser)
      • Tuckr (tuckr)
      • Umbrello (kdePackages.umbrello) [StarUML alternative]
      • Umu Launcher [github]
      • UV (uv)
      • vde2 (vde2)
      • Virt-Manager (virt-manager)
      • Virt-viewer (virt-viewer)
      • VLC (vlc)
      • Waydroid (waydroid) [Games Google Play beta alternative]
      • Wine (wineWowPackages.waylandFull)
      • Wireguard/OpenVPN (wireguard-ui/openvpn)
      • Wireshark (wireshark)
      • Xournal++ (xournalpp)
      • yt-dlp (yt-dlp)
      • YTDownloader (ytdownloader)
      • Zoom (zoom-us) [not_open-source]
    • Distrobox:
      • None
    • Podman:
      • chat-analytics [podman]
      • DiscordChatExporter-frontend [podman]
    • Scripts:
      • WE NEED TO SETUP UV (OR POETRY)
        • #To-Do
      • ao3downloader (phthallo) [github-script]
      • import-from-spotify.py [local]
      • lyricsgenius [github-script] #pipx install/upgrade lyricsgenius
      • UT61E [github-script]
      • Verbify-TTS OR Bark [github-script]
    • Wine:
      • Counter-Strike: 1.6 [Site] [Wine] [not_open-source] [unmaintained]
      • Hades 1 [Site] [Wine] [not_open-source] [unmaintained]
      • Lossless audio checker [site] [wine] [not_open-source]
      • Metal Gear Rising: Revengeance [Site] [Wine] [not_open-source] [unmaintained]
      • Mp3tag [site] [Wine] [not_open-source]
      • Outer Wilds [Site] [Wine] [not_open-source] [unmaintained]
      • videorepair [site] [Wine] [not_open-source]
    • Flatpak:
      • Flatseal [flathub]
      • Google Earth (googleearth-pro) [flathub] [not_open-source] #insecure on nixpkgs
      • Natron (natron) [flathub] #broken on nixp
      • Thrive Launcher [flathub] [not-available-yet-on-nixpkgs]
    • AppImage:
      • deemix-gui [site] [unmaintained] [not-available-yet-on-nixpkgs]
    • WaitingForNixpkgs:
      • Meshroom [not-available-yet-on-nixpkgs]
      • OneTagger [site] [not-available-yet-on-nixpkgs]
      • OpenGamepadUI [Playnite alternative] [not-available-yet-on-nixpkgs]
    • Windows VM:
      • Flashpoint [wine]
    • Unecessary:
      • ADBFileExplorer [github] [script-zip] [unecessary]
      • Bauh [unecessary]
      • ChoEazyCopy [unecessary]
      • DeepSkyStacker [unecessary] [not_open-source]
      • dell-powermanager [github] [not-available-yet-on-nixpkgs] [unecessary]
      • Geany (with plugins) [unecessary]
      • Gif2apng-apng2gif [site/github-scripts] [unmaintained] [unecessary]
      • Helium [github] [unmaintained] [unecessary]
      • Heroic [flathub] [unecessary]
      • hhocalculator [unecessary]
      • HTTrack [unecessary]
      • LaunchyQt [github-script] [unecessary]
      • offline explorer [site] [Wine] [unecessary] [not_open-source]
      • Playnite [unecessary]
      • PulseAudio (pulseaudioFull) [unecessary]
      • Rclone Shuttle [github] [unecessary]
      • Simplest File Renamer [unecessary]
      • siteone-crawler-gui [unecessary]
      • Steam [official] [unecessary] [not_open-source]
      • Team Fortress 2 [steam] [not_open-source]
      • Visual Studio [official] [unecessary] [not_open-source]
      • Wacom [unecessary] [not_open-source]
      • Webex [unecessary] [not_open-source]
      • WinSCP [site] [unecessary]
      • WorkerPDF [sourceforge] [zip] [unmaintained] [unecessary]
      • Session (messanger) [unecessary]
      • Winmerge [unecessary]
      • Διερμηνευτής της ΓΛΩΣΣΑΣ [site] [unecessary] [not_open-source]
    • Apps to paste in Configuration.nix:
      • #(inputs.umu.packages.${pkgs.system}.umu.override {version = "${inputs.umu.shortRev}";}) #UmuLauncher, we use system wine instead
      • #gimpPlugins.resynthesizer #broken
      • #git #managed by home-manager
      • #googleearth-pro #insecure #non-free #flathub
      • #kdePackages.umbrello #broken
      • #natron #broken when building #flathub
      • #poetry #uv is probably better
      • #protonup-qt #unecessary
      • #spicetify-cli #spicetify update #We will set it up differently!
      • airshipper
      • android-tools
      • aria2
      • ariang
      • audacity
      • bleachbit
      • blender
      • bottles
      • boxbuddy
      • caprine
      • codeblocksFull
      • cpu-x
      • cryptor
      • curl
      • czkawka
      • darktable
      • deno
      • discord #non-free
      • discordchatexporter-cli
      • distrobox
      • dnsmasq #Integrated DNS, DHCP and TFTP server for small networks
      • doublecmd
      • easyeffects
      • eclipses.eclipse-sdk
      • eduvpn-client
      • fastfetch
      • ffmpeg_6-full
      • filezilla
      • firefox-beta
      • flatpak #Addrepo
      • freac
      • freecad-wayland
      • gcc
      • gimp-with-plugins
      • gnumake
      • gocryptfs
      • godot_4
      • gparted
      • gsmartcontrol
      • handbrake
      • hugin
      • inkscape-with-extensions
      • iproute2 #bridge-utils is deprecated
      • jdk23
      • jellyfin
      • jellyfin-media-player
      • kdePackages.k3b
      • kdePackages.kate
      • kdePackages.kdeconnect-kde
      • kdePackages.krfb
      • kdePackages.okular
      • kdePackages.spectacle
      • kdevelop
      • keepassxc
      • krita
      • krita-plugin-gmic
      • krusader #Worse than doublecmd
      • kubernetes
      • libreoffice-qt6
      • libvirt #The libvirt-deamon that runs virtualisation in the back
      • lrcget
      • ludusavi
      • lutris
      • mindustry-wayland
      • minetest #switch to luanti in the future
      • mpv
      • neovim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
      • netcat #TLS/SSL implementation
      • nicotine-plus
      • nil
      • nodejs_22
      • nomacs
      • obs-studio
      • octaveFull
      • olive-editor
      • onionshare-gui
      • openrgb-with-all-plugins
      • openvpn
      • p7zip
      • pdfsam-basic
      • persepolis
      • piper
      • piper-tts
      • podman
      • podman-compose
      • podman-desktop
      • prismlauncher
      • protonvpn-gui
      • pspp
      • python3Full
      • qalculate-qt
      • qbittorrent
      • qdirstat
      • qemu #Generic and open source machine emulator and virtualizer
      • qtspim
      • quodlibet-full
      • radeontop
      • rclone
      • resources
      • restic
      • rsync
      • ruffle
      • rustic
      • screego
      • showmethekey
      • signal-desktop
      • signalbackup-tools
      • sirikali
      • siril
      • smartmontools
      • spek
      • spotify #non-free
      • sqlitebrowser
      • stirling-pdf
      • stow
      • sunshine
      • superTuxKart
      • syncplay
      • syncthing
      • syncthingtray
      • tenacity
      • testdisk-qt
      • thunderbird
      • tipp10
      • tor-browser
      • tree
      • tuckr
      • uv
      • vaults
      • vde2 #Virtual Distributed Ethernet, an Ethernet compliant virtual network
      • virt-manager #gui VM manager
      • virt-viewer #Viewer for remote virtual machines
      • vlc
      • wget
      • wineWowPackages.waylandFull
      • wireguard-ui
      • wireshark
      • xournalpp
      • yt-dlp
      • ytdownloader
      • zoom-us #non-free
    • Nix code:
      • Umu Launcher
        *flake.nix*
        inputs = {
        umu = {
        	url = "git+https://github.com/Open-Wine-Components/umu-launcher/?dir=packaging\/nix&submodules=1";
        		inputs.nixpkgs.follows = "nixpkgs";
        	};
        }
        
        *configuration.nix*
        {inputs, pkgs, ... }:
        {
        	environment.systemPackages = [  (inputs.umu.packages.${pkgs.system}.umu.override {version = "${inputs.umu.shortRev}";})  ];
        }
        
      • Podman
        *configuration.nix*
        virtualisation = {
            containers = {
            enable = true;
            };
            waydroid = {
            enable = true;
            };
            podman = {
            enable = true;
        
            # Create a `docker` alias for podman, to use it as a drop-in replacement
            dockerCompat = true;  #useful for distrobox too
        
            # Required for containers under podman-compose to be able to talk to each other.
            defaultNetwork.settings.dns_enabled = true;
            };
        };
        
  4. Flatpak
    • Enable flathub repo
      • sudo flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
    • Install apps
      • sudo flatpak install flathub com.github.tchx84.Flatseal #Flatseal
      • sudo flatpak install flathub fr.natron.Natron #Natron
      • sudo flatpak install flathub com.revolutionarygamesstudio.ThriveLauncher #Thrive Launcher
      • sudo flatpak install flathub com.google.EarthPro #Google Earth Pro
  5. AppImage
    • Enable appimages globally
      *configuration.nix*
      programs.appimage = {
          enable = true;
          binfmt = true;
      };
      
  6. Podman
    • Containerfile/Dockerfile
      • Like a makefile, it creates a container based on its instructions
    • Images
    • Containers
      • Inside these our programs run (somewhat) isolated
    • Pods
      • Clusters of containers (like in Kubernetes)
    • Volumes
      • When the container needs to be able to share something with the host
      • When the container runs, any volumes which are shared with it, will appear inside the user namespace as owned by root/root
    • To create containers declaretively
      *configuration.nix*
      virtualisation.oci-containers.containers."$CONTAINER_NAME" = {
          image = "$IMAGE_LINK";
          extraOptions = ["$OPTION1" "$OPTION2"];
          ports = ["$PORT_START:$PORT_END"];
      };
      
      • where:
        • $CONTAINER_NAME is the name of the container, like echo-http-service
        • $IMAGE_LINK is the link to the image of the container, like "hasicorp/http-echo:latest"
        • $OPTION1, $OPTION2 are options we can use (we can use as many as we want, not 2 exactly), like -text='Hello, World!' and --network=web respecively
        • $PORT_START and $PORT_END are the port numbers we use to create a range of ports, like 5678 and 5678 respectively (in this example it only uses the port 5678)
    • Podman-desktop
      • Settings/Prefernces/Experimental (Docker Compatibility)
        • Turn on Enabled
      • Images/Pull
        • Add your image (either type it or paste the link for docker hub tags tab of the project)
      • Containers/Create
        • Create your container, by selecting the image you want and clicking the run button
        • Add container name and anything else
        • Optionally create the container inside a pod (a cluster of containers)
      • Container/Terminal
        • cat /etc/*release #shows the distro info about the container
        • you can run commands that the distro version of the container supports (will probably be different that the host's distro), like apt update
      • Find the local port the container runs, open browser and type http://localhost:$PORT, where $PORT is the port of the container
      • Might be a good idea to update and upgrade the repos of the container
  7. Git
    • Configure git
      • In home-manager
      *home.nix*
      programs.git = {
          enable = true;
          userName = "$USERNAME";
          userEmail = "$EMAIL_ADDRESS";
      };
      
      • where:
        • $USERNAME is the username your account
        • $EMAIL_ADDRESS is the email address of your account
      • Run ssh-keygen to create ssh keys for your device
      • Add the public ssh key (usually stored in ~/.ssh/id_ed25519.pub) to your git server account (in Settings/SSH and GPG keys/SHH keys/New SHH key) and add a title to your key
    • GNU Stow (Tuckr is still under development)
    • Files to be versioned
      • Nix configs (os configs)
      • .dotfiles (app configs)
    • Enable git versioning
      1. Move all dotfiles in ~/dotfiles/
      2. Keep the file structure as if ~/dotfiles is ~/
      3. Sync this folder with a git server
      4. Navigate into ~/dotfiles/ and run the sync-dotfiles.sh script (change origin to main) or run stow . (the script is in ~/dotfiles/.bin/)
    • Home-manager .dotfiles [unecessary]
  8. Gaming
    • Bottles [Winner]
    • Lutris [2nd Winner]
    • Umu Launcher [to be used when using proton]
    • Heroic [unecessary]
    • Proton-qt
    • Wine:
      • Main runners:
        • wineWowPackages.waylandFull (sys-wine)
        • wine-ge-proton (wine ge version)
        • proton or umu (in the future, to be used as umu launcher)
      • Search dependencies at https://steamdb.info
      • Enable discrete graphics by default
      • Enable 32bit graphics support (very important to run openGL games)!
        *configuration.nix*
        # Enable 32bit support (for openGL wine'd games!!!)
        hardware.graphics.enable32Bit = true;
        
  9. Text editor
    • Kate [winner]
      • Configure
      • Add lsp servers
    • Notepad++ (Wine)
    • Geany [2nd winner]
    • NotepadNext
    • Textadept
  10. Import App data/configs (add [verified] to each when sure that it works) (mention only changes to default settings in wine)
    • Codeblocks [complete]
      • Settings/Editor/Compiler/Global Compiler Settings/
        • Compiler Flags (check):
          • Have gcc follow the 2011 ISO C language standard [-std=c11]
          • Enable all common compiler warnings (overrides many other settings)
        • Other compiler options (write the following):
          • -finput-charset=cp1253
          • -fexec-charset=cp737
    • Double commander [complete]
      • C:\Users\%USERNAME%\root\Archives\Backups\Linux-Transition [DELETE ONCE TRANSITIONED]\Double commander\
      • C:\Users\%USERNAME%\AppData\Roaming\doublecmd\
    • Firefox Beta [complete]
      • Addons:
        • Enabled:
          • Absolute Enable Right Click & Copy
          • Consent-O-Matic
          • Download All Images
          • Facebook Container
          • Firefox Multi-Account Containers
          • Firefox Relay
          • Link Gopher
          • Neat URL
          • Old Reddit Redirect
          • Plasma Integration
          • PopUpOFF - Popup and overlay blocker
          • Reddit Enhancement Suite
          • Return YouTube Dislike
          • Ruffle - Flash Emulator
          • Tampermonkey
          • uBlock Origin
          • Video DownloadHelper
          • Web Archives
          • YouTube High Definition
          • Youtube Playlist Duration Calculator
          • Youtube-shorts block
        • Disabled:
          • Cisco Webex Extension (disabled)
          • History Export (disabled)
          • Privacy Badger (disabled)
          • To Google Translate (disabled)
          • Tweaks for YouTube (disabled)
      • Addons extra configs:
        • Tampermonkey
        • Neat URL
          • Blocked parameters
            • igsh*@instagram.com
        • Ublock Origin
          • Filters list
            • Enable too:
              • Cookie notices
              • Social widgets
              • Annoyances
              • Regions, languages/gr-cy
          • My filters [#To-Do]
            accounts.google.com/gsi/iframe/$subdocument
            
            ! 2024-02-27 https://ostechnix.com
            ostechnix.com##div.tocSticky.hide-table.penci-sticky-toc.sticky-left.penci-toc-container-wrapper:nth-of-type(4)
            ostechnix.com##div.tocSticky.hide-table.penci-sticky-toc.sticky-left.penci-toc-container-wrapper:nth-of-type(3)
            
            ! 2024-03-22 https://www.instagram.com
            www.instagram.com##._abcm._aa5t._abck._abci._abcg._abcf._abab._ab9-._abby._abbg._ab9p._ab9m._ab9h._ab9c._ab99._ab94._ab8w._ab8q
            
            ! 2024-04-30 https://stackoverflow.com
            stackoverflow.com##.g16.jc-space-around.fd-column.d-flex.bs-lg.py32.px128.hs2.w100.s-card.z-modal.l0.b0.ps-fixed
            
            ! 19 Ιουν 2024 https://www.pinterest.com
            www.pinterest.com##.Hsu.iyn.zI7.p6V.ojN.jzS.imm.fte.fev.dxm._he.PKX.Lej.LCN.KS5.Jea
            
            ! 8 Νοε 2024 https://docs.amd.com
            docs.amd.com##.footer-links
            docs.amd.com##.footer-copyright
            
            
        • YouTube High Definition
          • Video Quality: 1080p
          • Video Size: Theater
          • Video Speed: 1.25
          • Video Volume:
          • Video Subtitles: On
          • Leave rest as default
        • Reddit Enhancement Suite
          • Backup & Restore C:\Users\%USERNAME%\Downloads\ForNixos\RES-2025-01-02-1735834708-5_24_7.resbackup
      • Bookmarks
        • C:\Users\%USERNAME%\Downloads\ForNixos\ (Native export)
      • History
        • C:\Users\%USERNAME%\Downloads\ForNixos\ff-history\ (History Export addon)
      • Profile
        • C:\Users\%USERNAME%\AppData\Local\Mozilla\Firefox\Profiles\
        • C:\Users\%USERNAME%\AppData\Roaming\Mozilla\Firefox\Profiles\
      • Settings
      • Theme
    • Logitech Gaming Software [complete]
      • Files:
        • C:\Users\%USERNAME%\AppData\Local\Logitech\
    • MusicBee [complete]
      • Files:
        • C:\Users\%USERNAME%\AppData\Roaming\MusicBee\
        • C:\Users\%USERNAME%\Music\MusicBee\
    • Notepad++ [complete]
      • Files:
        • C:\Users\%USERNAME%\AppData\Roaming\Notepad++\
    • FirefoxProfileSwitcher [complete]
    • MorphVOX Pro [complete]
      • Files:
        • C:\Users\%USERNAME%\AppData\Roaming\Screaming Bee\
    • Mindustry [complete]
    • nomacs [complete]
      • Edit/Settings/General/Default Settings/Export Settings
      • C:\Users\%USERNAME%\Downloads\ForNixos\nomacssettings.ini
    • OBS Studio [complete]
      • File format: %CCYY-%MM-%DD %hh-%mm-%ss
      • Obs virtual camera
        • obs-studio have officially provided virtual camera feature since version 26.0.0 , you can use it without installing this plugin
    • ~~Signal ~~ [unecessary]
    • Spicetify [complete]
      • Addons:
        • Keyboard Shortcut by spicetify
        • adblockify by ririxi
        • Old Like Button by Maskowh
        • All Of Artist by P4Imeiras
        • Old Cover Click by WaddlesPlays
        • Best Moment by dkqz
        • Nyan Cat Progress Bar
    • SuperTuxKart [complete]
      • Cart addons:
        • Formula by Fingersoft (Round Zero), Roblox
        • Spacecraft by Boombit Games
        • Volans by Kohda Interactive (CrystalDaEevee)
      • Tracks addons:
        • Abyss
        • Beam Runner
        • Cosmic
        • Egypt
        • Evergreen
        • Forest
        • Ice Rink
        • Nitro
        • Soccer
        • Tournament Field
        • Tournament Field (Snowy)
        • XR-4R3N4
        • Zen
        • A Secret (Soccer)
        • Another Soccer Field
        • Antarticy
        • Box
        • Experimental Plane
        • Island Soccer
        • Night Festival
        • OEM Cage
        • Skyline (Soccer)
        • Snooker Table
        • SuperTurnament Field
    • Thunderbird [unecessary]
    • TIPP 10 (tipp10) [complete] [verified]
      • Files:
        • C:\Program Files (x86)\Tipp10\ [unecessary]
        • tipp10v2.db #C:\Users\%USERNAME%\AppData\Roaming\TIPP10\tipp10v2.db #version: 33, soft version: 2.1.0
        • .config #not found on windows, only on linux
    • Counter-Strike: 1.6 [Wine] [complete] [Verified] [60 fps]
      • Site:
        • https://c s16.info/
        • https://ram page.us.lt/ #this seems better, the gt/full version
      • Files:
        • C:\Games\Counter Strike 1.6 GT\config\ #server list
      • Wine config:
        • Win64 system
        • Settings:
          • Runner
            • sys-wine-8.2 (wineWowPackages.waylandFull)
            • wine-ge-proton-8-26 (has issues with mouse movement)
          • Discrete Graphics
            • Enabled
        • Dependencies:
          • allfonts
          • gecko
    • Flashpoint [Wine] [Failed]
      • Install it in Windows VM or Distrobox
      • Wine config:
        • Win64 system
        • Settings:
          • Runners:
            • wine-ge-proton-8-26
            • sys-wine-8.2 (wineWowPackages.waylandFull)
        • Dependencies:
          • allfonts
          • VC 2015 Redist (vcredist2015)
          • .NET 4.7 Redist (dotnet472) (takes around 10 mins and 3 seperate installs to get installed)
          • Wine gecko (gecko) (tried it in case it fixed the issue)
          • Microsoft Edge Web View 2 (webview2) (tried it in case it fixed the issue)
        • Change default installation path, otherwise you will get error (it has no permission to access the I:\Flashpoint path)
          • Flashpoint doesn't want to be installed in C:\Program Files
          • Pick C:\users\$USERNAME\, where $USERNAME is the username of the user
    • Hades 1 [Wine] [Complete] [Verified] [55 fps]
      • Files:
        • C:\Program Files\Hades.v1.38290\ #Program Files
        • C:\Users\%USERNAME%\Documents\Saved Games\ #App data
      • Wine config:
        • Win64 system
        • Settings:
          • Runner
            • wine-ge-proton-8-26
            • sys-wine-8.2 (wineWowPackages.waylandFull) (doesn't run saves)
          • DXVK
            • Enabled
          • VKD3D
            • Enabled
          • Discrete Graphics
            • Enabled
        • Dependencies:
          • allfonts
          • VC 2019 Redist (vcredist2019)
          • .NET 4.7 Redist (dotnet472) (takes around 10 mins and 3 seperate installs to get installed)
    • Metal Gear Rising: Revengeance [Wine] [Complete] [Verified] [30 fps]
      • Files:
        • C:\Users\%USERNAME%\Documents\MGR\ #App data
        • C:\Users\%USERNAME%\root\Games\Video\Computer\windows\MetalGearRising_Revengeance\ #Program Files
      • Wine config:
        • Win64 system
        • Settings:
          • Runners (both work at 30 fps)
            • sys-wine-8.2 (wineWowPackages.waylandFull)
            • wine-ge-proton-8-26
          • DXVK
            • Enabled
          • VKD3D
            • Enabled
          • Discrete Graphics
            • Enabled
          • Discrete Graphics
            • Enabled
        • Dependencies:
          • allfonts
        • In-game settings (Graphics):
          • Turn off Antialiasing
    • Outer Wilds [Wine] [Complete]
      • Wine config:
        • Win64 system
        • Settings:
          • Runner
            • sys-wine-8.2 (wineWowPackages.waylandFull)
          • Discrete Graphics
            • Enabled
        • Dependencies:
          • allfonts
          • VC 2019 Redist (vcredist2019)
          • DirectX Jun 2010 Redist (d3dx9) Source
    • Mp3tag [Wine] [complete] [verified]
      • Files:
        • C:\Users\%USERNAME%\AppData\Roaming\Mp3tag\ #App data
      • Wine config:
        • Wine config:
        • Win64 system
        • Settings:
          • Runner
            • sys-wine-8.2 (wineWowPackages.waylandFull)
        • Dependencies:
          • allfonts
        • Install portable version (option inside the installer)
    • OneTagger [Wine] [complete] [broken]
      • Files:
        • C:\Users\%USERNAME%\AppData\Roaming\OneTagger\OneTagger\ #App data
      • Wine config:
        • Doesn't work with any runner
        • There is a docker image, until it's ported to nixpkgs
    • WinSCP [Wine] [complete] [broken]
      • Wine config:
        • Too much of a hassle, better not (not even the letters can be read, theme prevents it)
        • Probably better use rclone
    • deemix-gui [unecessary]
    • Playnite [complete]
      • CS 1.6: Time played 6:24
      • Metal Gear Rising: Revengeance: Time played 9:18
    • Minecraft [complete]
      • Files:
        • C:\Users\%USERNAME%\AppData\Roaming\.minecraft\
        • C:\Users\%USERNAME%\AppData\Roaming\.tlauncher\
    • ShareX [complete]
      • Files:
        • C:\Users\%USERNAME%\root\Software\Applications\Win64\ShareX\ #App data
      • Screen capture:
        • %y-%mo-%d_%h-%mi-%s-%ms
      • Window capture:
        • %t - %y-%mo-%d_%h-%mi-%s-%ms #%t: title of window
      • Screenshot folder:
        • C:\Users\%USERNAME%\root\images\screenshots
      • Video folder:
        • C:\Users\%USERNAME%\root\Video\Screen-Recording\
    • Libre Office [complete]
      • Settings/Personalisation: Green theme
    • Gimp [complete]
      • Files:
        • C:\Users\%USERNAME%\AppData\Roaming\GIMP\2.10\plug-ins\
    • genius_data_fetcher
      • Files:
        • C:\Users\%USERNAME%\Downloads\1T\Texts\
    • Minimal ADB and Fastboot [complete]
      • Files:
        • C:\Program Files (x86)\Minimal ADB and Fastboot
  11. Import user data/files
    • C:\Drivers
    • C:\Games
    • C:\Program Files
    • C:\Program Files (x86)
    • C:\ProgramData
    • C:\Users\%USERNAME%\:
      • C:\Users\%USERNAME%\AppData
      • C:\Users\%USERNAME%\blenderkit_data
      • C:\Users\%USERNAME%\Desktop
      • C:\Users\%USERNAME%\Documents
      • C:\Users\%USERNAME%\Downloads
      • C:\Users\%USERNAME%\IntelGraphicsProfiles
      • C:\Users\%USERNAME%\Links
      • C:\Users\%USERNAME%\Music
      • C:\Users\%USERNAME%\Naturalsoft
      • C:\Users\%USERNAME%\Pictures
      • C:\Users\%USERNAME%\PycharmProjects
      • C:\Users\%USERNAME%\root\
      • C:\Users\%USERNAME%\Start Menu
      • C:\Users\%USERNAME%\Videos
    • Do full Filelist backup:
      • On windows (you might want to use admin privilages):
        1. CMD or Powershell:
          • chcp 65001 #Enables Greek
          • dir /B /S "$PATH1" > "$PATH2\FileStructureList\FileListShort.txt"
          • dir /S "$PATH1" > "$PATH2\FileStructureList\FileList.txt"
          • dir /A:D /S "$PATH1" > "$PATH2\FileStructureList\DirList.txt"
          • dir /A:D /B /S "$PATH1" > "$PATH2\FileStructureList\DirListShort.txt"
        2. Powershell:
          • iex tree "$PATH1" > "$PATH2\FileStructureList\FileListTree.txt"
          • iex tree "$PATH1" /F > "$PATH2\FileStructureList\DirListTree.txt"
        3. Obsolete commands (no need to try them)
          • tree ""$PATH1" | clip
          • tree "$PATH1" /F | clip
          • FileListTree.txt
          • DirListTree.txt
      • On linux (you might want to use admin privilages):
        • ls -alR --time-style=full-iso --time=atime "$PATH1" > ~/FileList-atime.txt # For date accessed timestamp
        • ls -alR --time-style=full-iso --time=ctime "$PATH1" > ~/FileList-ctime.txt # For date changed timestamp
        • ls -alR --time-style=full-iso --time=mtime "$PATH1" > ~/FileList-mtime.txt # For date modified timestamp
        • ls -alR --time-style=full-iso --time=birth "$PATH1" > ~/FileList-btime.txt # For date created timestamp
        • Single command alternative: ls -alR --time-style=full-iso --time=atime "$PATH1" > ~/FileList-atime.txt ; ls -alR --time-style=full-iso --time=ctime "$PATH1" > ~/FileList-ctime.txt ; ls -alR --time-style=full-iso --time=mtime "$PATH1" > ~/FileList-mtime.txt ; ls -alR --time-style=full-iso --time=birth "$PATH1" > ~/FileList-btime.txt # Uses " ; " to seperate each command
      • Where "$PATH1" is the path you want to keep a log of and "$PATH2" is the path where you want to save the logs to
  12. VM
    • Qemu
      • We need:
        • qemu #Generic and open source machine emulator and virtualizer
        • virt-manager #gui VM manager
        • virt-viewer #Viewer for remote virtual machines
        • dnsmasq #Integrated DNS, DHCP and TFTP server for small networks
        • vde2 #Virtual Distributed Ethernet, an Ethernet compliant virtual network
        • iproute2 #bridge-utils is deprecated
        • netcat #TLS/SSL implementation
        • libvirt #The libvirt-deamon that runs virtualisation in the background, Toolkit to interact with the virtualization capabilities of recent versions of Linux and other OSes
      • Code (you can modify it to fit your configuration.nix code):
        *configuration.nix*
        programs.virt-manager.enable = true;
        users.groups.libvirtd.members = ["$USERNAME"];
        virtualisation.libvirtd.enable = true;
        virtualisation.spiceUSBRedirection.enable = true;
        
        • where:
          • $USERNAME is the user's username :)
        *home.nix*
        dconf.settings = {
        	"org/virt-manager/virt-manager/connections" = {
        		autoconnect = ["qemu:///system"];
        		uris = ["qemu:///system"];
        	};
        };
        
        • The 2nd code is used to resolve declaratively: Could not detect a default hypervisor. Make sure the appropriate QEMU/KVM virtualization packages are installed to manage virtualization on this host. A virtualization connection can be manually added via File->Add Connection
      • Run egrep -c '(vmx|svm)' /proc/cpuinfo to check if virtualisation is enabled
        • vmx: virtualisation module for intel
        • svm: virtualisation module for amd
        • returns info about cpu, should be !=0 if virtualisation is enabled (in Bios/Virtualisation Support/Enable Intel Virtualisation Technology for example)
      • Create a volume for where qemu locates the ISOs
      • Create a volume for where qemu installs the VMs [optional]
      • Enable autostart of libvirt deamon at boot
        • First, confirm that the default network is indeed inactive: sudo virsh net-list --all
        • If so, set the default network to autostart at boot: sudo virsh net-autostart default
          • If you want you can turn on the default network instead of setting it to autostart: sudo virsh net-start default
        • Another possible, declarative solution might be this:
          *configuration.nix*
          virtualisation.libvirtd.onBoot = "start";
          
      • How to increase the fps/speed of (Windows) VM
        • In virt-manager go to Edit/Prefernces/General/ and turn on Enable XML editing
        • Install virtio drivers (huge speedup)
          • Follow Variant 1 from here (install all the drivers that are selected by default (probably all))
        • If you have ssd, tell virt-manager to treat storage as ssd (needs virtion drivers (probably))
          • Follow this guide:
            • Add a VirtIO SCSI controller (use the gui way)
              • In virt-manager, click Add Hardware button on the VM details tap, select Controller and use Type SCSI and model VirtIO SCSI
            • Change disc to ssd (It's the Change disc bus to scsi step, but in the way that worked for me)
              • Add the rotation_rate=1 attribute to the (end of the) <target> tag, which dictates that the disk is SSD (doesn't rotate)
              • The resulting domain xml would look something like this:
                <domain type='kvm'>
                ...
                <devices>
                	<controller type='scsi' index='0' model='virtio-scsi' />
                	<disk type='file' device='disk'>
                	...
                	<target dev='sda' bus='sata' rotation_rate='1'/>
                	</disk>
                </devices>
                </domain>
                
                • The <target dev='sda' bus='sata' rotation_rate='1'/> and specifically the target dev='sda' and the bus='sata' attributes might be different, depending on the partition the VM is mounted and the type of disk you use, respecively
                • Note: Changing the disc bus to scsi as the guide says prevented my VM from properly booting for some reason
        • If you still encounter issues, you might want to check this guide that modifies the libvirt XML:
          1. Apply all available Hyper-V enlightenments - the <hyperv> section of your XML should look like this:
            <hyperv>
              <relaxed state='on'/>
              <vapic state='on'/>
              <spinlocks state='on' retries='8191'/>
              <vpindex state='on'/>
              <synic state='on'/>
              <stimer state='on'>
            	<direct state='on'/>
              </stimer>
              <reset state='on'/>
              <frequencies state='on'/>
              <reenlightenment state='on'/>
              <tlbflush state='on'/>
              <ipi state='on'/>
            </hyperv>
            
          2. Disable all timers except for the hypervclock - the <clock> section of your XML should look like this:
            <clock offset='localtime'>
              <timer name='rtc' present='no' tickpolicy='catchup'/>
              <timer name='pit' present='no' tickpolicy='delay'/>
              <timer name='hpet' present='no'/>
              <timer name='kvmclock' present='no'/>
              <timer name='hypervclock' present='yes'/>
            </clock>
            
          3. Further improvements can be made, though. Using CPU pinning (forces each virtual CPU to be pinned to a physical CPU core), reducing the performance overhead from the kernel constantly swapping the virtual CPUs to different threads. For example, (6 cores for the VM on an 8-core host):
            <vcpu placement='static'>6</vcpu>
            <iothreads>1</iothreads>
            <cputune>
              <vcpupin vcpu='0' cpuset='1'/>
              <vcpupin vcpu='1' cpuset='5'/>
              <vcpupin vcpu='2' cpuset='2'/>
              <vcpupin vcpu='3' cpuset='6'/>
              <vcpupin vcpu='4' cpuset='3'/>
              <vcpupin vcpu='5' cpuset='7'/>
              <emulatorpin cpuset='0,4'/>
              <iothreadpin iothread='1' cpuset='0,4'/>
            </cputune>
            
          4. I highly recommend using virtio as your disk type, as this allows disk access to be paravirtualized, further reducing overhead. This requires driver support though on the Windows side - easiest way to enable this is to reinstall Windows, and when partitioning the disk, insert the virtio-win drivers ISO into your virtual machine so that the disk can be recognized during setup. I'm using this in my XML:
            <disk type='file' device='disk'>
              <driver name='qemu' type='qcow2' cache='none' io='threads' discard='unmap' iothread='1' queues='6'/>
              <source file='/var/lib/libvirt/images/win11.qcow2'/>
              <target dev='vda' bus='virtio'/>
              <boot order='2'/>
              <address type='pci' domain='0x0000' bus='0x05' slot='0x00' function='0x0'/>
            </disk>
            
          5. Finally, make sure to install the Spice guest tools to improve how the VM handles mouse input between the guest and host and to automatically change the VM's resolution when the window resizes.
      • Windows image
        • Install Win10 IoT Enterprise LTSC (https://massgrave.dev/)
        • When creating account to sign in, chose "Domain account" to use an offline account
        • Activate Windows
          • Once it boots up, open Powershell (Admin)
          • Type irm https://get.activated.win | iex
          • Press 1 to activate Windows
          • Once it finishes, press 0 to exit
        • Make bootable image of Windows 10 OS before wiping it, to run on Linux VM/Qemu
    • Distrobox
      • Arch linux (latest)
        1. Create an arch linux installation:
          • distrobox create --name ArchNixos --init --image archlinux:latest --home ~/Distrobox/Archlinux --additional-packages "systemd"
          • or distrobox create --pull -i docker.io/library/archlinux:latest --name Distrobox-Archlinux --home ~/Distrobox/Archlinux --additional-packages "systemd" --init --pre-init-hooks "pacman -S -y -y; pacman -S --noconfirm dbus; pacman-key --refresh-keys" Link
          • It is important to create each container in its own home directory, otherwise it may interfere with your configs and your host home dir
          • Use BoxBuddy or something similar for GUI version
        2. Install yay:
          • sudo pacman -Syu #refresh the package cache and update the system first
          • sudo pacman -S --needed base-devel git #Install the rerquired base-devel (contains tools such as makepkg etc) and git (required for cloning the yay git repository)
          • git clone https://aur.archlinux.org/yay.git #Clone the Yay git repo
          • cd yay #switch to the cloned directory (it will be probably in the home dir)
          • makepkg -si #Install yay
          • yay --version #verify that yay has been installed yay -S package_name #Install packages yay -Rns package_name #Delete a package with its dependencies (ns removes the dependencies) yay -Sua #Upgrading (only) the AUR packages sudo pacman -Rs yay #Remove Yay
        3. Enable gui apps
          • yay -S xorg-xhost #install xorg-xhost
          • xhost +si:localuser:$USER #To provide access to an application running with sudo or su to the graphical server (aka your X session aka your computer screen), open a terminal and type it as your normal user
          • xhost - #To get things back to normal, with controlled access to the X screen
      • Export installed app
        • distrobox-export --app abiword
      • Upgrade containers
        • distrobox-upgrade --all
    • Gem5 [not-available-yet-on-nixpkgs]
  13. Extra set up
    • Add icons to desktop
      • Desktop icons seem to break after rebuilding the OS and deleting the previous profile in history (garbage collection)
        • To prevent this go to /run/current-system/sw/share/applications/ and pick your desktop shortcuts from there and link them (don't copy them) on your desktop
      • To prevent pinned icons from being removed from your Task Manager bar on the bottom, first open the app you want to pin and then select to pin it (don't simply pin it from the start menu, this won't survive the garbage collection)
    • Figure out file associations (probably better to not change anything..)
      • Take a screenshot before chaning anything, there is NO "reset" option...
      • This will probably break saving files in KDE apps, by reporting QImageWriter cannot write image: Unsupported image format
        • It probably has to do with qt-imageformats or something (???)
        • It affects apps like Krita, Spectacle etc.
        • To fix this, check if any file format is written in more than one file format
        • To fix *.jpg creations, go to *.jpg format and delete *.jfif and *.jpe
        • To fix *.png creations, go to *.apng format and delete *.png
        • To fix settings like Mouse & Mousepad, Network and Printers from reporting a big that an icon group can't be found, so far some solutions are to either reopen settings (maybe from a different shortcut?) or reboot
    • To fix mic issues when connecting headset
      • Open Settings/Sound and set Input to Headset Microphone
      • Needs a better fix
        • #To-Do
    • Set up Mousepad (clicking and scrolling)
      • Go to Settings/Mouse & Touchpad to customize it
    • Set up Waydroid
      • #To-Do
    • Set up shortcuts (probably better to not change anything..)
      • Apparently, creating keyboard shortcuts, immediately disables the key y for some reason
        • To fix it, remove the shortcut you've made, reset all shortcuts to defaul (rip shortcuts of kde apps) and reboot the pc or logout-login
        • Ever since I created a shortcut, using a shortcut (even ctrl+C) disables the ykey and it only got solved by resetting all shortcuts...
        • Needs a better fix
          • #To-Do
    • Set up KDE Connect
      • Open these ports in your firewall
        *configuration.nix*
        networking.firewall.allowedTCPPortRanges = [
        	{ from = 1714; to = 1764; } #KDE Connect
        ];
        
    • Enable ratbagd deamon to use Piper (Piper doesn't work well with G502 that has a second mode)
      *configuration.nix*
      # Enable Piper support
      services.ratbagd.enable = true;
      
    • Enable printing (good luck)
      *configuration.nix*
      # Enable CUPS to print documents.
      services.printing = {
      	enable = true;
      	drivers = [
      	pkgs.gutenprint # Drivers for many different printers from many different vendors.
      	pkgs.gutenprintBin # Additional, binary-only drivers for some printers.
      #     pkgs.hplip # Drivers for HP printers.
      	pkgs.hplipWithPlugin # Drivers for HP printers, with the proprietary plugin. Use NIXPKGS_ALLOW_UNFREE=1 nix-shell -p hplipWithPlugin --run 'sudo -E hp-setup' to add the printer, regular CUPS UI doesn't seem to work.
      	pkgs.postscript-lexmark # Postscript drivers for Lexmark
      	pkgs.samsung-unified-linux-driver # Proprietary Samsung Drivers
      	pkgs.splix # Drivers for printers supporting SPL (Samsung Printer Language).
      	pkgs.brlaser # Drivers for some Brother printers
      	pkgs.brgenml1lpr # Generic drivers for more Brother printers [1]
      	pkgs.brgenml1cupswrapper # Generic drivers for more Brother printers [1]
      	pkgs.cnijfilter2 # Drivers for some Canon Pixma devices (Proprietary driver)
      	];
      };
      
      # Enable autodiscovery of network printers
      services.avahi = {
      	enable = true;
      	nssmdns4 = true;
      	openFirewall = true;
      };
      
    • Set up OpenSnitch (helps open the appropriate firewall ports)
      • #To-Do
    • Enable Spicetify-nix
      • We need to add the flake, plug it in the modules and customize it in configuration.nix
      • Somehow, even though the marketplace shouldn't apply the installed apps, it worked almost flowlessly
      *flake.nix*
          spicetify-nix = {
              url = "github:Gerg-L/spicetify-nix";
              inputs.nixpkgs.follows = "nixpkgs";
          };
          ...
          modules = [
              # Imports spicetify in configuration.nix
              inputs.spicetify-nix.nixosModules.default
          ];
      
      *configuration.nix*
          programs.spicetify =
              let
              spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.system};
              in
              {
              enable = true;
      
              enabledExtensions = with spicePkgs.extensions; [
                  keyboardShortcut
                  adblock
              ];
              enabledCustomApps = with spicePkgs.apps; [
                  marketplace
          #        ({
          #       # The source of the customApp
          #       src = pkgs.fetchFromGitHub {
          #         owner = "Maskowh";
          #         repo = "spicetify-old-like-button-extension";
          #         rev = "fe6f9792ef7d3532d054c5544c79068ce68609a9";
          #         hash = "???";
          #       };
          #       # The actual file name of the customApp usually ends with .js
          #       name = "";
          #   })
              ];
          #       enabledSnippets = with spicePkgs.snippets; [
          #       ];
              # Not very sure how to use the default theme
              theme = spicePkgs.themes.catppuccin;
              colorScheme = "mocha";
              };
      

Extras

Commands

  1. Nixos commands
    • cd /etc/nixos
    • sudo nix flake update
    • sudo nixos-rebuild switch --flake /etc/nixos
    • sudo nix profile wipe-history --older-than 1d --profile /nix/var/nix/profiles/system
    • sudo nix-collect-garbage
    • nix profile history --profile /nix/var/nix/profiles/system
    • nix-store --query --referrers "$path", where $path is the nix store path to the program you want to check its dependencies (like /nix/store/...(insert full path here)...)
  2. Flatpak commands`
    • sudo flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
    • sudo flatpak uninstall --delete-data app-ID
    • sudo flatpak install flathub com.github.tchx84.Flatseal
    • sudo flatpak install https://dl.flathub.org/repo/appstream/com.github.tchx84.Flatseal.flatpakref
    • sudo flatpak install path/to/package.flatpakref

NixOS Bookmarks

  1. Basics
  2. Home-Manager
  3. General
  4. Specific
  5. Dotfiles
  6. Podman
  7. Distrobox
  8. Qemu-VMs
  9. Gaming
  10. YT-Tutorials
  11. Meta

Obsolete

  1. Auto 3rd party app downloader/installer
    • Find how to fetch from each site
      • Github
      • Gitlab
      • Other
    • Find how to check for updates
      • Append date/time on log
      • Fetch link for download
      • Compare with log file
    • Find how to install each type
      • .deb
        • sudo apt install *.deb
      • .tar.*
        • delete old app files (/opt/ and /usr/bin/)
        • sudo tar xzvf archive.tar -C /path/to/dir --overwrite-dir --remove-files
    • Find how to create a .desktop
      • extract version from link
      • update .desktop (version)
      • create .desktop
    • Upload to github
  2. ZFS