summaryrefslogtreecommitdiff
path: root/home/ebisu/meta/multimedia/browser/thorium.nix
diff options
context:
space:
mode:
authorFuwn <[email protected]>2024-08-28 20:36:04 -0700
committerFuwn <[email protected]>2024-08-28 20:36:04 -0700
commitf3c31e4ad7fab36e151f3a2e207fafb1eda1a787 (patch)
treee265a1a5270b4522049110b8bc5aa13fda142c2f /home/ebisu/meta/multimedia/browser/thorium.nix
parentmany (diff)
downloadnixos-config-f3c31e4ad7fab36e151f3a2e207fafb1eda1a787.tar.xz
nixos-config-f3c31e4ad7fab36e151f3a2e207fafb1eda1a787.zip
hi
Diffstat (limited to 'home/ebisu/meta/multimedia/browser/thorium.nix')
-rw-r--r--home/ebisu/meta/multimedia/browser/thorium.nix47
1 files changed, 47 insertions, 0 deletions
diff --git a/home/ebisu/meta/multimedia/browser/thorium.nix b/home/ebisu/meta/multimedia/browser/thorium.nix
new file mode 100644
index 0000000..e789275
--- /dev/null
+++ b/home/ebisu/meta/multimedia/browser/thorium.nix
@@ -0,0 +1,47 @@
+{ pkgs, lib, ... }:
+let
+ thorium-archive = pkgs.fetchurl {
+ url = "https://github.com/Alex313031/thorium/releases/download/M126.0.6478.246/Thorium_Browser_126.0.6478.246_Th24_SSE4.AppImage";
+ hash = "sha256-izYbx/mSA+l7fAh917SauHopk3UlUJo+7NjkyIGpnNA=";
+ };
+
+ version = "126.0.6478.246_Th24";
+
+ # https://discourse.nixos.org/t/creating-a-nix-derivation-for-an-appimage/31927
+ thorium = pkgs.appimageTools.wrapType2 {
+ pname = "thorium";
+ version = version;
+ src = "${thorium-archive}";
+
+ meta = with lib; {
+ description = "Chromium fork named after radioactive element No. 90. Windows and MacOS/Raspi/Android/Special builds are in different repositories, links are towards the top of the README.md.";
+ sourceProvenance = with sourceTypes; [ binaryNativeCode ];
+ homepage = "https://thorium.rocks/";
+ license = licenses.bsd3;
+ platforms = platforms.linux;
+ mainProgram = "thorium-browser";
+ };
+ };
+in
+{
+ home.packages = [ thorium ];
+
+ xdg.configFile."thorium-flags.conf".text = ''
+ --enable-features=UseOzonePlatform,WaylandWindowDecorations,WebRTCPipeWireCapturer,TouchpadOverscrollHistoryNavigation
+ --ozone-platform=wayland
+ --ignore-gpu-blocklist
+ --enable-gpu-rasterization
+ --enable-zero-copy
+ --disable-gpu-driver-bug-workarounds
+ --enable-features=VaapiVideoDecoder
+ --enable-native-gpu-memory-buffers
+ --disable-features=UseSkiaRenderer
+ --use-cmd-decoder=passthrough
+ --process-per-site
+ --force-dark-mode
+ --enable-features=WebUIDarkMode
+ --enable-unsafe-webgpu
+ --gtk-version=4
+ --enable-wayland-ime
+ '';
+}