Add org-protocol desktop entry
This commit is contained in:
parent
1b305fa81c
commit
af00fac01c
|
@ -5,10 +5,7 @@
|
||||||
|
|
||||||
home.stateVersion = "21.11";
|
home.stateVersion = "21.11";
|
||||||
|
|
||||||
imports = [ ./shell ./wayland ./password.nix ./email.nix ];
|
imports = [ ./shell ./wayland ./xdg.nix ./password.nix ./email.nix ];
|
||||||
|
|
||||||
xdg.enable = true;
|
|
||||||
xdg.userDirs.enable = true;
|
|
||||||
|
|
||||||
programs.git = {
|
programs.git = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
24
home-manager/xdg.nix
Normal file
24
home-manager/xdg.nix
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
|
let
|
||||||
|
org-protocol = pkgs.writeTextDir
|
||||||
|
"/share/applications/org-protocol.desktop"
|
||||||
|
''
|
||||||
|
[Desktop Entry]
|
||||||
|
Name=Org-Protocol
|
||||||
|
Exec=emacsclient %u
|
||||||
|
Icon=emacs-icon
|
||||||
|
Type=Application
|
||||||
|
Terminal=false
|
||||||
|
MimeType=x-scheme-handler/org-protocol
|
||||||
|
'';
|
||||||
|
in {
|
||||||
|
xdg.enable = true;
|
||||||
|
xdg.userDirs.enable = true;
|
||||||
|
|
||||||
|
# Org Roam Protocol
|
||||||
|
home.packages = [ org-protocol ];
|
||||||
|
xdg.mimeApps = {
|
||||||
|
enable = true;
|
||||||
|
defaultApplications."x-scheme-handler/org-protocol" = [ "org-protocol.desktop" ];
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in a new issue