diff --git a/README.md b/README.md index a340840..284ae5e 100644 --- a/README.md +++ b/README.md @@ -15,6 +15,8 @@ * [x] Make a flake * [x] merge hosted docs into a single subdomain * [x] Setup some remote-development and deploy flow +* [ ] add a hidpi profile? https://wiki.archlinux.org/title/HiDPI +* [ ] rocm * [ ] xclip * [ ] xforwarding over ssh * [ ] autogenerate ssh keys diff --git a/base.nix b/base.nix index 2bfb0fd..c720b4e 100644 --- a/base.nix +++ b/base.nix @@ -3,8 +3,14 @@ imports = [ ./cachix.nix ./profiles/locale-no.nix + # results of 'nixos-generate-config' + # nice to have if i just dump this flake into /etc/nixos on a clean install + (if builtins.pathExists ./configuration.nix + then ./configuration.nix + else {} + ) (if builtins.pathExists ./hardware-configuration.nix - then ./hardware-configuration.nix # results of ‘nixos-generate-config + then ./hardware-configuration.nix else {} ) ]; @@ -44,7 +50,6 @@ environment.shells = with pkgs; [ bash zsh ]; - nix.settings.allowed-users = [ "*" ]; # default #nix.settings.allowed-users = [ "@nixbld" "@builders" ]; # TODO: this nix.settings.trusted-users = [ "root" "@wheel" ]; @@ -64,5 +69,4 @@ # firewall services.fail2ban.enable = config.services.openssh.enable; networking.firewall.enable = true; # default - } diff --git a/hosts/bolle/default.nix b/hosts/bolle/default.nix index 57ddf56..5413f60 100644 --- a/hosts/bolle/default.nix +++ b/hosts/bolle/default.nix @@ -7,47 +7,29 @@ imports = [ ./hardware-configuration.nix + ../../hardware/opengl-intel.nix ../../users # home-manager ../../users/pbsds - ../../hardware/opengl-intel.nix + ../../profiles/shell/base.nix + ../../profiles/shell/archives.nix + ../../profiles/shell/nix-utils.nix + ../../profiles/shell/binfmt-emu.nix - /** / - ../../profiles/web - ../../profiles/web/index - ../../profiles/web/docs - ../../profiles/web/docs/pdoc.nix - ../../profiles/web/docs/python-docs.nix - ../../profiles/web/docs/nixpkgs.nix - ../../profiles/web/docs/linux-docs.nix - ../../profiles/web/docs/yagcd.nix - /**/ - - #../../profiles/domeneshop-dyndns # TODO: olavtr is hardcoded... + #../../profiles/domeneshop-dyndns # TODO: secrets #../../profiles/code-remote - #../../profiles/remote-builders # + #../../profiles/remote-builders #../../profiles/autossh-reverse-tunnels ]; - - # run/build weird binaries - # TODO: somehow make sure this is in sync with remote-builders - boot.binfmt.emulatedSystems = [ - "wasm32-wasi" - "wasm64-wasi" - "x86_64-windows" - "aarch64-linux" - "riscv64-linux" - #"x86_64-darwin" - #"aarch64-darwin" - ]; + #services.domeneshop-updater.target = "bolle.pbsds.net"; # default? services.thermald.enable = true; # Virtualization #virtualisation.podman.enable = true; #virtualisation.podman.dockerCompat = true; # alias docker to podman - #virtualisation.oci-containers.backend = "podman"; + #virtualisation.oci-containers.backend = "podman"; # default # Networking networking.networkmanager.enable = true; @@ -71,96 +53,14 @@ /**/ # Installed system packages - # TODO: prune this, make home-manager deal with the majority environment.systemPackages = with pkgs; [ - lsof - lshw - htop - file - tmux - #parallel # already provided by moreutils - pwgen - git - nmap - rsync - bind.dnsutils - graphviz - dialog - cowsay - gnused - gnumake - coreutils-full - moreutils - binutils - diffutils - findutils - usbutils - bash-completion - curl - wget - strace - killall - - zip - unrar - unzip - atool - p7zip - bzip2 - gzip - atool - - micro - aspell aspellDicts.en aspellDicts.nb - vimv - dos2unix - #rmate # TODO: add to nixpkgs - pandoc - cargo - cargo-edit - sqlite - #sshuttle - visidata - - weston cage + weston + dialog + zenith vimix-gtk-themes flat-remix-icon-theme - xclip feh - - sshfs - - glances - zenith - tealdeer # tldr - entr - axel aria - bat - xe # xargs alternative - sd # sed alternative - fd # find alternative - silver-searcher # `ag` - ripgrep - jq - yq - htmlq - sysz - du-dust # du alternative - ncdu # Disk usage analyzer with an ncurses interface - - gh - hub - - cachix - nix-output-monitor - nix-prefetch - nix-top - #nix-index - nix-tree - nix-diff - nixfmt - alejandra ]; # TODO: remove? Move? @@ -173,12 +73,15 @@ # System fonts # Nice to have when X-forwading on headless machines # TODO: move? + #hardware.video.hidpi.enable = true; # highdpi (for nord only) + #fonts.fontconfig.hinting.enable = true; # lowdpi + fonts.fontDir.enable = true; # creates /run/current-system/sw/share/X11/fonts + fonts.enableDefaultFonts = true; # dejavu, freefont, gyre, liberation, unifont, noto-fonts-emoji fonts.fonts = with pkgs; [ noto-fonts # includes Cousine noto-fonts-cjk noto-fonts-emoji noto-fonts-extra - dejavu_fonts ]; # This value determines the NixOS release from which the default diff --git a/hosts/nord/default.nix b/hosts/nord/default.nix index 2b9db87..1793e2c 100644 --- a/hosts/nord/default.nix +++ b/hosts/nord/default.nix @@ -13,8 +13,6 @@ boot.kernelPackages = pkgs.linuxPackages_latest; # amdgpu audio fix when at 4k@60fps - services.flatpak.enable = true; - imports = [ ./hardware-configuration.nix ../../hardware/rocm.nix @@ -23,40 +21,34 @@ ../../users # home-manager ../../users/pbsds - ../../profiles/desktop/gnome # with gdm + ../../profiles/mounts/reidun-nfs.nix + + ../../profiles/shell/base.nix + ../../profiles/shell/archives.nix + ../../profiles/shell/nix-utils.nix + #../../profiles/shell/binfmt-emu.nix + + ../../profiles/desktop/gnome # configures gdm + #../../profiles/desktop/sound/alsa.nix #../../profiles/desktop/sound/pulseaudio.nix ../../profiles/desktop/sound/pipewire.nix - #../../profiles/desktop/sound/alsa.nix ../../profiles/desktop/steam.nix - - ../../profiles/nfs/reidun.nix + ../../profiles/desktop/flatpak.nix ../../profiles/remote-builders #../../profiles/autossh-reverse-tunnels #../../profiles/domeneshop-dyndns # handled by noximilien ]; - networking.firewall.allowedTCPPorts = [ 57621 ]; # spotify - - # run/build weird binaries - # TODO: somehow make sure this is in sync with remote-builders - boot.binfmt.emulatedSystems = [ - "wasm32-wasi" - "wasm64-wasi" - "x86_64-windows" - "aarch64-linux" - "riscv64-linux" - #"x86_64-darwin" - #"aarch64-darwin" - ]; + networking.firewall.allowedTCPPorts = [ 57621 ]; # spotify local discovery services.thermald.enable = true; # Virtualization #virtualisation.podman.enable = true; #virtualisation.podman.dockerCompat = true; # alias docker to podman - #virtualisation.oci-containers.backend = "podman"; + #virtualisation.oci-containers.backend = "podman"; # default # Networking networking.networkmanager.enable = true; @@ -75,97 +67,15 @@ #TODO: avahi? resolved? https://git.pvv.ntnu.no/Drift/pvv-nixos-config/src/main/base.nix#L15-L18 # Installed system packages - # TODO: prune this, make home-manager deal with the majority environment.systemPackages = with pkgs; [ - lsof - lshw - htop - file - tmux - #parallel # already provided by moreutils - pwgen - git - nmap - rsync - bind.dnsutils - graphviz - dialog - cowsay - gnused - gnumake - coreutils-full - moreutils - binutils - diffutils - findutils - usbutils - bash-completion - curl - wget - strace - killall - - zip - unrar - unzip - atool - p7zip - bzip2 - gzip - atool - - micro - aspell aspellDicts.en aspellDicts.nb - vimv - dos2unix - #rmate # TODO: add to nixpkgs - pandoc - cargo - cargo-edit - sqlite - #sshuttle - visidata - - weston cage + weston + dialog + zenith vimix-gtk-themes flat-remix-icon-theme - xclip feh - sshfs - - glances - zenith - tealdeer # tldr - entr - axel aria - bat - xe # xargs alternative - sd # sed alternative - fd # find alternative - silver-searcher # `ag` - ripgrep - jq - yq - htmlq - sysz - du-dust # du alternative - ncdu # Disk usage analyzer with an ncurses interface - - gh - hub - - cachix - nix-output-monitor - nix-prefetch - nix-top - #nix-index - nix-tree - nix-diff - nixfmt - alejandra - firefox ]; @@ -179,12 +89,15 @@ # System fonts # Nice to have when X-forwading on headless machines # TODO: move? + hardware.video.hidpi.enable = true; # highdpi (for nord only) + #fonts.fontconfig.hinting.enable = true; # lowdpi + fonts.fontDir.enable = true; # creates /run/current-system/sw/share/X11/fonts + fonts.enableDefaultFonts = true; # dejavu, freefont, gyre, liberation, unifont, noto-fonts-emoji fonts.fonts = with pkgs; [ noto-fonts # includes Cousine noto-fonts-cjk noto-fonts-emoji noto-fonts-extra - dejavu_fonts ]; diff --git a/hosts/noximilien/default.nix b/hosts/noximilien/default.nix index 7e70221..6f851ab 100644 --- a/hosts/noximilien/default.nix +++ b/hosts/noximilien/default.nix @@ -6,17 +6,22 @@ boot.loader.grub.useOSProber = true; imports = [ ./hardware-configuration.nix + ../../hardware/opengl-intel.nix ../../users # home-manager ../../users/pbsds ../../users/jornane - #../../users/all.nix # TODO: does not work? - ../../hardware/opengl-intel.nix + ../../profiles/mounts/reidun-nfs.nix - ../../profiles/tmate-server # opens port 42244 + ../../profiles/shell/base.nix + ../../profiles/shell/archives.nix + ../../profiles/shell/nix-utils.nix + ../../profiles/shell/binfmt-emu.nix - ../../profiles/web + ../../profiles/services/tmate-server.nix # opens port 42244 + + ../../profiles/web # enables nginx+acme, defines mkDomain ../../profiles/web/index ../../profiles/web/services/cinny ../../profiles/web/services/element @@ -69,15 +74,14 @@ #../../profiles/web/services/trivial-gradios ../../profiles/domeneshop-dyndns # TODO: olavtr is hardcoded... - ../../profiles/code-remote - ../../profiles/remote-builders # - ../../profiles/nfs/reidun.nix # NFS mounts + ../../profiles/code-remote # TODO: move into web? services? + ../../profiles/remote-builders ../../profiles/autossh-reverse-tunnels #../../profiles/xrdp ]; services.domeneshop-updater.target = "olavtr.pbsds.net"; - # TODO: remove? Move to where relevant= + # TODO: remove? Move to where relevant? nixpkgs.overlays = [ /** / (final: prev: { @@ -87,25 +91,12 @@ /**/ ]; - # run/build weird binaries - # TODO: somehow make sure this is in sync with remote-builders - boot.binfmt.emulatedSystems = [ - "wasm32-wasi" - "wasm64-wasi" - "x86_64-windows" - "aarch64-linux" - "riscv64-linux" - #"x86_64-darwin" - #"aarch64-darwin" - ]; - services.thermald.enable = true; # Virtualization virtualisation.podman.enable = true; - # TODO: are these default since 22.11? virtualisation.podman.dockerCompat = true; # alias docker to podman - virtualisation.oci-containers.backend = "podman"; + virtualisation.oci-containers.backend = "podman"; # default # Networking networking.networkmanager.enable = true; @@ -127,96 +118,14 @@ #TODO: avahi? resolved? https://git.pvv.ntnu.no/Drift/pvv-nixos-config/src/main/base.nix#L15-L18 # Installed system packages - # TODO: prune this, make home-manager deal with the majority environment.systemPackages = with pkgs; [ - lsof - lshw - htop - file - tmux - #parallel # already provided by moreutils - pwgen - git - nmap - rsync - bind.dnsutils - graphviz - dialog - cowsay - gnused - gnumake - coreutils-full - moreutils - binutils - diffutils - findutils - usbutils - bash-completion - curl - wget - strace - killall - - zip - unrar - unzip - atool - p7zip - bzip2 - gzip - atool - - micro - aspell aspellDicts.en aspellDicts.nb - vimv - dos2unix - #rmate # TODO: add to nixpkgs - pandoc - cargo - cargo-edit - sqlite - #sshuttle - visidata - - weston cage + weston + dialog + zenith vimix-gtk-themes flat-remix-icon-theme - xclip feh - - sshfs - - glances - zenith - tealdeer # tldr - entr - axel aria - bat - xe # xargs alternative - sd # sed alternative - fd # find alternative - silver-searcher # `ag` - ripgrep - jq - yq - htmlq - sysz - du-dust # du alternative - ncdu # Disk usage analyzer with an ncurses interface - - gh - hub - - cachix - nix-output-monitor - nix-prefetch - nix-top - #nix-index - nix-tree - nix-diff - nixfmt - alejandra ]; # TODO: remove? Move? @@ -234,24 +143,20 @@ services.openssh.enable = true; services.openssh.forwardX11 = true; - # TODO: should not be system-wide - #programs.ssh.extraConfig = '' - # Host *.ntnu.no *.pvv.org - # User pederbs - #''; - # System fonts # Nice to have when X-forwading on headless machines # TODO: move? + #hardware.video.hidpi.enable = true; # highdpi (for nord only) + #fonts.fontconfig.hinting.enable = true; # lowdpi + fonts.fontDir.enable = true; # creates /run/current-system/sw/share/X11/fonts + fonts.enableDefaultFonts = true; # dejavu, freefont, gyre, liberation, unifont, noto-fonts-emoji fonts.fonts = with pkgs; [ noto-fonts # includes Cousine noto-fonts-cjk noto-fonts-emoji noto-fonts-extra - dejavu_fonts ]; - # This value determines the NixOS release from which the default # settings for stateful data, like file locations and database versions # on your system were taken. It‘s perfectly fine and recommended to leave diff --git a/profiles/desktop/flatpak.nix b/profiles/desktop/flatpak.nix new file mode 100644 index 0000000..d99bb74 --- /dev/null +++ b/profiles/desktop/flatpak.nix @@ -0,0 +1,26 @@ +{ config, pkgs, ... }: + +{ + services.flatpak.enable = true; + + # fix missing fonts in flatpak, without resorting to copying fonts to a dedicated folder + # via https://github.com/NixOS/nixpkgs/issues/119433#issuecomment-1326957279 + system.fsPackages = [ pkgs.bindfs ]; + fileSystems = let + mkRoSymBind = path: { + device = path; + fsType = "fuse.bindfs"; + # resolve-symlinks enable not mounting /nix into the flatpacks + options = [ "ro" "resolve-symlinks" "x-gvfs-hide" ]; + }; + aggregatedFonts = pkgs.buildEnv { + name = "system-fonts"; + paths = config.fonts.fonts; + pathsToLink = [ "/share/fonts" ]; + }; + in { + # Create an FHS mount to support flatpak host icons/fonts + "/usr/share/icons" = mkRoSymBind (config.system.path + "/share/icons"); + "/usr/share/fonts" = mkRoSymBind (aggregatedFonts + "/share/fonts"); + }; +} diff --git a/profiles/locale-no.nix b/profiles/locale-no.nix index 2af2cc0..351006e 100644 --- a/profiles/locale-no.nix +++ b/profiles/locale-no.nix @@ -1,17 +1,26 @@ { - # Time zone and internationalisation properties. - time.timeZone = "Europe/Oslo"; - i18n.defaultLocale = "en_US.utf8"; - i18n.extraLocaleSettings.LC_ADDRESS = "nb_NO.utf8"; - i18n.extraLocaleSettings.LC_IDENTIFICATION = "nb_NO.utf8"; - i18n.extraLocaleSettings.LC_MEASUREMENT = "nb_NO.utf8"; - i18n.extraLocaleSettings.LC_MONETARY = "nb_NO.utf8"; - i18n.extraLocaleSettings.LC_NAME = "nb_NO.utf8"; - i18n.extraLocaleSettings.LC_NUMERIC = "nb_NO.utf8"; - i18n.extraLocaleSettings.LC_PAPER = "nb_NO.utf8"; - i18n.extraLocaleSettings.LC_TELEPHONE = "nb_NO.utf8"; - i18n.extraLocaleSettings.LC_TIME = "nb_NO.utf8"; - console.keyMap = "no"; - services.xserver.layout = "no"; - services.xserver.xkbVariant = ""; + # Time zone and internationalisation properties. + time.timeZone = "Europe/Oslo"; + i18n.defaultLocale = "en_US.utf8"; + i18n.extraLocaleSettings.LC_ADDRESS = "nb_NO.utf8"; + i18n.extraLocaleSettings.LC_IDENTIFICATION = "nb_NO.utf8"; + i18n.extraLocaleSettings.LC_MEASUREMENT = "nb_NO.utf8"; + i18n.extraLocaleSettings.LC_MONETARY = "nb_NO.utf8"; + i18n.extraLocaleSettings.LC_NAME = "nb_NO.utf8"; + i18n.extraLocaleSettings.LC_NUMERIC = "nb_NO.utf8"; + i18n.extraLocaleSettings.LC_PAPER = "nb_NO.utf8"; + i18n.extraLocaleSettings.LC_TELEPHONE = "nb_NO.utf8"; + i18n.extraLocaleSettings.LC_TIME = "nb_NO.utf8"; + console.keyMap = "no"; + services.xserver.layout = "no"; + services.xserver.xkbVariant = ""; + + # no caps lock + services.xserver.xkbOptions = "ctrl:nocaps"; + #console.useXkbConfig = true; # applies to ttys aswell, mutex with console.keyMap + # run the following to make GNOME reload the xkb options: + /* + gsettings reset org.gnome.desktop.input-sources xkb-options + gsettings reset org.gnome.desktop.input-sources sources + */ } diff --git a/profiles/nfs/reidun.nix b/profiles/mounts/reidun-nfs.nix similarity index 100% rename from profiles/nfs/reidun.nix rename to profiles/mounts/reidun-nfs.nix diff --git a/profiles/tmate-server/default.nix b/profiles/services/tmate-server.nix similarity index 100% rename from profiles/tmate-server/default.nix rename to profiles/services/tmate-server.nix diff --git a/profiles/shell/archives.nix b/profiles/shell/archives.nix new file mode 100644 index 0000000..08a7f84 --- /dev/null +++ b/profiles/shell/archives.nix @@ -0,0 +1,13 @@ +{ pkgs, ... }: +{ + environment.systemPackages = with pkgs; [ + zip + unrar + unzip + atool + p7zip + bzip2 + gzip + atool + ]; +} diff --git a/profiles/shell/base.nix b/profiles/shell/base.nix new file mode 100644 index 0000000..08e4aa4 --- /dev/null +++ b/profiles/shell/base.nix @@ -0,0 +1,53 @@ +{ pkgs, ... }: +{ + environment.systemPackages = with pkgs; [ + lsof + lshw + file + tmux + #parallel # already provided by moreutils + pwgen + git + #gh + #hub + nmap + rsync + bind.dnsutils + gnused + gnumake + coreutils-full + moreutils + binutils + diffutils + findutils + usbutils + bash-completion + curl + wget + strace + killall + + htop + glances + + #sshfs + entr + tealdeer # tldr, but rust + axel aria + bat + xe # xargs alternative + sd # sed alternative + fd # find alternative + silver-searcher # `ag` + ripgrep # 'rg' + jq + yq + htmlq + sysz + du-dust # du alternative + ncdu # Disk usage analyzer with an ncurses interface + + visidata + sqlite + ]; +} diff --git a/profiles/shell/binfmt-emu.nix b/profiles/shell/binfmt-emu.nix new file mode 100644 index 0000000..c05a309 --- /dev/null +++ b/profiles/shell/binfmt-emu.nix @@ -0,0 +1,14 @@ +{ pkgs, ... }: +{ + # run/build weird binaries + # TODO: somehow make sure this is in sync with remote-builders + boot.binfmt.emulatedSystems = [ + "wasm32-wasi" + "wasm64-wasi" + "x86_64-windows" + "aarch64-linux" + "riscv64-linux" + #"x86_64-darwin" + #"aarch64-darwin" + ]; +} diff --git a/profiles/shell/nix-utils.nix b/profiles/shell/nix-utils.nix new file mode 100644 index 0000000..1d92cbc --- /dev/null +++ b/profiles/shell/nix-utils.nix @@ -0,0 +1,16 @@ +{ pkgs, ... }: +{ + environment.systemPackages = with pkgs; [ + cachix + nix-output-monitor + nix-prefetch + nix-top + #nix-index + nix-tree + #nix-search # TODO: exists? + nix-diff + #comma + nixfmt + alejandra + ]; +} diff --git a/users/pbsds/default.nix b/users/pbsds/default.nix index 9447752..1d3cd65 100644 --- a/users/pbsds/default.nix +++ b/users/pbsds/default.nix @@ -3,7 +3,11 @@ # system-wide shit environment.systemPackages = with pkgs; [ + micro + vimv + xclip fzf + #rmate-sh # TODO: add to nixpkgs ]; # TODO: fzf for zsh programs.bash.shellInit = '' @@ -13,6 +17,7 @@ programs.bash.shellAliases."ed" = "micro"; # TODO: ${EDITOR:-micro} environment.variables."EDITOR" = "micro"; + # user and home-manager #nix.trusted-users = [ "pbsds" ]; diff --git a/users/pbsds/home/default.nix b/users/pbsds/home/default.nix index 7ca336f..b5a3d09 100644 --- a/users/pbsds/home/default.nix +++ b/users/pbsds/home/default.nix @@ -2,7 +2,7 @@ { pkgs, config, ... }: { nixpkgs.config.allowUnfree = true; - home.stateVersion = "22.11"; + home.stateVersion = "22.11"; # TODO: what uses this? imports = [ ./profiles/bat.nix @@ -14,12 +14,8 @@ ./profiles/tmate.nix ]; + # TODO: add remote-exec once packaged programs.bash.initExtra = '' - if [ "$COLORTERM" = "truecolor" ] || [ "$TERM" == "xterm" ]; then - export TERM=xterm-256color - export MICRO_TRUECOLOR=1 - fi - # remote-exec if command -v remote >/dev/null && remote-quick >/dev/null; then complete -F _command remote @@ -31,10 +27,11 @@ nix-shell -p atom --run "atom $(printf "%q " "$@") --in-process-gpu --no-sandbox" } ''; - # TODO: split ^ home.packages = with pkgs; [ xclip + #rmate-sh # TODO: add to nixpkgs, add to ssh config + #remote-exec # TODO: add to nixpkgs zip unrar @@ -45,17 +42,14 @@ gzip atool - aspell - aspellDicts.en - aspellDicts.nb dos2unix pandoc graphviz vgmstream gallery-dl - yt-dlp youtube-dl + yt-dlp ffmpeg-full visidata @@ -67,18 +61,26 @@ ponysay # TODO: move to graphical? kiosk? - mesa-demos cage + mesa-demos librespeed-cli cachix - nix-template + #nix-template nix-output-monitor nixpkgs-review manix comma + #sshuttle + + #cargo + #cargo-edit + + #nim + #nimble + (python3.withPackages (python-packages: with python-packages; [ matplotlib more-itertools @@ -98,10 +100,8 @@ home.shellAliases = { #flexget = "ssh -t knut.pbsds.net sudo -u flexget flexget"; - flexget = "sudo --user=flexget flexget -c /var/lib/flexget/flexget.yml"; - + flexget = "sudo --user=flexget flexget -c /var/lib/flexget/flexget.yml"; # TODO: only applies to nox... hman = "man -H "; # HTML opened in a browser - tmux = "systemd-run --scope --user tmux"; # detach from ssh scope, surviving logout # TODO: wayland @@ -111,7 +111,6 @@ pwd-fqdn = ''echo "$(whoami)@$(hostname -f):$(printf "%q" "$(realpath .)/")"''; http-server = "${pkgs.python3}/bin/python -m http.server"; - manix-fzf = ''manix "" 2>/dev/null | grep '^# ' | sed 's/^# \(.*\) (.*/\1/;s/ (.*//;s/^# //' | fzf --preview="manix '{}'" | xargs manix''; # TODO: move to /run/user/... @@ -121,7 +120,7 @@ programs.nix-index.enable = true; xdg.enable = true; - #xdg.desktopEntries + #TODO: xdg.desktopEntries /** / programs.beets = { diff --git a/users/pbsds/home/profiles/git.nix b/users/pbsds/home/profiles/git.nix index 98110e1..7863556 100644 --- a/users/pbsds/home/profiles/git.nix +++ b/users/pbsds/home/profiles/git.nix @@ -1,7 +1,10 @@ { pkgs, ... }: { - - home.packages = with pkgs; [ git gh hub ]; + home.packages = with pkgs; [ + git + gh + hub + ]; #programs.git.gitui.enable = true; programs.git.enable = true; @@ -19,29 +22,30 @@ "result-dev" "result-lib" "__pycache__" + "*.pyc" ]; home.shellAliases = { # git gud - gs = "git status"; - gb = "git blame"; - gl = "git log --oneline --color | head -n 30"; - glg = "git log --all --decorate --oneline --graph"; - gpra = "git pull --rebase --autostash"; - gd = "git diff"; - gdwd = "git diff --word-diff"; - gdwdr = "git diff --word-diff --word-diff-regex=."; - gds = "git diff --staged"; - gdswd = "git diff --staged --word-diff"; + gs = "git status"; + gb = "git blame"; + gl = "git log --oneline --color | head -n 30"; + glg = "git log --all --decorate --oneline --graph"; + gpra = "git pull --rebase --autostash"; + gd = "git diff"; + gdwd = "git diff --word-diff"; + gdwdr = "git diff --word-diff --word-diff-regex=."; + gds = "git diff --staged"; + gdswd = "git diff --staged --word-diff"; gdswdr = "git diff --staged --word-diff --word-diff-regex=."; - gcp = "git cherry-pick"; - gca = "git commit --amend"; - gcara = "git commit --amend --reset-author"; - gpo = "git push origin"; - gpasr = "git pull --autostash --rebase"; - #gfr = "git fetch origin master && git rebase FETCH_HEAD"; - gfr = "git pull --rebase"; - gp = "git pull --rebase --autostash"; + gcp = "git cherry-pick"; + gca = "git commit --amend"; + gcara = "git commit --amend --reset-author"; + gpo = "git push origin"; + gpasr = "git pull --autostash --rebase"; + #gfr = "git fetch origin master && git rebase FETCH_HEAD"; + gfr = "git pull --rebase"; + gp = "git pull --rebase --autostash"; }; } diff --git a/users/pbsds/home/profiles/micro.nix b/users/pbsds/home/profiles/micro.nix index 215d3e5..d359eab 100644 --- a/users/pbsds/home/profiles/micro.nix +++ b/users/pbsds/home/profiles/micro.nix @@ -8,7 +8,19 @@ home.shellAliases.de = "$EDITOR"; home.sessionVariables.EDITOR = "micro"; - home.packages = with pkgs; [ micro ]; + home.packages = with pkgs; [ + micro + aspell + aspellDicts.en + aspellDicts.nb + ]; + + programs.bash.initExtra = '' + if [ "$COLORTERM" = "truecolor" ] || [ "$TERM" == "xterm" ]; then + export TERM=xterm-256color + export MICRO_TRUECOLOR=1 + fi + ''; programs.micro.enable = true; programs.micro.trueColor = true;