This commit is contained in:
sadan 2024-11-26 17:01:58 -05:00
parent 59ee516926
commit 5a3af882ec
No known key found for this signature in database
61 changed files with 705 additions and 562 deletions

View file

@ -1,5 +1,11 @@
{ ... }:
{
{pkgs, ...}: {
home = {
packages = with pkgs; [
spotify
pulseaudioFull
pavucontrol
];
};
xdg = {
desktopEntries = {
spotifyOpen = {
@ -14,4 +20,4 @@
};
};
};
}
}

View file

@ -0,0 +1,14 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
btop
];
file = {
btop = {
recursive = true;
source = ../dotfiles/btop;
target = "./.config/btop";
};
}
}
}

View file

@ -0,0 +1,18 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
meson
cmake
clang
glib
glibc
llvmPackages_19.clang-tools
];
file = {
eslint_d_config = {
source = ../dotfiles/eslintrc.json;
target = "./.config/.eslintrc.json";
};
};
};
}

View file

@ -0,0 +1,8 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
gnumake
linuxHeaders
];
};
}

View file

@ -0,0 +1,7 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
go
];
};
}

View file

@ -0,0 +1,12 @@
{pkgs, config, ...}:
let
pinned = import ../pinned.nix { inherit pkgs config; };
in {
home = {
packages = with pkgs; [
pinned.vscode
# codium
zed-editor
];
};
}

View file

@ -0,0 +1,5 @@
{...}: {
imports = [
./idea.nix
];
}

View file

@ -0,0 +1,7 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
jetbrains.idea-ultimate
];
};
}

View file

@ -0,0 +1,22 @@
{pkgs, ...}: {
imports = [
../prisma.nix
]
home = {
packages = with pkgs; [
deno
eslint_d
vscode-langservers-extracted
nodePackages_latest.typescript-language-server
typescript
eslint
corepack_22
nodejs_22
] ++ (with pkgs.nodePackages; [
nodemon
ts-node
pnpm
live-server
]);
}
}

View file

@ -0,0 +1,19 @@
{ pkgs, ... }: {
home = {
packages = with pkgs; [
android-studio-tools
gradle
jadx
android-studio
jetbrains.idea-ultimate
# jbeap.idea-ultimate
# jetbrains.pycharm-community
];
};
programs = {
java = {
enable = true;
package = pkgs.temurin-bin-17;
};
};
}

View file

@ -0,0 +1,7 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
lua
];
};
}

View file

@ -0,0 +1,8 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
nixfmt-rfc-style
nil
];
}
}

View file

@ -0,0 +1,7 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
php
];
};
}

View file

@ -0,0 +1,20 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
(python312.withPackages (
ps: with ps; [
pytesseract
pillow
pyzbar
pygobject3
nanoid
loguru
evdev
setuptools
xlib
]
))
python312Packages.openai-whisper
];
};
}

View file

@ -0,0 +1,7 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
rustup
];
};
}

View file

@ -0,0 +1,11 @@
{pkgs, inputs, ...}:
let
cpkg = import ../../../customPackages { inherit pkgs inputs; };
in
{
home = {
packages = [
cpkg.frog
];
};
}

View file

@ -0,0 +1,17 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
xclicker
bottles
(prismlauncher.override {
jdks = [
jdk8
jdk17
jdk22
];
})
protontricks
lutris
];
};
}

View file

@ -0,0 +1,59 @@
{ pkgs, ... }: {
home = {
packages = with pkgs; [
git
lazygit
gh
];
file = {
lazygit = {
recursive = true;
source = ../dotfiles/lazygit;
target = "./.config/lazygit";
};
gh = {
source = ../dotfiles/gh/config.yml;
target = "./.config/gh/config.yml";
};
};
shellAliases = {
lg = "lazygit";
}
sessionVariables {
LG_CONFIG_FILE = "/home/${config.home.username}/.config/lazygit/tokyonight_night.conf";
};
}
programs = {
git = {
enable = true;
userName = "sadan";
userEmail = "117494111+sadan4@users.noreply.github.com";
extraConfig = {
gpg = {
format = "ssh";
};
user = {
signingkey = "~/.ssh/id_ed25519";
};
commit = {
gpgsign = true;
};
core = {
autocrlf = "input";
};
pull = {
rebase = true;
};
push = {
autoSetupRemote = true;
};
init = {
defaultBranch = "main";
};
rerere = {
enabled = true;
};
};
};
};
}

