diff --git a/.install/symlinks.sh b/.install/symlinks.sh index 0c1a367..0f40069 100644 --- a/.install/symlinks.sh +++ b/.install/symlinks.sh @@ -73,6 +73,7 @@ CONFIG_LINKED_FILES_HOME=( ".config/zsh" ".config/kitty" ".local/bin" + ".local/share/applications" ".local/share/gnupg/gpg.conf" ".local/share/gnupg/dirmngr.conf" ) @@ -96,4 +97,7 @@ for file in "${!CONFIG_LINKED_FILES[@]}"; do rm -rf "${file}" |& output::debug ln -fs "${CONFIG_LINKED_FILES[${file}]}" "${file}" |& output::debug done + +update-desktop-database ~/.local/share/applications + output::success "Successfully created symlinks" diff --git a/system/.local/bin/code b/system/.local/bin/code new file mode 100755 index 0000000..19a7f4d --- /dev/null +++ b/system/.local/bin/code @@ -0,0 +1,14 @@ +#!/usr/bin/env bash +# +# SCRIPT NAME: +# code +# +# AUTHOR: +# Severin Kaderli +# +# DESCRIPTION: +# Wrapper script for code to use XDG directories +# +# USAGE: +# ./code +"/usr/bin/code" --extensions-dir "${XDG_DATA_HOME}/vscode/extensions" "${@}" diff --git a/system/.local/share/applications/code-oss.desktop b/system/.local/share/applications/code-oss.desktop new file mode 100644 index 0000000..3947c73 --- /dev/null +++ b/system/.local/share/applications/code-oss.desktop @@ -0,0 +1,18 @@ +[Desktop Entry] +Name=Code - OSS +Comment=Code Editing. Redefined. +GenericName=Text Editor +Exec=code --unity-launch %F +Icon=com.visualstudio.code.oss +Type=Application +StartupNotify=false +StartupWMClass=Code +Categories=TextEditor;Development;IDE; +MimeType=text/plain;application/x-code-oss-workspace; +Actions=new-empty-window; +Keywords=vscode; + +[Desktop Action new-empty-window] +Name=New Empty Window +Exec=/usr/bin/code-oss --new-window %F +Icon=com.visualstudio.code.oss diff --git a/system/.local/share/applications/mimeinfo.cache b/system/.local/share/applications/mimeinfo.cache new file mode 100644 index 0000000..87e85ac --- /dev/null +++ b/system/.local/share/applications/mimeinfo.cache @@ -0,0 +1,3 @@ +[MIME Cache] +application/x-code-oss-workspace=code-oss.desktop; +text/plain=code-oss.desktop;