mirror of
https://github.com/nix-community/home-manager.git
synced 2025-11-08 11:36:05 +01:00
superfile: add pinnded folder and first use option
This commit is contained in:
parent
c39c07bf31
commit
0a5a165aca
3 changed files with 110 additions and 12 deletions
|
|
@ -0,0 +1,6 @@
|
|||
[
|
||||
{
|
||||
"location": "/nix/store",
|
||||
"name": "Nix Store"
|
||||
}
|
||||
]
|
||||
|
|
@ -53,6 +53,13 @@
|
|||
];
|
||||
};
|
||||
};
|
||||
firstUseCheck = false;
|
||||
pinnedFolders = [
|
||||
{
|
||||
name = "Nix Store";
|
||||
location = "/nix/store";
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
nmt.script =
|
||||
|
|
@ -60,6 +67,10 @@
|
|||
configSubPath =
|
||||
if !pkgs.stdenv.isDarwin then ".config/superfile" else "Library/Application Support/superfile";
|
||||
configBasePath = "home-files/" + configSubPath;
|
||||
|
||||
dataSubPath =
|
||||
if !pkgs.stdenv.isDarwin then ".local/share/superfile" else "Library/Application Support/superfile";
|
||||
dataBasePath = "home-files/" + dataSubPath;
|
||||
in
|
||||
''
|
||||
assertFileExists "${configBasePath}/config.toml"
|
||||
|
|
@ -82,5 +93,10 @@
|
|||
assertFileContent \
|
||||
"${configBasePath}/theme/test2.toml" \
|
||||
${./example-theme2-expected.toml}
|
||||
assertFileExists "${dataBasePath}/firstUseCheck"
|
||||
assertFileExists "${dataBasePath}/pinned.json"
|
||||
assertFileContent \
|
||||
"${dataBasePath}/pinned.json" \
|
||||
${./example-pinned-folders.json}
|
||||
'';
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue