VSCode Extensions merged from all 3 sources.
This commit is contained in:
parent
dc484e3161
commit
b31a3c940e
1 changed files with 46 additions and 34 deletions
|
@ -2,37 +2,33 @@
|
|||
with lib;
|
||||
let
|
||||
cfg = config.mySystem.editor.vscode;
|
||||
in
|
||||
{
|
||||
options.mySystem.editor.vscode.enable = mkEnableOption "vscode";
|
||||
config = mkIf cfg.enable {
|
||||
|
||||
# Enable vscode & addons
|
||||
environment.systemPackages = with pkgs; [
|
||||
(vscode-with-extensions.override {
|
||||
vscode = unstable.vscode;
|
||||
|
||||
vscodeExtensions =
|
||||
[
|
||||
vscode-extensions.dracula-theme.theme-dracula
|
||||
vscode-extensions.yzhang.markdown-all-in-one
|
||||
vscode-extensions.signageos.signageos-vscode-sops
|
||||
vscode-extensions.redhat.ansible
|
||||
vscode-extensions.ms-azuretools.vscode-docker
|
||||
vscode-extensions.mikestead.dotenv
|
||||
vscode-extensions.tamasfe.even-better-toml
|
||||
vscode-extensions.pkief.material-icon-theme
|
||||
vscode-extensions.jnoortheen.nix-ide
|
||||
vscode-extensions.ms-vscode-remote.remote-ssh
|
||||
vscode-extensions.ms-vscode-remote.remote-ssh-edit
|
||||
vscode-extensions.redhat.vscode-yaml
|
||||
# vscode-marketplace.continue.continue
|
||||
# vscode-marketplace.github.copilot
|
||||
# vscode-marketplace.github.copilot-chat
|
||||
vscode-extensions.continue.continue
|
||||
vscode-extensions.ms-python.python
|
||||
vscode-extensions.ms-python.vscode-pylance
|
||||
] ++ pkgs.vscode-utils.extensionsFromVscodeMarketplace [
|
||||
# VSCode Community Extensions. These are updated daily.
|
||||
vscodeCommunityExtensions = [
|
||||
"dracula-theme.theme-dracula"
|
||||
"esbenp.prettier-vscode"
|
||||
"jnoortheen.nix-ide"
|
||||
"mikestead.dotenv"
|
||||
"ms-azuretools.vscode-docker"
|
||||
# Python extensions *required* for redhat.ansible/vscode-yaml
|
||||
"ms-python.python"
|
||||
"ms-python.vscode-pylance"
|
||||
"ms-vscode-remote.remote-ssh"
|
||||
"ms-vscode-remote.remote-ssh-edit"
|
||||
"pkief.material-icon-theme"
|
||||
"redhat.ansible"
|
||||
"redhat.vscode-yaml"
|
||||
"signageos.signageos-vscode-sops"
|
||||
"tamasfe.even-better-toml"
|
||||
"tyriar.sort-lines"
|
||||
"yzhang.markdown-all-in-one"
|
||||
];
|
||||
# Nixpkgs Extensions. These are updated whenver they get around to it.
|
||||
vscodeNixpkgsExtensions = [
|
||||
# Continue ships with a binary that requires the patchelf fix which is done by default in nixpkgs.
|
||||
"continue.continue"
|
||||
];
|
||||
# Straight from the VSCode marketplace.
|
||||
marketplaceExtensions = [
|
||||
{
|
||||
name = "copilot";
|
||||
publisher = "github";
|
||||
|
@ -43,9 +39,25 @@ in
|
|||
name = "copilot-chat";
|
||||
publisher = "github";
|
||||
version = "0.17.1";
|
||||
sha256 = "sha256-Aa4gmHJCveP18v6CAvmkxmqf1JV1LygyQFNpzDz64Gw=";
|
||||
sha256 = "Aa4gmHJCveP18v6CAvmkxmqf1JV1LygyQFNpzDz64Gw=";
|
||||
}
|
||||
];
|
||||
# Extract extension strings and coerce them to a list of valid attribute paths.
|
||||
vscodeCommunityExtensionsPackages = map (ext: getAttrFromPath (splitString "." ext) pkgs.vscode-marketplace) vscodeCommunityExtensions;
|
||||
nixpkgsExtensionsPackages = map (ext: getAttrFromPath (splitString "." ext) pkgs.vscode-extensions) vscodeNixpkgsExtensions;
|
||||
marketplaceExtensionsPackages = pkgs.vscode-utils.extensionsFromVscodeMarketplace marketplaceExtensions;
|
||||
in
|
||||
{
|
||||
options.mySystem.editor.vscode.enable = mkEnableOption "vscode";
|
||||
config = mkIf cfg.enable {
|
||||
|
||||
# Enable vscode & addons
|
||||
environment.systemPackages = with pkgs; [
|
||||
(vscode-with-extensions.override {
|
||||
vscode = unstable.vscode;
|
||||
# Merge all the extension packages together.
|
||||
vscodeExtensions =
|
||||
vscodeCommunityExtensionsPackages ++ nixpkgsExtensionsPackages ++ marketplaceExtensionsPackages;
|
||||
})
|
||||
];
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue