Skip to content

Commit

Permalink
fix: combine all brews and resolve finder/dock entries
Browse files Browse the repository at this point in the history
  • Loading branch information
tboerger committed Aug 31, 2024
1 parent bbe2011 commit 9a44428
Show file tree
Hide file tree
Showing 34 changed files with 138 additions and 930 deletions.
2 changes: 1 addition & 1 deletion profiles/shared/modules/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
type = types.str;
};

modules = { };
programs = { };
};
};
}
30 changes: 14 additions & 16 deletions profiles/shared/modules/dock.nix
Original file line number Diff line number Diff line change
Expand Up @@ -76,23 +76,21 @@ in
in
{
home = {
packages = with pkgs; [
dockutil
];
activation = {
updateDockEntries = ''
echo >&2 "Setting up dock items..."
haveURIs="$(${pkgs.dockutil}/bin/dockutil --list | ${pkgs.coreutils}/bin/cut -f2)"
if ! diff -wu <(echo -n "$haveURIs") <(echo -n '${wantURIs}') >&2; then
echo >&2 "Resetting dock"
${pkgs.dockutil}/bin/dockutil --no-restart --remove all
${createEntries}
killall Dock
else
echo >&2 "Dock is how we want it"
fi
'';
};
};

system.activationScripts.postUserActivation.text = ''
echo >&2 "Setting up dock items..."
haveURIs="$(${pkgs.dockutil}/bin/dockutil --list | ${pkgs.coreutils}/bin/cut -f2)"
if ! diff -wu <(echo -n "$haveURIs") <(echo -n '${wantURIs}') >&2; then
echo >&2 "Resetting dock"
${pkgs.dockutil}/bin/dockutil --no-restart --remove all
${createEntries}
killall Dock
else
echo >&2 "Dock is how we want it"
fi
'';
}
);
}
28 changes: 13 additions & 15 deletions profiles/shared/modules/finder.nix
Original file line number Diff line number Diff line change
Expand Up @@ -55,22 +55,20 @@ in
in
{
home = {
packages = with pkgs; [
mysides
];
activation = {
updateFinderEntries = ''
echo >&2 "Setting up finder items..."
haveURIs="$(${pkgs.mysides}/bin/mysides list | ${pkgs.coreutils}/bin/cut -d' ' -f3)"
if ! diff -wu <(echo -n "$haveURIs") <(echo -n '${wantURIs}') >&2; then
echo >&2 "Resetting finder"
${pkgs.mysides}/bin/mysides remove all
${createEntries}
else
echo >&2 "Finder is how we want it"
fi
'';
};
};

system.activationScripts.postUserActivation.text = ''
echo >&2 "Setting up finder items..."
haveURIs="$(${pkgs.mysides}/bin/mysides list | ${pkgs.coreutils}/bin/cut -d' ' -f3)"
if ! diff -wu <(echo -n "$haveURIs") <(echo -n '${wantURIs}') >&2; then
echo >&2 "Resetting finder"
${pkgs.mysides}/bin/mysides remove all
${createEntries}
else
echo >&2 "Finder is how we want it"
fi
'';
}
);
}
27 changes: 0 additions & 27 deletions profiles/shared/programs/alfred.nix

This file was deleted.

27 changes: 0 additions & 27 deletions profiles/shared/programs/alttab.nix

This file was deleted.

27 changes: 0 additions & 27 deletions profiles/shared/programs/appcleaner.nix

This file was deleted.

28 changes: 0 additions & 28 deletions profiles/shared/programs/browser.nix

This file was deleted.

39 changes: 0 additions & 39 deletions profiles/shared/programs/chat.nix

This file was deleted.

42 changes: 8 additions & 34 deletions profiles/shared/programs/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,40 +2,14 @@

{
imports = [
# ./act.nix
# ./alfred.nix
# ./alttab.nix
# ./appcleaner.nix
# ./browser.nix
# ./chat.nix
# ./clouds.nix
# ./develop.nix
# ./docker.nix
# ./etcher.nix
# ./gaming.nix
# ./gnupg.nix
# ./golang.nix
# ./graphics.nix
# ./hammerspoon.nix
# ./ice.nix
# ./itsycal.nix
# ./joplin.nix
# ./kube.nix
# ./kya.nix
# ./macdown.nix
# ./music.nix
# ./nextcloud.nix
# ./ngrok.nix
# ./office.nix
# ./onlyswitch.nix
# ./password.nix
# ./rectangle.nix
# ./stats.nix
# ./streaming.nix
# ./terminal.nix
# ./utm.nix
# ./work.nix
# ./yubikey.nix
./act.nix
./clouds.nix
./develop.nix
./gnupg.nix
./golang.nix
./hammerspoon.nix
./kube.nix
./ngrok.nix
];

options = with lib; {
Expand Down
33 changes: 0 additions & 33 deletions profiles/shared/programs/docker.nix

This file was deleted.

27 changes: 0 additions & 27 deletions profiles/shared/programs/etcher.nix

This file was deleted.

48 changes: 0 additions & 48 deletions profiles/shared/programs/gaming.nix

This file was deleted.

Loading

0 comments on commit 9a44428

Please sign in to comment.