diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..abe320a --- /dev/null +++ b/flake.lock @@ -0,0 +1,27 @@ +{ + "nodes": { + "nixpkgs": { + "locked": { + "lastModified": 1723991338, + "narHash": "sha256-Grh5PF0+gootJfOJFenTTxDTYPidA3V28dqJ/WV7iis=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "8a3354191c0d7144db9756a74755672387b702ba", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "nixpkgs": "nixpkgs" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix index a10d2e0..3e4852d 100644 --- a/flake.nix +++ b/flake.nix @@ -26,16 +26,20 @@ name = "zen-browser"; src = builtins.fetchTarball { - url = downloadUrl; - sha256 = "sha256:1z81dg3xgfpkyj501gflx8lw7d8124iqwm27zqfja2b47zf4ai2x"; - }; + url = downloadUrl; + sha256 = "sha256:1z81dg3xgfpkyj501gflx8lw7d8124iqwm27zqfja2b47zf4ai2x"; + }; + + desktopSrc = ./.; phases = [ "installPhase" "fixupPhase" ]; - nativeBuildInputs = [ pkgs.makeWrapper ] ; + nativeBuildInputs = [ pkgs.makeWrapper pkgs.copyDesktopItems ] ; installPhase = '' mkdir -p $out/bin && cp -r $src/* $out/bin + mkdir -p $out/share/applications + install -D $desktopSrc/zen.desktop $out/share/applications/dev.zen.Zen.desktop ''; fixupPhase = '' diff --git a/zen.desktop b/zen.desktop new file mode 100644 index 0000000..df5b81a --- /dev/null +++ b/zen.desktop @@ -0,0 +1,25 @@ +[Desktop Entry] +Name=Zen Browser +Exec=zen %u +Icon=zen +Type=Application +MimeType=text/html;text/xml;application/xhtml+xml;x-scheme-handler/http;x-scheme-handler/https;application/x-xpinstall;application/pdf;application/json; +StartupWMClass=zen-alpha +Categories=Network;WebBrowser; +StartupNotify=true +Terminal=false +X-MultipleArgs=false +Keywords=Internet;WWW;Browser;Web;Explorer; +Actions=new-window;new-private-window;profilemanager; + +[Desktop Action new-window] +Name=Open a New Window +Exec=zen %u + +[Desktop Action new-private-window] +Name=Open a New Private Window +Exec=zen --private-window %u + +[Desktop Action profilemanager] +Name=Open the Profile Manager +Exec=zen --ProfileManager %u