generated from nhcarrigan/template
feat: back to vscode
All checks were successful
Node.js CI / Lint and Test (push) Successful in 2m6s
All checks were successful
Node.js CI / Lint and Test (push) Successful in 2m6s
This commit is contained in:
parent
2d58bd6d6b
commit
144685e92c
@ -3386,270 +3386,190 @@ This file goes in `~/.config/wofi/style.css`.
|
|||||||
|
|
||||||
## 4. Code Editor
|
## 4. Code Editor
|
||||||
|
|
||||||
Naomi uses Emacs as her current code editor.
|
Naomi uses VSCodium as her current code editor.
|
||||||
|
|
||||||
### 4.1. Settings
|
### 4.1. Settings
|
||||||
|
|
||||||
This is Naomi's configuration. It goes in `~/.config/emacs/init.el`.
|
This is Naomi's configuration. It goes in `~/.config/VSCodium/User/settings.json`.
|
||||||
|
|
||||||
```lisp
|
```json
|
||||||
;; Initialize package system
|
{
|
||||||
(require 'package)
|
"workbench.iconTheme": "vscode-icons",
|
||||||
(setq package-archives '(("melpa" . "https://melpa.org/packages/")
|
"[typescript]": {
|
||||||
("org" . "https://orgmode.org/elpa/")
|
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||||
("elpa" . "https://elpa.gnu.org/packages/")))
|
},
|
||||||
(package-initialize)
|
"[json]": {
|
||||||
|
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||||
;; Bootstrap use-package
|
},
|
||||||
(unless (package-installed-p 'use-package)
|
"[jsonc]": {
|
||||||
(package-install 'use-package))
|
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||||
(require 'use-package)
|
},
|
||||||
(setq use-package-always-ensure t)
|
"[typescriptreact]": {
|
||||||
|
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||||
;; Terminal-specific settings
|
},
|
||||||
(xterm-mouse-mode 1) ; Enable mouse support
|
"javascript.preferences.importModuleSpecifierEnding": "js",
|
||||||
(global-set-key (kbd "<mouse-4>") 'scroll-down-line)
|
"javascript.updateImportsOnFileMove.enabled": "always",
|
||||||
(global-set-key (kbd "<mouse-5>") 'scroll-up-line)
|
"typescript.preferences.importModuleSpecifierEnding": "js",
|
||||||
(menu-bar-mode -1) ; Disable menu bar in terminal
|
"typescript.preferences.preferTypeOnlyAutoImports": true,
|
||||||
|
"[javascript]": {
|
||||||
;; Better terminal colors
|
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||||
(use-package eterm-256color
|
},
|
||||||
:hook (term-mode . eterm-256color-mode))
|
"typescript.updateImportsOnFileMove.enabled": "always",
|
||||||
|
"[html]": {
|
||||||
;; Line numbers configuration
|
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||||
(global-display-line-numbers-mode 1) ; Enable line numbers globally
|
},
|
||||||
(setq display-line-numbers-type t)
|
"editor.fontFamily": "'OpenDyslexicM Nerd Font'",
|
||||||
|
"files.exclude": {
|
||||||
;; Make line numbers stand out a bit
|
"**/node_modules/": true
|
||||||
(set-face-background 'line-number-current-line nil)
|
},
|
||||||
(set-face-foreground 'line-number-current-line "yellow")
|
"editor.fontLigatures": true,
|
||||||
|
"editor.codeLensFontFamily": "'OpenDyslexicM Nerd Font'",
|
||||||
;; Optional: Customize line number format
|
"editor.inlineSuggest.fontFamily": "'OpenDyslexicM Nerd Font'",
|
||||||
(setq display-line-numbers-width 4) ; Reserve space for line numbers
|
"editor.inlayHints.fontFamily": "'OpenDyslexicM Nerd Font'",
|
||||||
(setq display-line-numbers-widen t) ; Expand line number space as needed
|
"terminal.integrated.fontFamily": "'OpenDyslexicM Nerd Font'",
|
||||||
|
"notebook.output.fontFamily": "'OpenDyslexicM Nerd Font'",
|
||||||
;; Disable line numbers for some modes where they don't make sense
|
"chat.editor.fontFamily": "'OpenDyslexicM Nerd Font'",
|
||||||
(dolist (mode '(term-mode-hook
|
"markdown.preview.fontFamily": "'OpenDyslexicM Nerd Font'",
|
||||||
shell-mode-hook
|
"colorize.languages": [
|
||||||
treemacs-mode-hook
|
"html",
|
||||||
eshell-mode-hook))
|
"javascript",
|
||||||
(add-hook mode (lambda () (display-line-numbers-mode 0))))
|
"typescript",
|
||||||
|
"json",
|
||||||
;; Project management
|
"typescriptreact",
|
||||||
(use-package projectile
|
"css",
|
||||||
:config
|
"sass",
|
||||||
(projectile-mode +1)
|
"scss",
|
||||||
:bind-keymap ("C-c p" . projectile-command-map))
|
"less",
|
||||||
|
"postcss",
|
||||||
;; File tree with treemacs
|
"sss",
|
||||||
(use-package treemacs
|
"stylus",
|
||||||
:bind
|
"xml",
|
||||||
(:map global-map
|
"svg"
|
||||||
("C-c t" . treemacs))
|
],
|
||||||
:config
|
"cSpell.language": "en-GB",
|
||||||
(treemacs-follow-mode t)
|
"http.proxyAuthorization": null,
|
||||||
(treemacs-project-follow-mode t))
|
"github.copilot.enable": {
|
||||||
|
"*": true,
|
||||||
(use-package treemacs-projectile
|
},
|
||||||
:after (treemacs projectile))
|
"discord.detailsIdling": "She's not editing a file...",
|
||||||
|
"discord.detailsEditing": "{file_name}:L{current_line}:{current_column}",
|
||||||
;; LSP Mode base configuration
|
"discord.lowerDetailsEditing": "{workspace}/{git_branch}",
|
||||||
(use-package lsp-mode
|
"discord.largeImageIdling": "Nothing to see here...",
|
||||||
:init
|
"discord.lowerDetailsIdling": "Off in lala land...",
|
||||||
(setq lsp-keymap-prefix "C-c l"
|
"editor.inlayHints.enabled": "off",
|
||||||
lsp-enable-symbol-highlighting t
|
"workbench.colorCustomizations": {
|
||||||
lsp-enable-snippet t
|
"editor.lineHighlightBackground": "#1073cf2d",
|
||||||
lsp-enable-indentation t)
|
"editor.lineHighlightBorder": "#9fced11f"
|
||||||
:hook
|
},
|
||||||
((typescript-mode . lsp)
|
"editor.wordWrap": "off",
|
||||||
(js2-mode . lsp)
|
"diffEditor.wordWrap": "off",
|
||||||
(web-mode . lsp)
|
"editor.guides.indentation": false,
|
||||||
(python-mode . lsp)
|
"editor.guides.bracketPairs": false,
|
||||||
(java-mode . lsp)
|
"sonarlint.connectedMode.connections.sonarcloud": [
|
||||||
(c++-mode . lsp)
|
{
|
||||||
(c-mode . lsp)
|
"organizationKey": "nhcarrigan",
|
||||||
(csharp-mode . lsp))
|
"connectionId": "nhcarrigan"
|
||||||
:commands lsp)
|
}
|
||||||
|
],
|
||||||
;; LSP UI enhancements
|
"workbench.colorTheme": "Ocean Breeze",
|
||||||
(use-package lsp-ui
|
"terminal.integrated.lineHeight": 1,
|
||||||
:commands lsp-ui-mode
|
"[css]": {
|
||||||
:config
|
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||||
(setq lsp-ui-doc-enable t
|
},
|
||||||
lsp-ui-doc-position 'at-point))
|
"debug.console.fontFamily": "'OpenDyslexicM Nerd Font'",
|
||||||
|
"scm.inputFontFamily": "'OpenDyslexicM Nerd Font'",
|
||||||
(use-package typescript-mode
|
"errorLens.fontFamily": "'OpenDyslexicM Nerd Font'",
|
||||||
:mode ("\\.ts\\'")
|
"gitlens.currentLine.fontFamily": "'OpenDyslexicM Nerd Font'",
|
||||||
:hook (typescript-mode . (lambda () (setq typescript-indent-level 2))))
|
"gitlens.blame.fontFamily": "'OpenDyslexicM Nerd Font'",
|
||||||
(use-package web-mode
|
"sonarlint.disableTelemetry": true,
|
||||||
:mode (("\\.tsx\\'" . web-mode)
|
"explorer.confirmDelete": false,
|
||||||
("\\.jsx\\'" . web-mode))
|
"wordcounter.include_eol_chars": false,
|
||||||
:config
|
"wordcounter.side.left": [
|
||||||
(setq web-mode-markup-indent-offset 2
|
"word",
|
||||||
web-mode-css-indent-offset 2
|
"char"
|
||||||
web-mode-code-indent-offset 2)
|
]
|
||||||
web-mode-json-indent-offset 2)
|
}
|
||||||
|
|
||||||
;; JavaScript better syntax highlighting
|
|
||||||
(use-package js2-mode
|
|
||||||
:mode "\\.js\\'")
|
|
||||||
(setq js-indent-level 2)
|
|
||||||
|
|
||||||
(use-package csharp-mode
|
|
||||||
:config
|
|
||||||
(add-to-list 'auto-mode-alist '("\\.cs\\'" . csharp-mode)))
|
|
||||||
|
|
||||||
(use-package ccls
|
|
||||||
:hook ((c-mode c++-mode) . (lambda () (require 'ccls) (lsp))))
|
|
||||||
|
|
||||||
(use-package lsp-java
|
|
||||||
:config (add-hook 'java-mode-hook 'lsp))
|
|
||||||
|
|
||||||
(use-package kotlin-mode)
|
|
||||||
|
|
||||||
(use-package python-mode
|
|
||||||
:hook (python-mode . (lambda ()
|
|
||||||
(require 'lsp-pyright)
|
|
||||||
(lsp))))
|
|
||||||
(use-package lsp-pyright
|
|
||||||
:ensure t)
|
|
||||||
|
|
||||||
(use-package markdown-mode
|
|
||||||
:mode (("README\\.md\\'" . gfm-mode)
|
|
||||||
("\\.md\\'" . markdown-mode)
|
|
||||||
("\\.mdx\\'" . markdown-mode))
|
|
||||||
:init (setq markdown-command "multimarkdown"))
|
|
||||||
|
|
||||||
(use-package git-gutter
|
|
||||||
:config
|
|
||||||
(global-git-gutter-mode +1))
|
|
||||||
|
|
||||||
(use-package hl-todo
|
|
||||||
:config
|
|
||||||
(setq hl-todo-keyword-faces
|
|
||||||
'(("TODO" . "#FF0000")
|
|
||||||
("FIXME" . "#FF0000")
|
|
||||||
("DEBUG" . "#A020F0")
|
|
||||||
("GOTCHA" . "#FF4500")
|
|
||||||
("STUB" . "#1E90FF")))
|
|
||||||
(global-hl-todo-mode))
|
|
||||||
|
|
||||||
(use-package elcord)
|
|
||||||
(elcord-mode)
|
|
||||||
|
|
||||||
;; Redirect backup files
|
|
||||||
(setq backup-directory-alist `(("." . "~/.config/emacs/backups")))
|
|
||||||
|
|
||||||
;; Redirect auto-save files
|
|
||||||
(setq auto-save-file-name-transforms `((".*" "~/.config/emacs/auto-saves/" t)))
|
|
||||||
|
|
||||||
(custom-set-variables
|
|
||||||
;; custom-set-variables was added by Custom.
|
|
||||||
;; If you edit it by hand, you could mess it up, so be careful.
|
|
||||||
;; Your init file should contain only one such instance.
|
|
||||||
;; If there is more than one, they won't work right.
|
|
||||||
'(package-selected-packages
|
|
||||||
'(hl-todo format-all flycheck git-gutter lsp-pyright python-mode kotlin-mode lsp-java ccls js2-mode web-mode typescript-mode company lsp-ui lsp-mode treemacs-projectile treemacs projectile eterm-256color)))
|
|
||||||
(custom-set-faces
|
|
||||||
;; custom-set-faces was added by Custom.
|
|
||||||
;; If you edit it by hand, you could mess it up, so be careful.
|
|
||||||
;; Your init file should contain only one such instance.
|
|
||||||
;; If there is more than one, they won't work right.
|
|
||||||
)
|
|
||||||
|
|
||||||
(setq-default indent-tabs-mode nil)
|
|
||||||
(setq-default tab-width 2)
|
|
||||||
(setq indent-line-function 'insert-tab)
|
|
||||||
|
|
||||||
(add-to-list 'custom-theme-load-path "/home/naomi/.config/emacs/themes/")
|
|
||||||
(load-theme 'ocean-breeze t)
|
|
||||||
```
|
```
|
||||||
|
|
||||||
### 4.2. Theme
|
### 4.2. Extensions
|
||||||
|
|
||||||
This is Naomi's custom emacs theme. It goes in `~/.config/emacs/themes/ocean-breeze-theme.el`.
|
Naomi uses the following extensions. This list is generated with `codium --list-extensions`.
|
||||||
|
|
||||||
```lisp
|
```txt
|
||||||
(deftheme ocean-breeze
|
1password.op-vscode
|
||||||
"Naomi's custom emacs theme.")
|
aaron-bond.better-comments
|
||||||
|
addy2142.avalonia-templates
|
||||||
;; Set frame transparency
|
adpyke.codesnap
|
||||||
(set-frame-parameter nil 'alpha-background 0)
|
ahmadalli.vscode-nginx-conf
|
||||||
(add-to-list 'default-frame-alist '(alpha-background . 0))
|
astro-build.astro-vscode
|
||||||
|
avaloniateam.vscode-avalonia
|
||||||
(let ((class '((class color) (min-colors 89)))
|
bmewburn.vscode-intelephense-client
|
||||||
;; Core colors
|
bungcip.better-toml
|
||||||
(bg "unspecified-bg")
|
chrmarti.regex
|
||||||
(bg-dark "#022b23")
|
dabbinavo.xamlstyler
|
||||||
(bg-darker "#044a3c")
|
dart-code.dart-code
|
||||||
(fg "#abfcec")
|
dart-code.flutter
|
||||||
(fg-light "#e2fcf8")
|
dbaeumer.vscode-eslint
|
||||||
(selection-bg "#1a7765")
|
donjayamanne.githistory
|
||||||
(selection-fg "#d2fcf4")
|
eamodio.gitlens
|
||||||
(cursor "#abfcec")
|
esbenp.prettier-vscode
|
||||||
|
firefox-devtools.vscode-firefox-debug
|
||||||
;; ANSI color palette
|
fwcd.kotlin
|
||||||
(black "#022b23")
|
github.copilot
|
||||||
(red "#ff6b6b")
|
github.copilot-chat
|
||||||
(green "#4ddbba")
|
golang.go
|
||||||
(yellow "#ffd93d")
|
haskell.haskell
|
||||||
(blue "#6bc5ff")
|
icrawl.discord-vscode
|
||||||
(magenta "#ff92df")
|
ionide.ionide-fsharp
|
||||||
(cyan "#89ffea")
|
justusadam.language-haskell
|
||||||
(white "#c4fcf2")
|
jzmstrjp.color-the-tag-name
|
||||||
|
kirozen.wordcounter
|
||||||
;; Bright ANSI colors
|
leodevbro.blockman
|
||||||
(bright-black "#044a3c")
|
mkxml.vscode-filesize
|
||||||
(bright-red "#ff8585")
|
mrmlnc.vscode-scss
|
||||||
(bright-green "#6bedcc")
|
ms-dotnettools.csdevkit
|
||||||
(bright-yellow "#ffe074")
|
ms-dotnettools.csharp
|
||||||
(bright-blue "#92d5ff")
|
ms-dotnettools.dotnet-interactive-vscode
|
||||||
(bright-magenta "#ffb2e7")
|
ms-dotnettools.vscode-dotnet-pack
|
||||||
(bright-cyan "#a9fff0")
|
ms-dotnettools.vscode-dotnet-runtime
|
||||||
(bright-white "#e2fcf8"))
|
ms-dotnettools.vscodeintellicode-csharp
|
||||||
|
ms-toolsai.jupyter
|
||||||
(custom-theme-set-faces
|
ms-toolsai.jupyter-keymap
|
||||||
'ocean-breeze
|
ms-toolsai.jupyter-renderers
|
||||||
|
ms-toolsai.vscode-jupyter-cell-tags
|
||||||
;; Basic faces
|
ms-toolsai.vscode-jupyter-slideshow
|
||||||
`(default ((,class (:foreground ,fg :background ,bg))))
|
ms-vscode.cmake-tools
|
||||||
`(cursor ((,class (:background ,cursor))))
|
ms-vscode.cpptools
|
||||||
`(region ((,class (:background ,selection-bg :foreground ,selection-fg))))
|
ms-vscode.cpptools-extension-pack
|
||||||
`(highlight ((,class (:background ,selection-bg))))
|
ms-vscode.cpptools-themes
|
||||||
`(hl-line ((,class (:background ,bg-dark))))
|
nhcarrigan.ocean-breeze
|
||||||
`(fringe ((,class (:background ,bg))))
|
oderwat.indent-rainbow
|
||||||
`(vertical-border ((,class (:foreground ,bg-darker))))
|
oracle.oracle-java
|
||||||
|
prisma.prisma
|
||||||
;; Font-lock faces
|
rebornix.ruby
|
||||||
`(font-lock-builtin-face ((,class (:foreground ,magenta))))
|
redhat.java
|
||||||
`(font-lock-comment-face ((,class (:foreground ,bright-black))))
|
rust-lang.rust-analyzer
|
||||||
`(font-lock-constant-face ((,class (:foreground ,cyan))))
|
sonarsource.sonarlint-vscode
|
||||||
`(font-lock-doc-face ((,class (:foreground ,green))))
|
streetsidesoftware.code-spell-checker
|
||||||
`(font-lock-function-name-face ((,class (:foreground ,blue))))
|
twxs.cmake
|
||||||
`(font-lock-keyword-face ((,class (:foreground ,magenta))))
|
usernamehw.errorlens
|
||||||
`(font-lock-string-face ((,class (:foreground ,green))))
|
visualstudioexptteam.intellicode-api-usage-examples
|
||||||
`(font-lock-type-face ((,class (:foreground ,yellow))))
|
visualstudioexptteam.vscodeintellicode
|
||||||
`(font-lock-variable-name-face ((,class (:foreground ,white))))
|
vitest.explorer
|
||||||
`(font-lock-warning-face ((,class (:foreground ,red))))
|
vscjava.vscode-gradle
|
||||||
|
vscjava.vscode-java-debug
|
||||||
;; Mode line
|
vscjava.vscode-java-dependency
|
||||||
`(mode-line ((,class (:background ,bg-darker :foreground ,fg))))
|
vscjava.vscode-java-pack
|
||||||
`(mode-line-inactive ((,class (:background ,bg-dark :foreground ,bright-black))))
|
vscjava.vscode-java-test
|
||||||
|
vscjava.vscode-maven
|
||||||
;; Search
|
vscode-icons-team.vscode-icons
|
||||||
`(isearch ((,class (:background ,yellow :foreground ,bg))))
|
william-voyek.vscode-nginx
|
||||||
`(lazy-highlight ((,class (:background ,bright-yellow :foreground ,bg))))
|
wingrunr21.vscode-ruby
|
||||||
|
wix.vscode-import-cost
|
||||||
;; Others
|
xdebug.php-debug
|
||||||
`(minibuffer-prompt ((,class (:foreground ,blue))))
|
yandeu.five-server
|
||||||
`(link ((,class (:foreground ,bright-blue :underline t))))
|
yoavbls.pretty-ts-errors
|
||||||
`(show-paren-match ((,class (:background ,selection-bg :foreground ,bright-cyan))))
|
yutengjing.vscode-colorize-plus
|
||||||
`(show-paren-mismatch ((,class (:background ,red :foreground ,white))))))
|
yzane.markdown-pdf
|
||||||
|
ziglang.vscode-zig
|
||||||
;;;###autoload
|
```
|
||||||
(when load-file-name
|
|
||||||
(add-to-list 'custom-theme-load-path
|
|
||||||
(file-name-as-directory (file-name-directory load-file-name))))
|
|
||||||
|
|
||||||
(provide-theme 'ocean-breeze)
|
|
||||||
```
|
|
Loading…
x
Reference in New Issue
Block a user