Compare commits
3 Commits
160f3ab303
...
7f90793909
Author | SHA1 | Date | |
---|---|---|---|
7f90793909 | |||
3453bc27e4 | |||
a7fdb34dc9 |
10
darwin.nix
10
darwin.nix
|
@ -1,6 +1,7 @@
|
||||||
{ system, pkgs, pkgs-unsupported, nixpkgs-flake, ... }:
|
{ system, pkgs, pkgs-unsupported, nixpkgs-flake, ... }:
|
||||||
|
|
||||||
let prismlauncher = pkgs-unsupported.prismlauncher.override { jdks = [ pkgs.jdk8 pkgs.jdk21 ]; };
|
let prismlauncher = pkgs-unsupported.prismlauncher.override { jdks = [ pkgs.jdk8 pkgs.jdk21 ]; };
|
||||||
|
fileicon = import ./fileicon.nix { inherit pkgs; };
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
# TODO: nix options should be joint for darwin and nix-os
|
# TODO: nix options should be joint for darwin and nix-os
|
||||||
|
@ -120,6 +121,7 @@ in
|
||||||
|
|
||||||
system.defaults.dock.persistent-apps = [
|
system.defaults.dock.persistent-apps = [
|
||||||
# Finder? LaunchPad?
|
# Finder? LaunchPad?
|
||||||
|
"/System/Applications/Launchpad.app/"
|
||||||
"${pkgs.keepassxc}/Applications/KeePassXC.app"
|
"${pkgs.keepassxc}/Applications/KeePassXC.app"
|
||||||
"/System/Applications/Calendar.app/"
|
"/System/Applications/Calendar.app/"
|
||||||
"/System/Applications/Mail.app/"
|
"/System/Applications/Mail.app/"
|
||||||
|
@ -133,12 +135,18 @@ in
|
||||||
"/Applications/krita.app/"
|
"/Applications/krita.app/"
|
||||||
"${pkgs.inkscape}/Applications/Inkscape.app/"
|
"${pkgs.inkscape}/Applications/Inkscape.app/"
|
||||||
"/Users/xenia/Applications/Home Manager Apps/Alacritty.app"
|
"/Users/xenia/Applications/Home Manager Apps/Alacritty.app"
|
||||||
|
"/Applications/"
|
||||||
|
"/Applications/Nix Apps/"
|
||||||
];
|
];
|
||||||
|
|
||||||
# Set desktop background
|
|
||||||
system.activationScripts.extraActivation.text = ''
|
system.activationScripts.extraActivation.text = ''
|
||||||
|
echo "Setting background image..."
|
||||||
osascript -e "tell application \"System Events\" to tell every desktop to set picture to \"${./backgrounds/enby-mac.png}\" as POSIX file"
|
osascript -e "tell application \"System Events\" to tell every desktop to set picture to \"${./backgrounds/enby-mac.png}\" as POSIX file"
|
||||||
'';
|
'';
|
||||||
|
system.activationScripts.postActivation.text = ''
|
||||||
|
echo "Setting nix-apps folder icon..."
|
||||||
|
${fileicon}/bin/fileicon set '/Applications/Nix Apps/' ${./nix-apps-folder.png}
|
||||||
|
'';
|
||||||
|
|
||||||
system.defaults.menuExtraClock = {
|
system.defaults.menuExtraClock = {
|
||||||
ShowSeconds = true;
|
ShowSeconds = true;
|
||||||
|
|
23
fileicon.nix
Normal file
23
fileicon.nix
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
{ pkgs }:
|
||||||
|
let
|
||||||
|
name = "fileicon";
|
||||||
|
version = "v0.3.4";
|
||||||
|
src = pkgs.fetchFromGitHub {
|
||||||
|
owner = "mklement0";
|
||||||
|
repo = name;
|
||||||
|
rev = version;
|
||||||
|
hash = "sha256-AqAnY/neBIkxgB5ioyExO4NSLw0Rk4wTo9hcCHTqOQ8=";
|
||||||
|
};
|
||||||
|
in pkgs.stdenv.mkDerivation {
|
||||||
|
inherit src name version;
|
||||||
|
|
||||||
|
dontBuild = true;
|
||||||
|
installPhase = ''
|
||||||
|
cd "$src"
|
||||||
|
mkdir -p "$out/bin" "$out/share/man"
|
||||||
|
cp bin/fileicon "$out/bin/"
|
||||||
|
cp man/fileicon.1 "$out/share/man"
|
||||||
|
'';
|
||||||
|
|
||||||
|
# TODO: Run the test suite?
|
||||||
|
}
|
|
@ -63,6 +63,8 @@
|
||||||
mkNixOsGraphical = opts: import ./nixos/graphical.nix opts;
|
mkNixOsGraphical = opts: import ./nixos/graphical.nix opts;
|
||||||
mkNixOsNetworking = opts: import ./nixos/networking.nix opts;
|
mkNixOsNetworking = opts: import ./nixos/networking.nix opts;
|
||||||
in {
|
in {
|
||||||
|
packages."aarch64-darwin".fileicon = import ./fileicon.nix { pkgs = mkPkgs "aarch64-darwin"; };
|
||||||
|
|
||||||
homeConfigurations."xenia@Joe-Bidens-MacBook-Pro" =
|
homeConfigurations."xenia@Joe-Bidens-MacBook-Pro" =
|
||||||
let
|
let
|
||||||
system = "aarch64-darwin";
|
system = "aarch64-darwin";
|
||||||
|
|
BIN
nix-apps-folder.png
Normal file
BIN
nix-apps-folder.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 560 KiB |
Loading…
Reference in New Issue
Block a user