-
Notifications
You must be signed in to change notification settings - Fork 0
/
firefox.nix
74 lines (66 loc) · 2.39 KB
/
firefox.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
{ config
, pkgs
, lib
, ...
}:
let
fxcast = pkgs.fx_cast_bridge.overrideAttrs (o: {
version = "0.3.1";
src = pkgs.fetchFromGitHub {
owner = "hensm";
repo = "fx_cast";
rev = "v0.3.1";
hash = "sha256-hB4NVJW2exHoKsMp0CKzHerYgj8aR77rV+ZsCoWA1Dg=";
};
});
darkreaderManifest = {
name = "darkreader";
description = "custom darkreader native host for syncing with pywal";
path = "${./files/darkreader}/index.js";
type = "stdio";
};
in
{
config.xdg.configFile."google-chrome/NativeMessagingHosts/darkreader.json".text = builtins.toJSON
(darkreaderManifest // { allowed_origins = [ "chrome-extension://gidgehhdgebooieidpcckaphjbfcghpe/" ]; });
config.home.file = {
".mozilla/native-messaging-hosts/darkreader.json".text = builtins.toJSON
(darkreaderManifest // { allowed_extensions = [ "[email protected]" ]; });
};
config.xdg.configFile."vimfx/config.js".source = ./files/vimfx.js;
config.xdg.configFile."vimfx/frame.js".text = "";
config.xdg.configFile."wal/templates/userContent.css".source = ./files/theme/firefox/userContent.css;
config.programs.firefox = {
enable = true;
profiles.default = {
id = 0;
settings = {
"toolkit.legacyUserProfileCustomizations.stylesheets" = true;
"dom.w3c_touch_events.enabled" = 1;
"widget.use-xdg-desktop-portal" = true;
"apz.gtk.kinetic_scroll.enabled" = false;
};
userChrome = ''
@import url('blurredfox/userChrome.css');
@import url('userContent.css');
@import url('layout.css');
'';
};
};
config.outOfStoreSymlinks.home = {
".mozilla/firefox/default/chrome/userContent.css" = "${config.xdg.cacheHome}/wal/userContent.css";
};
config.home.file = {
".mozilla/firefox/default/chrome/blurredfox".source = pkgs.fetchFromGitHub {
owner = "manilarome";
repo = "blurredfox";
rev = "6976b5460f47bd28b4dc53bd093012780e6bfed3";
sha256 = "0mj47pv27dv2bk4hsdjl3c81kw6bz9kk7gkdz30l4z88ckj31j0j";
};
".mozilla/firefox/default/chrome/layout.css".source = ./files/theme/firefox/twoline.css;
".mozilla/firefox/default/chrome/blur.css".source = pkgs.fetchurl {
url = "https://raw.githubusercontent.com/pavlukivan/dotfiles/6dfa74974cb25d9730a37bf4895a0f8421092b9e/firefox-transparency.css";
sha256 = "0k1h14hpzm25sh7jrrxrgafrhld742gy0ybf74fz1n7s8w0fd1kn";
};
};
}