View file

@ -1,8 +0,0 @@
{ pkgs, ... }: {
programs = {
java = {
enable = true;
package = pkgs.temurin-bin-17;
};
};
}

View file

@ -0,0 +1,11 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
ksshaskpass
xsel
libsForQt5.kinit
libsForQt5.kcolorchooser
gnome.gnome-calculator
];
}
}

View file

@ -0,0 +1,9 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
imagemagick
ffmpeg
yt-dlp
];
}
}

View file

@ -0,0 +1,7 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
davinci-resolve
];
};
}

View file

@ -0,0 +1,6 @@
{...}: {
imports = [
./cli.nix
./gui.nix
];
}

View file

@ -0,0 +1,11 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
shotcut
pinta
gimp
inkscape
obs-studio
];
}
}

View file

@ -0,0 +1,12 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
parsec-bin
protonvpn-gui
insomnia
teamviewer
filezilla
bitwarden
];
};
}

View file

@ -0,0 +1,19 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
neovim
];
file = {
nvim = {
recursive = true;
source = pkgs.lib.file.mkOutOfStoreSymlink "${pkgs.home.homeDirectory}/nixos/dotfiles/nvim";
target = "./.config/nvim";
};
};
sessionVariables = {
EDITOR = "nvim";
MANPAGER = "nvim +Man!";
MANWIDTH = "999";
};
}
}

View file

@ -0,0 +1,7 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
obsidian
];
};
}

View file

@ -0,0 +1,13 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
prisma
prisma-engines
];
sessionVariables = {
PRISMA_QUERY_ENGINE_BINARY = "${pkgs.prisma-engines}/bin/query-engine";
PRISMA_SCHEMA_ENGINE_BINARY = "${pkgs.prisma-engines}/bin/schema-engine";
PRISMA_QUERY_ENGINE_LIBRARY = "${pkgs.prisma-engines}/lib/libquery_engine.node";
};
};
}

View file

@ -0,0 +1,14 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
rofi
];
file = {
rofi = {
recursive = true;
source = ../dotfiles/rofi;
target = "./.config/rofi";
};
};
};
}

View file

@ -0,0 +1,8 @@
command -v xsel > /dev/null
if [[ $? -eq 0 ]]; then
xsel -ib $@ && exit 0
fi
command -v wslclip > /dev/null
if [[ $? -eq 0 ]]; then
wslclip $@ && exit 0
fi

View file

@ -0,0 +1,62 @@
{pkgs, lib, inputs, ...}:
let
cpkg = import ../../../customPackages { inherit pkgs inputs; };
# https://discourse.nixos.org/t/how-to-create-a-script-with-dependencies/7970/6
mkScript = { name, version ? "0.0.1", file, env ? [ ] }:
pkgs.writeTextFile {
name = "${name}-${version}";
executable = true;
destination = "/bin/${name}";
text = ''
for i in ${lib.concatStringsSep " " env}; do
export PATH="$i/bin:$PATH"
done
exec ${bash}/bin/bash ${file} $@
'';
};
in
{
home = {
packages = with pkgs; [
# env for clipboard command will be required by their respective environemnts
(mkScript {
name = "paste";
file = ./paste.sh;
})
(mkScript {
name = "copy";
file = ./copy.sh;
})
(mkScript {
name = "http2ssh";
file = ./http2ssh.sh;
env = [git];
})
(mkScript {
name = "git_fetchAll";
file = ./git_fetchAll.sh;
env = [git];
})
(mkScript {
name = "install_eslint";
file = ./install_eslint.sh;
})
(mkScript {
name = "math";
file = ./math.sh;
env = [python3];
})
(mkScript {
name = "hashi18n";
file = ./hashi18n.sh;
})
];
file = {
scripts = {
source = "${cpkg.scripts}";
target = ".scripts";
};
};
};
}

