Merge branch 'main' of github.com:LarssonMartin1998/.dotfiles

This commit is contained in:
Martin Lasson 2025-04-16 22:59:45 +02:00
commit 122874a915
13 changed files with 83 additions and 36 deletions

View file

@ -133,10 +133,17 @@
darwinConfigurations = darwinConfigurations =
let let
baseDarwinConfig = makeSystemConfig { makeDarwinSystem =
name = "darwin"; {
name,
user,
extraModules ? [ ],
}:
makeSystemConfig {
inherit name;
system = "aarch64-darwin"; system = "aarch64-darwin";
builder = nix-darwin.lib.darwinSystem; builder = nix-darwin.lib.darwinSystem;
extraModules = [ extraModules = [
./nix/system/darwin.nix ./nix/system/darwin.nix
nix-homebrew.darwinModules.nix-homebrew nix-homebrew.darwinModules.nix-homebrew
@ -144,25 +151,36 @@
nix-homebrew = { nix-homebrew = {
enable = true; enable = true;
enableRosetta = true; enableRosetta = true;
user = "larssonmartin1998-mac"; user = user; # pass the user parameter
taps = { taps = {
"homebrew/core" = homebrew-core; "homebrew/core" = homebrew-core;
"homebrew/cask" = homebrew-cask; "homebrew/cask" = homebrew-cask;
"homebrew/bundle" = homebrew-bundle; "homebrew/bundle" = homebrew-bundle;
"nikitabobko/tap" = homebrew-nikitabobko; "nikitabobko/tap" = homebrew-nikitabobko;
}; };
mutableTaps = true; mutableTaps = false;
}; };
} }
]; ] ++ extraModules;
specialArgs = { specialArgs = {
self = self; self = self;
}; };
}; };
in in
{ {
"darwin" = baseDarwinConfig; darwin = makeDarwinSystem {
"darwin_work" = baseDarwinConfig; name = "darwin";
user = "larssonmartin1998-mac";
};
darwin_work = makeDarwinSystem {
name = "darwin_work";
user = "martin.larsson";
extraModules = [
./nix/system/darwin_work.nix
];
};
}; };
homeConfigurations = { homeConfigurations = {
@ -187,7 +205,10 @@
"darwin" = makeHomeConfig { "darwin" = makeHomeConfig {
name = "darwin"; name = "darwin";
system = "aarch64-darwin"; system = "aarch64-darwin";
extraModules = [ ./nix/pkgs/darwin.nix ]; extraModules = [
./nix/pkgs/darwin.nix
./nix/pkgs/darwin_personal.nix
];
}; };
"darwin_work" = makeHomeConfig { "darwin_work" = makeHomeConfig {

View file

@ -23,8 +23,6 @@
jq jq
starship starship
fastfetch fastfetch
clang
clang-tools
nixfmt-rfc-style nixfmt-rfc-style
luajit luajit
zoxide zoxide

View file

@ -6,7 +6,7 @@
# accordingly, and then commit it. # accordingly, and then commit it.
home = { home = {
# Stub values for demonstration. Override these in local branch. # Stub values for demonstration. Override these in local branch.
username = "nixos"; username = "martin.larsson";
homeDirectory = "/home/nixos"; homeDirectory = "/Users/martin.larsson";
}; };
} }

View file

@ -3,6 +3,8 @@
}: }:
{ {
system = { system = {
stateVersion = "24.11"; stateVersion = 5;
}; };
nix-homebrew.user = "martin.larsson";
} }

View file

@ -0,0 +1,10 @@
{ pkgs, ... }:
{
home = {
packages = with pkgs; [
clang
clang-tools
];
};
}

View file

@ -8,6 +8,8 @@
])) ]))
pcre pcre
ccache ccache
mkdocs
]; ];
}; };
} }

View file

@ -112,8 +112,6 @@ in
ninja ninja
tldr tldr
nerd-fonts.caskaydia-mono nerd-fonts.caskaydia-mono
clang
clang-tools
lldb lldb
nodejs nodejs
tree-sitter tree-sitter

View file

@ -4,6 +4,8 @@
packages = with pkgs; [ packages = with pkgs; [
wl-clipboard-rs wl-clipboard-rs
sway sway
clang
clang-tools
]; ];
file = { file = {
".config/sway".source = ../sway; ".config/sway".source = ../sway;

View file

@ -3,6 +3,8 @@
home = { home = {
packages = with pkgs; [ packages = with pkgs; [
wslu wslu
clang
clang-tools
]; ];
}; };
} }

View file

@ -65,7 +65,7 @@
enableKeyMapping = true; enableKeyMapping = true;
nonUS.remapTilde = true; nonUS.remapTilde = true;
remapCapsLockToEscape = true; remapCapsLockToEscape = true;
swapLeftCtrlAndFn = true; swapLeftCtrlAndFn = false;
}; };
activationScripts.applications.text = activationScripts.applications.text =
let let

View file

@ -0,0 +1,11 @@
{
...
}:
{
homebrew = {
brews = [
"openjdk"
"llvm"
];
};
}

View file

@ -27,7 +27,7 @@ function M.setup()
end end
utils.set_keymap_list({ utils.set_keymap_list({
{ "<leader>ff", function() M.format() end }, { "<leader>ff", function() M.format(true) end },
{ "<leader>fe", function() M.format_enable() end }, { "<leader>fe", function() M.format_enable() end },
{ "<leader>fd", function() M.format_disable() end }, { "<leader>fd", function() M.format_disable() end },
}) })

View file

@ -49,6 +49,7 @@ return {
"python", "python",
"latex", "latex",
"typst", "typst",
"ruby",
}, },
sync_install = false, sync_install = false,
-- This can be updated to a list of languages instead of defaulting to true -- This can be updated to a list of languages instead of defaulting to true