diff --git a/bootstrap/components/mocha-port.bash b/bootstrap/components/mocha-port.bash index 9b89a03..ceabe73 100644 --- a/bootstrap/components/mocha-port.bash +++ b/bootstrap/components/mocha-port.bash @@ -2,7 +2,6 @@ # Adds better error handling and safety features # shellcheck disable=SC2016 -# TODO: UNTESTED set -e # Exit immediately if a command exits with a non-zero status set -u # Treat unset variables as an error diff --git a/platforms/mac/karabiner/karabiner.json b/platforms/mac/karabiner/karabiner.json index 7651575..3e05f38 100644 --- a/platforms/mac/karabiner/karabiner.json +++ b/platforms/mac/karabiner/karabiner.json @@ -1098,9 +1098,32 @@ } ], "treat_as_built_in_keyboard": true + }, + { + "identifiers": { + "is_keyboard": true, + "is_pointing_device": true, + "product_id": 12870, + "vendor_id": 6645 + }, + "ignore": false, + "simple_modifications": [ + { + "from": { "key_code": "backslash" }, + "to": [{ "key_code": "delete_or_backspace" }] + }, + { + "from": { "key_code": "delete_or_backspace" }, + "to": [{ "key_code": "backslash" }] + } + ] } ], "name": "Colemak", + "virtual_hid_keyboard": { "keyboard_type_v2": "ansi" } + }, + { + "name": "New profile", "selected": true, "virtual_hid_keyboard": { "keyboard_type_v2": "ansi" } } diff --git a/tools/emacs.d/lisp/init-appearance.el b/tools/emacs.d/lisp/init-appearance.el index 88adcc4..85a620e 100644 --- a/tools/emacs.d/lisp/init-appearance.el +++ b/tools/emacs.d/lisp/init-appearance.el @@ -103,7 +103,7 @@ :init (setq highlight-indent-guides-method 'column) (setq highlight-indent-guides-responsive 'top) - (setq highlight-indent-guides-auto-character-face-perc 5)) + (setq highlight-indent-guides-auto-character-face-perc 1)) diff --git a/tools/emacs.d/lisp/init-counsel.el b/tools/emacs.d/lisp/init-counsel.el index 2875f81..cf0fe3e 100644 --- a/tools/emacs.d/lisp/init-counsel.el +++ b/tools/emacs.d/lisp/init-counsel.el @@ -20,6 +20,12 @@ "fc" #'js0ny/open-config-directory "fh" #'counsel-recentf)) +;; Replace `cd' with `counsel-cd' +(defun cd () + "Change currend default directory" + (interactive) + (counsel-cd)) + (provide 'init-counsel) ;;; init-counsel.el ends diff --git a/tools/emacs.d/lisp/init-edit.el b/tools/emacs.d/lisp/init-edit.el index cf43a12..58e8808 100644 --- a/tools/emacs.d/lisp/init-edit.el +++ b/tools/emacs.d/lisp/init-edit.el @@ -13,7 +13,7 @@ (use-package company :ensure t :hook (after-init . global-company-mode) ; 在启动后自动启用 global-company-mode - :bind (:map company-active-map ; TODO: Seems does not work + :bind (:map company-active-map ("C-n" . company-select-next) ("C-p" . company-select-previous)) :custom diff --git a/tools/fish/conf.d/colorscheme.fish b/tools/fish/conf.d/colorscheme.fish index 8598659..8c1467f 100644 --- a/tools/fish/conf.d/colorscheme.fish +++ b/tools/fish/conf.d/colorscheme.fish @@ -7,8 +7,12 @@ case "Linux" fish_config theme choose "Catppuccin Latte" end case "Darwin" - set SYSTEM_COLOR_SCHEME defaults read -g AppleInterfaceStyle - echo "[TODO] Check if dark mode is enabled in macOS" + set SYSTEM_COLOR_SCHEME (defaults read -g AppleInterfaceStyle) + if test $SYSTEM_COLOR_SCHEME = "Dark" + fish_config theme choose "Catppuccin Mocha" + else + fish_config theme choose "Catppuccin Latte" + end case '*' fish_config theme choose "Catppuccin Mocha" end diff --git a/tools/nvim/lua/plugins/completion.lua b/tools/nvim/lua/plugins/completion.lua index af9e473..84bcd22 100644 --- a/tools/nvim/lua/plugins/completion.lua +++ b/tools/nvim/lua/plugins/completion.lua @@ -18,7 +18,7 @@ return { dependencies = { "L3MON4D3/LuaSnip", "lervag/vimtex" }, ft = { "tex", "latex", "markdown", "org" }, opts = {}, - dev = true, - dir = "~/Source/Forks/luasnip-latex-snippets.nvim/" + -- dev = true, + -- dir = "~/Source/Forks/luasnip-latex-snippets.nvim/" } } diff --git a/tools/wezterm/wezterm.lua b/tools/wezterm/wezterm.lua index 545eb3e..0c5331a 100644 --- a/tools/wezterm/wezterm.lua +++ b/tools/wezterm/wezterm.lua @@ -8,11 +8,6 @@ local color = require("color") local config = wezterm.config_builder() --- TODO: OS light/dark theme detection --- local function detect_theme() end - --- config.font = 'FiraCode Nerd Font' - require("tab")(config) require("appearance")(config) require("keymaps")(config)