View file

@ -0,0 +1,3 @@
git branch -r | grep -v '\->' | sed "s,\x1B\[[0-9;]*[a-zA-Z],,g" | while read remote; do git branch --track "${remote#origin/}" "$remote"; done
git fetch --all
git pull --all

View file

@ -0,0 +1 @@
xsel -ob | node $HOME/.scripts/hash.js | tr -d '\n' | xsel -ib

View file

@ -0,0 +1,12 @@
set -eo pipefail
if [[ -z $1 ]]; then
echo "You need to provide a remote name";
echo "Avilable remotes";
git remote -v;
exit 1;
fi
URL=$(git remote get-url $1);
URL=${URL/https:\/\//git@};
URL=${URL/\//:};
git remote set-url $1 $URL;

View file

@ -0,0 +1,10 @@
set -x
cp $HOME/.config/.eslintrc.json .
pkgs=("@stylistic/eslint-plugin" "@typescript-eslint/eslint-plugin")
if [[ -z $1 ]]; then
echo please specify npm, pnpm, or yarn
exit 1
fi
for i in "${pkgs[@]}"; do
`$1 i -D $i`
done

View file

@ -0,0 +1,2 @@
set -e
python3 -c "print($*)"

View file

@ -0,0 +1,8 @@
command -v xsel > /dev/null
if [[ $? -eq 0 ]]; then
xsel -ob && exit 0
fi
command -v wslclip > /dev/null
if [[ $? -eq 0 ]]; then
wslclip -g && exit 0
fi

View file

@ -0,0 +1,16 @@
{pkgs, ...}: {
imports = [
./arrpc.nix
];
home = {
packages = with pkgs;[
legcord
cinny-desktop
element-desktop
(pkgs.discord.override {
withVencord = true;
})
vesktop
];
};
}

View file

@ -0,0 +1,15 @@
{ config, inputs, ... }:
{
imports = [
inputs.sops-nix.homeManagerModules.sops
];
sops = {
age.keyFile = "/home/${config.home.username}/.config/sops/age/keys.txt";
defaultSopsFile = ../../../secrets.yaml;
secrets.hosts = {
format = "binary";
sopsFile = ../../../secrets/hosts;
path = "/home/${config.home.username}/.config/gh/hosts.yml";
};
};
}

View file

@ -0,0 +1,18 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
warp-terminal
kitty
onefetch
hyfetch
neofetch
];
file = {
kitty = {
recursive = true;
source = ../dotfiles/kitty;
target = "./.config/kitty";
};
};
}
}

View file

@ -0,0 +1,22 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
p7zip
dig
bat
usbutils
tree
sops
fzf
jq
unzip
];
sessionVariables = {
BAT_THEME = "Dracula";
SSH_ASKPASS_REQUIRE = "prefer";
};
sessionPath = [
"$HOME/.local/bin"
];
};
}

View file

@ -0,0 +1,9 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
bottles
virt-manager
qemu_full
];
};
}

View file

@ -0,0 +1,12 @@
{pkgs, ...}: {
home = {
packages = with pkgs; [
firefox-devedition
google-chrome
thunderbird
jellyfin-web
jellyfin-media-player
vlc
];
};
}

View file

@ -1,6 +1,7 @@
{ lib, pkgs, ... }:
let
# TODO: make these modular
_ = [
"source ${pkgs.zsh-powerlevel10k}/share/zsh-powerlevel10k/powerlevel10k.zsh-theme"
"source ${pkgs.zsh-syntax-highlighting}/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh"
@ -12,6 +13,19 @@ let
zshInitArgs = lib.concatMapStrings (x: x + "\n") _;
in
{
home = {
packages = with pkgs; [
zsh-powerlevel10k
zsh-syntax-highlighting
];
file = {
p10k = {
recursive = true;
source = ../dotfiles/.p10k.zsh;
target = ".p10k.zsh";
};
};
};
programs = {
zoxide = {
enable = true;