Seperate firefox profiles for trusted / work / general
This commit is contained in:
parent
d94fe01659
commit
cbb3278b8f
4 changed files with 264 additions and 48 deletions
30
modules/user/modules/firefox/theme.nix
Normal file
30
modules/user/modules/firefox/theme.nix
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
{ pkgs, name, theme }: let
|
||||
json = builtins.toJSON {
|
||||
manifest_version = 2;
|
||||
version = "1.0";
|
||||
browser_specific_settings.gecko = {
|
||||
id = "theme-${name}@outfoxxed.me";
|
||||
};
|
||||
|
||||
inherit name theme;
|
||||
};
|
||||
|
||||
jsonFile = pkgs.writeTextFile {
|
||||
name = "manifest.json";
|
||||
text = json;
|
||||
};
|
||||
in pkgs.stdenvNoCC.mkDerivation {
|
||||
pname = "firefox-theme-${name}.xpi";
|
||||
version = "1.0";
|
||||
preferLocalBuild = true;
|
||||
unpackPhase = "true";
|
||||
|
||||
buildPhase = ''
|
||||
cp ${jsonFile} manifest.json
|
||||
${pkgs.zip}/bin/zip out.xpi manifest.json
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
mv out.xpi $out
|
||||
'';
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue