Skip to content

Commit

Permalink
feat(home-manager): update configs
Browse files Browse the repository at this point in the history
  • Loading branch information
dr460nf1r3 committed Feb 15, 2024
1 parent eed6387 commit 515ef23
Show file tree
Hide file tree
Showing 5 changed files with 107 additions and 127 deletions.
3 changes: 0 additions & 3 deletions home-manager/common.nix
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,6 @@
warn-dirty = false
'';
settings = {
# Test out ca-derivations (https://nixos.wiki/wiki/Ca-derivations)
experimental-features = ["ca-derivations"];

# A few extra binary caches and their public keys
substituters = [
"https://cache.garnix.io"
Expand Down
3 changes: 3 additions & 0 deletions home-manager/development.nix
Original file line number Diff line number Diff line change
Expand Up @@ -87,4 +87,7 @@
"editor.defaultFormatter" = "jnoortheen.nix-ide";
};
};

# GitHub CLI
programs.gh.settings.git_protocol = "ssh";
}
47 changes: 7 additions & 40 deletions home-manager/nico/nico.nix
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
{pkgs, ...}: let
appdir = ".local/share/applications";
_: let
forwardPostgres = "-L 5432:127.0.0.1:5432";
hetznerStoragebox = "your-storagebox.de";
immortalis = "immortalis.kanyu-bushi.ts.net";
Expand Down Expand Up @@ -51,7 +50,13 @@ in {
};
};
git = {
diff-so-fancy.enable = true;
enable = true;
extraConfig = {
color.ui = "auto";
help.autocorrect = 10;
pull.rebase = true;
};
signing = {
key = "D245D484F3578CB17FD6DA6B67DB29BFF3C96757";
signByDefault = true;
Expand All @@ -60,42 +65,4 @@ in {
userName = "Nico Jensch";
};
};

# The apps themes not everyone might want
home.file = {
"${appdir}/teams-for-linux.desktop".text = ''
[Desktop Entry]
Categories=Network;InstantMessaging;Chat
Comment=Unofficial Microsoft Teams client for Linux
Exec=${pkgs.teams-for-linux}/bin/teams-for-linux
Icon=teams-for-linux
Name=Microsoft Teams
NoDisplay=false
Path=
StartupNotify=true
Terminal=false
TerminalOptions=
Type=Application
Version=1.4
X-KDE-SubstituteUID=false
X-KDE-Username=
'';
"${appdir}/zenmonitor.desktop".text = ''
[Desktop Entry]
Categories=GTK;System;
Comment=Monitoring software for AMD Zen-based CPUs
Exec=${pkgs.zenmonitor}/bin/zenmonitor
Icon=aptik-battery-monitor
Keywords=CPU;AMD;zen;system;core;speed;clock;temperature;voltage;
Name=Zenmonitor
NoDisplay=false
Path=
StartupNotify=true
Terminal=false
TerminalOptions=
Type=Application
X-KDE-SubstituteUID=false
X-KDE-Username=
'';
};
}
41 changes: 41 additions & 0 deletions home-manager/nico/not-standalone.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
{pkgs, ...}: let
appdir = ".local/share/applications";
in {
# The apps themes not everyone might want
home.file = {
"${appdir}/teams-for-linux.desktop".text = ''
[Desktop Entry]
Categories=Network;InstantMessaging;Chat
Comment=Unofficial Microsoft Teams client for Linux
Exec=${pkgs.teams-for-linux}/bin/teams-for-linux
Icon=teams-for-linux
Name=Microsoft Teams
NoDisplay=false
Path=
StartupNotify=true
Terminal=false
TerminalOptions=
Type=Application
Version=1.4
X-KDE-SubstituteUID=false
X-KDE-Username=
'';
"${appdir}/zenmonitor.desktop".text = ''
[Desktop Entry]
Categories=GTK;System;
Comment=Monitoring software for AMD Zen-based CPUs
Exec=${pkgs.zenmonitor}/bin/zenmonitor
Icon=aptik-battery-monitor
Keywords=CPU;AMD;zen;system;core;speed;clock;temperature;voltage;
Name=Zenmonitor
NoDisplay=false
Path=
StartupNotify=true
Terminal=false
TerminalOptions=
Type=Application
X-KDE-SubstituteUID=false
X-KDE-Username=
'';
};
}
140 changes: 56 additions & 84 deletions home-manager/standalone.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
{pkgs, ...}:
{
lib,
pkgs,
...
}:
with builtins; let
configDir = ".config";

Expand All @@ -23,7 +27,6 @@ in {
# Import individual configuration snippets
imports = [
./common.nix
./theme-launchers.nix
./misc.nix
];
# Enable Kvantum theme and GTK & place a few bigger files
Expand All @@ -47,9 +50,26 @@ in {
# this also allows us to use remote builders to reduce build times and batter usage
builders-use-substitutes = true;

experimental-features = ["flakes" "nix-command"];
# Enable experimental features
experimental-features = [
"auto-allocate-uids"
"flakes"
"nix-command"
];
};

# Disable those as they are not needed in standalone
services = {
gpg-agent = {
enableExtraSocket = lib.mkForce false;
enableScDaemon = lib.mkForce false;
};
syncthing = {
enable = lib.mkForce false;
};
};
programs.mangohud.enable = lib.mkForce false;

# Use micro as editor
home.sessionVariables = {
ALSOFT_DRIVERS = "pipewire";
Expand Down Expand Up @@ -85,7 +105,6 @@ in {
"gpush" = "git push";
"ip" = "ip --color=auto";
"jctl" = "journalctl -p 3 -xb";
"ls" = "eza -al --color=always --group-directories-first --icons";
"psmem" = "ps auxf | sort -nr -k 4";
"psmem10" = "ps auxf | sort -nr -k 4 | head -1";
"su" = "sudo su -";
Expand All @@ -102,6 +121,14 @@ in {
nix-direnv.enable = true;
};

# Eza for a better ls
eza = {
enableAliases = true;
enable = true;
git = true;
icons = true;
};

# The fish shell, default for terminals
fish = {
enable = true;
Expand Down Expand Up @@ -141,7 +168,6 @@ in {
"gitlog" = "git log --oneline --graph --decorate --all";
"ip" = "ip --color=auto";
"jctl" = "journalctl -p 3 -xb";
"ls" = "eza -al --color=always --group-directories-first --icons";
"psmem" = "ps auxf | sort -nr -k 4";
"psmem10" = "ps auxf | sort -nr -k 4 | head -1";
"vdir" = "vdir --color=auto";
Expand All @@ -156,6 +182,9 @@ in {
# This is needed to make use of the home-manager
home-manager.enable = true;

# Nix index for faster search
nix-index.enable = true;

# The starship prompt
starship = {
enable = true;
Expand Down Expand Up @@ -208,113 +237,56 @@ in {
};
};

# Only CLI apps
home.packages = with pkgs; [
age
alejandra
ansible
appimage-run
asciinema
bind
bind.dnsutils
btop
cached-nix-shell
cloudflared
deadnix
duf
eza
jq
killall
micro
mosh
nettools
nmap
nvd
sops
tldr
tmux
traceroute
ugrep
wget
whois
appimage-run
asciinema
# telegram-desktop_git
alejandra
ansible
#beekeeper-studio
bind.dnsutils
deadnix
gh
#gitkraken
heroku
hugo
jq
killall
manix
micro
mongodb-compass
mosh
nerdctl
nettools
nix-prefetch-git
nixd
nixos-generators
nixpkgs-lint
nixpkgs-review
nmap
nodePackages_latest.prettier
nodejs
nvd
ruff
shellcheck
shfmt

#speedcrunch
sops
sqlite
statix
#termius
vagrant
tldr
tmux
traceroute
ugrep
ventoy-full
(vscode-with-extensions.override {
vscodeExtensions = with vscode-extensions;
[
bbenoist.nix
# charliermarsh.ruff
davidanson.vscode-markdownlint
eamodio.gitlens
esbenp.prettier-vscode
foxundermoon.shell-format
github.codespaces
github.copilot
github.vscode-github-actions
github.vscode-pull-request-github
jnoortheen.nix-ide
kamadorueda.alejandra
ms-azuretools.vscode-docker
ms-python.python
ms-python.vscode-pylance
ms-vscode-remote.remote-ssh
ms-vscode.hexeditor
ms-vsliveshare.vsliveshare
njpwerner.autodocstring
pkief.material-icon-theme
redhat.vscode-xml
redhat.vscode-yaml
timonwong.shellcheck
tyriar.sort-lines
]
++ pkgs.vscode-utils.extensionsFromVscodeMarketplace [
{
name = "sweet-vscode";
publisher = "eliverlara";
sha256 = "sha256-kJgqMEJHyYF3GDxe1rnpTEmbfJE01tyyOFjRUp4SOds=";
version = "1.1.1";
}
{
# Available in nixpkgs, but outdated (0.4.0) at the time of adding
name = "vscode-tailscale";
publisher = "tailscale";
sha256 = "sha256-MKiCZ4Vu+0HS2Kl5+60cWnOtb3udyEriwc+qb/7qgUg=";
version = "1.0.0";
}
];
})
vulnix
#wireshark
#xdg-utils
wget
whois
yarn

#speedcrunch
sqlite
#sqlitebrowser
#teams-for-linux
#virt-manager
];

# Don't change this
Expand Down

0 comments on commit 515ef23

Please sign in to comment.