commit b350757c6af80bfdc270913cacf530e94aed437f
parent 926c46571914857dfcb612e913306d29de2ca0a6
Author: Vincent Demeester <vincent@sbr.pm>
Date: Thu, 1 Nov 2018 14:28:44 +0100
modules: add programs.vscode
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Diffstat:
6 files changed, 26 insertions(+), 10 deletions(-)
diff --git a/hokkaido.nix b/hokkaido.nix
@@ -6,13 +6,13 @@
# dev
./dev.python.nix
./dev.js.nix
- ./vscode.nix
# k8s
./containers.nix
./kubernetes.nix
];
profiles.laptop.enable = true;
profiles.dev.go.enable = true;
+ programs.vscode.enable = true;
home.packages = with pkgs; [
google-chrome
];
diff --git a/modules/module-list.nix b/modules/module-list.nix
@@ -13,6 +13,7 @@
./profiles/laptop.nix
./profiles/ssh.nix
./profiles/tmux.nix
+ ./programs/vscode.nix
./services/shairport-sync.nix
];
}
diff --git a/modules/programs/vscode.nix b/modules/programs/vscode.nix
@@ -0,0 +1,22 @@
+{ config, lib, pkgs, ... }:
+
+with lib;
+let
+ cfg = config.programs.vscode;
+in
+{
+ options = {
+ programs.vscode = {
+ enable = mkOption {
+ default = false;
+ description = "Enable VS Code profile";
+ type = types.bool;
+ };
+ };
+ };
+ config = mkIf cfg.enable {
+ home.packages = with pkgs; [
+ vscode-with-extensions
+ ];
+ };
+}
diff --git a/shikoku.nix b/shikoku.nix
@@ -11,10 +11,10 @@
./dev.java.nix
./dev.haskell.nix
./openshift.nix
- ./vscode.nix
];
profiles.desktop.enable = true;
profiles.dev.go.enable = true;
+ programs.vscode.enable = true;
xdg.configFile."fish/conf.d/docker.fish".text = ''
set -gx DOCKER_BUILDKIT 1
'';
diff --git a/vscode.nix b/vscode.nix
@@ -1,7 +0,0 @@
-{ pkgs, ... }:
-
-{
- home.packages = with pkgs; [
- vscode-with-extensions
- ];
-}
diff --git a/wakasu.nix b/wakasu.nix
@@ -10,10 +10,10 @@
./dev.java.nix
./dev.haskell.nix
./openshift.nix
- ./vscode.nix
];
profiles.laptop.enable = true;
profiles.dev.go.enable = true;
+ programs.vscode.enable = true;
xdg.configFile."fish/conf.d/docker.fish".text = ''
set -gx DOCKER_BUILDKIT 1
'';