summary refs log tree commit diff
path: root/pkgs/applications/editors
diff options
context:
space:
mode:
authorEdmund Wu <22758444+eadwu@users.noreply.github.com>2018-06-10 18:23:30 -0400
committerxeji <36407913+xeji@users.noreply.github.com>2018-06-11 00:23:30 +0200
commit4d8c0313b893fb079c1e29b850114b0ceca9df9d (patch)
tree0b441c661b2a3cfb0ae7cd5138fe7700359c6bcc /pkgs/applications/editors
parent559e26d7def59534902a1560e17f4d3ef1d2af6d (diff)
downloadnixlib-4d8c0313b893fb079c1e29b850114b0ceca9df9d.tar
nixlib-4d8c0313b893fb079c1e29b850114b0ceca9df9d.tar.gz
nixlib-4d8c0313b893fb079c1e29b850114b0ceca9df9d.tar.bz2
nixlib-4d8c0313b893fb079c1e29b850114b0ceca9df9d.tar.lz
nixlib-4d8c0313b893fb079c1e29b850114b0ceca9df9d.tar.xz
nixlib-4d8c0313b893fb079c1e29b850114b0ceca9df9d.tar.zst
nixlib-4d8c0313b893fb079c1e29b850114b0ceca9df9d.zip
nixos/vscode-with-extensions: add desktop file (#41803)
Diffstat (limited to 'pkgs/applications/editors')
-rw-r--r--pkgs/applications/editors/vscode/with-extensions.nix11
1 files changed, 8 insertions, 3 deletions
diff --git a/pkgs/applications/editors/vscode/with-extensions.nix b/pkgs/applications/editors/vscode/with-extensions.nix
index c54c8a4277f1..9b0d69ae65aa 100644
--- a/pkgs/applications/editors/vscode/with-extensions.nix
+++ b/pkgs/applications/editors/vscode/with-extensions.nix
@@ -12,7 +12,7 @@
         # When the extension is already available in the default extensions set.
         vscodeExtensions = with vscode-extensions; [
           bbenoist.Nix
-        ]   
+        ]
 
         # Concise version from the vscode market place when not available in the default set.
         ++ vscode-utils.extensionsFromVscodeMarketplace [
@@ -26,11 +26,11 @@
       }
       ~~~
 
-      This expression should fetch 
+      This expression should fetch
        -  the *nix* vscode extension from whatever source defined in the
           default nixpkgs extensions set `vscodeExtensions`.
 
-       -  the *code-runner* vscode extension from the marketplace using the 
+       -  the *code-runner* vscode extension from the marketplace using the
           following url:
 
           ~~~
@@ -72,6 +72,11 @@ runCommand "${wrappedPkgName}-with-extensions-${wrappedPkgVersion}" {
   meta = vscode.meta;
 } ''
   mkdir -p "$out/bin"
+  mkdir -p "$out/share/applications"
+  mkdir -p "$out/share/pixmaps"
+
+  ln -sT "${vscode}/share/applications/code.desktop" "$out/share/applications/code.desktop"
+  ln -sT "${vscode}/share/pixmaps/code.png" "$out/share/pixmaps/code.png"
   ${if [] == vscodeExtensions
     then ''
       ln -sT "${vscode}/bin/${wrappedExeName}" "$out/bin/${exeName}"