2022-07-27 16:47:49 +01:00
|
|
|
{ config, pkgs, ... }:
|
|
|
|
let
|
2022-03-09 21:11:42 +00:00
|
|
|
configDir = "Code";
|
|
|
|
userDir = if pkgs.stdenv.hostPlatform.isDarwin then
|
2022-04-11 12:26:28 +01:00
|
|
|
"$HOME/Library/Application Support/${configDir}/User"
|
2022-03-09 21:11:42 +00:00
|
|
|
else
|
|
|
|
"${config.xdg.configHome}/${configDir}/User";
|
|
|
|
in {
|
2021-12-21 14:00:09 +00:00
|
|
|
programs.vscode = {
|
|
|
|
enable = true;
|
|
|
|
userSettings = {
|
2022-01-29 18:06:26 +00:00
|
|
|
"editor.tabSize" = 4;
|
2022-08-28 14:34:58 +01:00
|
|
|
"terminal.integrated.shellIntegration.enabled" = false;
|
|
|
|
"github.gitAuthentication" = false;
|
2021-12-21 15:26:21 +00:00
|
|
|
"editor.fontSize" = 24;
|
|
|
|
"editor.fontFamily" = "'Comic Code'";
|
|
|
|
"terminal.integrated.fontSize" = 24;
|
|
|
|
"editor.codeLensFontFamily" = "'Comic Code'";
|
|
|
|
"editor.inlayHints.fontFamily" = "'Comic Code'";
|
|
|
|
"markdown.preview.fontFamily" = "'Comic Code'";
|
|
|
|
"terminal.integrated.fontFamily" = "'Comic Code'";
|
|
|
|
"files.autoSave" = "afterDelay";
|
2021-12-21 14:00:09 +00:00
|
|
|
};
|
|
|
|
};
|
2022-08-28 14:34:58 +01:00
|
|
|
programs.vscode.extensions = with pkgs;
|
|
|
|
[ vscode-extensions.matklad.rust-analyzer ];
|
2022-08-19 10:51:01 +01:00
|
|
|
|
2022-03-09 21:05:56 +00:00
|
|
|
# make config changeable
|
2022-06-01 07:13:31 +01:00
|
|
|
#home = {
|
|
|
|
# activation = {
|
|
|
|
# afterWriteBoundary = {
|
|
|
|
# after = [ "writeBoundary" ];
|
|
|
|
# before = [ ];
|
|
|
|
# data = ''
|
|
|
|
# vscodeDir="${userDir}"
|
|
|
|
# $DRY_RUN_CMD cat "$vscodeDir/settings.json" > "$vscodeDir/settings_whatever.json"
|
|
|
|
# $DRY_RUN_CMD rm -f "$vscodeDir/settings.json"
|
|
|
|
# $DRY_RUN_CMD cp "$vscodeDir/settings_whatever.json" "$vscodeDir/settings.json"
|
|
|
|
# '';
|
|
|
|
# };
|
|
|
|
# };
|
|
|
|
#};
|
2021-12-21 15:26:21 +00:00
|
|
|
}
|