fix(macos): trampoline apps
This commit is contained in:
parent
c707909f4f
commit
01240450d2
3 changed files with 28 additions and 0 deletions
|
@ -21,6 +21,10 @@
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
mac-app-util = {
|
||||||
|
url = "github:hraban/mac-app-util";
|
||||||
|
};
|
||||||
|
|
||||||
# Home Manager
|
# Home Manager
|
||||||
home-manager = {
|
home-manager = {
|
||||||
url = "github:nix-community/home-manager/master";
|
url = "github:nix-community/home-manager/master";
|
||||||
|
@ -104,6 +108,7 @@
|
||||||
, nixpkgs
|
, nixpkgs
|
||||||
, nix-on-droid
|
, nix-on-droid
|
||||||
, nix-darwin
|
, nix-darwin
|
||||||
|
, mac-app-util
|
||||||
, home-manager
|
, home-manager
|
||||||
, disko
|
, disko
|
||||||
, deploy-rs
|
, deploy-rs
|
||||||
|
|
20
modules/home-manager/darwin-trampolines/default.nix
Normal file
20
modules/home-manager/darwin-trampolines/default.nix
Normal file
|
@ -0,0 +1,20 @@
|
||||||
|
{ inputs, outputs, ... }:
|
||||||
|
{ lib, pkgs, config, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
imports = [ ];
|
||||||
|
|
||||||
|
options = { };
|
||||||
|
|
||||||
|
config = {
|
||||||
|
home.activation = lib.mkIf pkgs.stdenv.isDarwin {
|
||||||
|
trampolineApps = let
|
||||||
|
mac-app-util = inputs.mac-app-util.packages.${pkgs.stdenv.system}.default;
|
||||||
|
in lib.hm.dag.entryAfter [ "writeBoundary" ] ''
|
||||||
|
fromDir="$HOME/Applications/Home Manager Apps"
|
||||||
|
toDir="$HOME/Applications/Home Manager Trampolines"
|
||||||
|
${mac-app-util}/bin/mac-app-util sync-trampolines "$fromDir" "$toDir"
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -1,3 +1,4 @@
|
||||||
|
{ inputs, outputs, ... }:
|
||||||
{ lib, pkgs, config, ... }:
|
{ lib, pkgs, config, ... }:
|
||||||
|
|
||||||
with lib;
|
with lib;
|
||||||
|
@ -181,6 +182,8 @@ in
|
||||||
|
|
||||||
# echo "Set hostname"
|
# echo "Set hostname"
|
||||||
# sudo scutil --set HostName $hostname
|
# sudo scutil --set HostName $hostname
|
||||||
|
|
||||||
|
${inputs.mac-app-util.packages.${pkgs.stdenv.system}.default}/bin/mac-app-util sync-trampolines "/Applications/Nix Apps" "/Applications/Nix Trampolines"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
# User-level settings
|
# User-level settings
|
||||||
|
|
Loading…
Reference in a new issue