mirror of
https://github.com/nickolaj-jepsen/nixos.git
synced 2026-01-22 16:16:50 +01:00
refactor: prepare new modules structure
This commit is contained in:
parent
d25e24c15b
commit
bf82970b9e
65 changed files with 94 additions and 94 deletions
10
legacy_modules/apps/chromium.nix
Normal file
10
legacy_modules/apps/chromium.nix
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
{pkgsUnstable, ...}: {
|
||||
fireproof.home-manager.programs.chromium = {
|
||||
enable = true;
|
||||
package = pkgsUnstable.chromium;
|
||||
extensions = [
|
||||
"cjpalhdlnbpafiamejdnhcphjbkeiagm" # uBlock Origin
|
||||
"nngceckbapebfimnlniiiahkandclblb" # Bitwarden
|
||||
];
|
||||
};
|
||||
}
|
||||
9
legacy_modules/apps/claude.nix
Normal file
9
legacy_modules/apps/claude.nix
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
inputs,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
environment.systemPackages = [
|
||||
inputs.claude-desktop.packages.${pkgs.system}.claude-desktop-with-fhs
|
||||
];
|
||||
}
|
||||
5
legacy_modules/apps/ferdium.nix
Normal file
5
legacy_modules/apps/ferdium.nix
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
{pkgsUnstable, ...}: {
|
||||
environment.systemPackages = [
|
||||
pkgsUnstable.ferdium
|
||||
];
|
||||
}
|
||||
62
legacy_modules/apps/firefox.nix
Normal file
62
legacy_modules/apps/firefox.nix
Normal file
|
|
@ -0,0 +1,62 @@
|
|||
{
|
||||
pkgsUnstable,
|
||||
inputs,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
nur = inputs.nur.legacyPackages.${pkgs.system};
|
||||
extensions = nur.repos.rycee.firefox-addons;
|
||||
in {
|
||||
programs.firefox = {
|
||||
enable = true;
|
||||
package = pkgsUnstable.firefox;
|
||||
};
|
||||
|
||||
xdg.mime.defaultApplications = {
|
||||
"text/html" = "firefox.desktop";
|
||||
"x-scheme-handler/http" = "firefox.desktop";
|
||||
"x-scheme-handler/https" = "firefox.desktop";
|
||||
"x-scheme-handler/about" = "firefox.desktop";
|
||||
"x-scheme-handler/unknown" = "firefox.desktop";
|
||||
};
|
||||
|
||||
fireproof.home-manager = {
|
||||
programs.firefox = {
|
||||
enable = true;
|
||||
package = pkgsUnstable.firefox;
|
||||
profiles.default = {
|
||||
extensions.packages = with extensions; [
|
||||
# Privacy
|
||||
ublock-origin
|
||||
clearurls
|
||||
libredirect
|
||||
smartproxy
|
||||
|
||||
# Security
|
||||
bitwarden
|
||||
|
||||
# Media
|
||||
dearrow
|
||||
sponsorblock
|
||||
|
||||
# Search
|
||||
kagi-search
|
||||
|
||||
# Productivity
|
||||
new-tab-override
|
||||
|
||||
# Social
|
||||
reddit-enhancement-suite
|
||||
|
||||
# Development
|
||||
react-devtools
|
||||
refined-github
|
||||
];
|
||||
|
||||
settings = {
|
||||
"browser.startup.homepage" = "https://flame.nickolaj.com";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
50
legacy_modules/apps/ghostty.nix
Normal file
50
legacy_modules/apps/ghostty.nix
Normal file
|
|
@ -0,0 +1,50 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
environment.systemPackages = with pkgs; [
|
||||
ghostty
|
||||
];
|
||||
fireproof.home-manager = {
|
||||
programs.ghostty = {
|
||||
enable = true;
|
||||
enableFishIntegration = config.programs.fish.enable;
|
||||
settings = {
|
||||
window-decoration = false;
|
||||
theme = "fireproof";
|
||||
font-size = 11;
|
||||
font-family = "Hack Nerd Font";
|
||||
window-inherit-font-size = false;
|
||||
};
|
||||
themes = {
|
||||
fireproof = {
|
||||
background = "1C1B1A";
|
||||
cursor-color = "DAD8CE";
|
||||
foreground = "DAD8CE";
|
||||
palette = [
|
||||
"0=#100F0F"
|
||||
"1=#AF3029"
|
||||
"2=#66800B"
|
||||
"3=#AD8301"
|
||||
"4=#205EA6"
|
||||
"5=#A02F6F"
|
||||
"6=#24837B"
|
||||
"7=#DAD8CE"
|
||||
"8=#878580"
|
||||
"9=#D14D41"
|
||||
"10=#879A39"
|
||||
"11=#D0A215"
|
||||
"12=#4385BE"
|
||||
"13=#CE5D97"
|
||||
"14=#3AA99F"
|
||||
"15=#F2F0E5"
|
||||
];
|
||||
selection-background = "403E3C";
|
||||
selection-foreground = "DAD8CE";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
fireproof.base.defaults.terminal = "ghostty";
|
||||
}
|
||||
5
legacy_modules/apps/obsidian.nix
Normal file
5
legacy_modules/apps/obsidian.nix
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
{pkgsUnstable, ...}: {
|
||||
environment.systemPackages = [
|
||||
pkgsUnstable.obsidian
|
||||
];
|
||||
}
|
||||
6
legacy_modules/apps/ollama.nix
Normal file
6
legacy_modules/apps/ollama.nix
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
_: {
|
||||
services.ollama = {
|
||||
enable = true;
|
||||
acceleration = "cuda";
|
||||
};
|
||||
}
|
||||
10
legacy_modules/apps/pycharm.nix
Normal file
10
legacy_modules/apps/pycharm.nix
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
{pkgsUnstable, ...}: {
|
||||
environment.systemPackages = [
|
||||
(pkgsUnstable.jetbrains.pycharm-professional.override {
|
||||
vmopts = ''
|
||||
-Dawt.toolkit.name=WLToolkit
|
||||
-Xmx8G
|
||||
'';
|
||||
})
|
||||
];
|
||||
}
|
||||
5
legacy_modules/apps/slack.nix
Normal file
5
legacy_modules/apps/slack.nix
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
{pkgsUnstable, ...}: {
|
||||
environment.systemPackages = [
|
||||
pkgsUnstable.slack
|
||||
];
|
||||
}
|
||||
22
legacy_modules/apps/spotify.nix
Normal file
22
legacy_modules/apps/spotify.nix
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
{
|
||||
username,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
environment.systemPackages = with pkgs; [
|
||||
spotify
|
||||
];
|
||||
|
||||
age.secrets.spotify-player = {
|
||||
rekeyFile = ../../secrets/spotify-player.age;
|
||||
path = "/home/${username}/.cache/spotify-player/credentials.json";
|
||||
mode = "0600";
|
||||
owner = username;
|
||||
};
|
||||
|
||||
fireproof.home-manager = {
|
||||
programs.spotify-player = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
5
legacy_modules/apps/sublime-merge.nix
Normal file
5
legacy_modules/apps/sublime-merge.nix
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
{pkgsUnstable, ...}: {
|
||||
environment.systemPackages = [
|
||||
pkgsUnstable.sublime-merge
|
||||
];
|
||||
}
|
||||
123
legacy_modules/apps/vscode.nix
Normal file
123
legacy_modules/apps/vscode.nix
Normal file
|
|
@ -0,0 +1,123 @@
|
|||
{
|
||||
pkgsUnstable,
|
||||
pkgs,
|
||||
inputs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
vscodePackage = pkgsUnstable.vscode;
|
||||
|
||||
vscode-extensions = inputs.nix-vscode-extensions.extensions.${pkgs.system};
|
||||
vscodePkgs = vscode-extensions.vscode-marketplace // vscode-extensions.vscode-marketplace-release; # Prefer release over pre-release
|
||||
|
||||
mkFormatter = formatter: languages: {
|
||||
"[${lib.concatStringsSep "][" languages}]" = {
|
||||
"editor.defaultFormatter" = formatter;
|
||||
};
|
||||
};
|
||||
|
||||
# I can't get nix-vscode-extensions to respect allowUnfree, so this is a workaround
|
||||
allowUnfree = ext: ext.override {meta.license = [];};
|
||||
in {
|
||||
fireproof.home-manager = {
|
||||
programs.vscode = {
|
||||
enable = true;
|
||||
package = vscodePackage;
|
||||
profiles.default = {
|
||||
enableUpdateCheck = true;
|
||||
enableExtensionUpdateCheck = true;
|
||||
keybindings = [
|
||||
{
|
||||
"key" = "ctrl+shift+p";
|
||||
"command" = "editor.action.formatDocument";
|
||||
}
|
||||
];
|
||||
userSettings = lib.mkMerge [
|
||||
{
|
||||
# General
|
||||
"extensions.ignoreRecommendations" = true;
|
||||
"telemetry.telemetryLevel" = "off";
|
||||
|
||||
# Editor
|
||||
"editor.linkedEditing" = true;
|
||||
"files.exclude" = {
|
||||
"**/*.egg-info" = true;
|
||||
"**/__pycache__" = true;
|
||||
};
|
||||
|
||||
# Files
|
||||
"files.autoSave" = "afterDelay";
|
||||
|
||||
# Remote
|
||||
"remote.SSH.useLocalServer" = false;
|
||||
"remote.SSH.remotePlatform" = lib.mapAttrs (_name: _value: "linux") config.fireproof.home-manager.programs.ssh.matchBlocks;
|
||||
|
||||
# AI
|
||||
"github.copilot.editor.enableAutoCompletions" = true;
|
||||
"github.copilot.enable" = {
|
||||
"*" = true;
|
||||
"plaintext" = true;
|
||||
"markdown" = true;
|
||||
"scminput" = true;
|
||||
};
|
||||
"chat.agent.enabled" = true;
|
||||
"github.copilot.chat.agent.thinkingTool" = true;
|
||||
"github.copilot.chat.codesearch.enabled" = true;
|
||||
"github.copilot.nextEditSuggestions.enabled" = true;
|
||||
|
||||
# Theme
|
||||
"workbench.colorTheme" = "Darcula Theme from IntelliJ";
|
||||
"window.titleBarStyle" = "custom";
|
||||
"editor.fontFamily" = "'Hack Nerd Font', 'Hack', 'monospace', monospace";
|
||||
|
||||
# Keybindings
|
||||
"workbench.commandPalette.experimental.suggestCommands" = true; # Emulates IntelliJ's "Search Everywhere"
|
||||
|
||||
# nix-ide
|
||||
"nix.enableLanguageServer" = true;
|
||||
"nix.serverPath" = lib.getExe pkgs.nil;
|
||||
"nix.serverSettings" = {
|
||||
nil.formatting.command = ["nix" "fmt" "--" "--"];
|
||||
};
|
||||
}
|
||||
(mkFormatter "esbenp.prettier-vscode" ["json" "jsonc" "markdown" "css" "scss" "typescript" "typescriptreact" "html" "yaml"])
|
||||
(mkFormatter "charliermarsh.ruff" ["python"])
|
||||
];
|
||||
extensions = with vscodePkgs; [
|
||||
# Remote
|
||||
(allowUnfree ms-vscode-remote.remote-ssh)
|
||||
|
||||
# AI
|
||||
(allowUnfree github.copilot)
|
||||
(allowUnfree github.copilot-chat)
|
||||
|
||||
# Git(hub)
|
||||
github.vscode-pull-request-github
|
||||
|
||||
# Python
|
||||
ms-pyright.pyright
|
||||
ms-python.python
|
||||
charliermarsh.ruff
|
||||
|
||||
# JavaScript
|
||||
dbaeumer.vscode-eslint
|
||||
esbenp.prettier-vscode
|
||||
|
||||
# Nix
|
||||
jnoortheen.nix-ide
|
||||
|
||||
# Other languages
|
||||
nefrob.vscode-just-syntax
|
||||
redhat.vscode-yaml
|
||||
|
||||
# Theme
|
||||
trinm1709.dracula-theme-from-intellij
|
||||
|
||||
# Keybindings
|
||||
k--kato.intellij-idea-keybindings
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue