diff --git a/.config/nvim/lua/plugins/cmpconf.lua b/.config/nvim/lua/plugins/cmpconf.lua index 183c406..f98f018 100644 --- a/.config/nvim/lua/plugins/cmpconf.lua +++ b/.config/nvim/lua/plugins/cmpconf.lua @@ -249,7 +249,7 @@ M.config = function() check_ts = true, -- treesitter integration enable_check_bracket_line = false, disable_in_macro = true, - disable_filetype = { 'TelescopePrompt', 'guihua', 'guihua_rust', 'clap_input' }, + disable_filetype = { 'fzf', 'guihua', 'guihua_rust', 'clap_input' }, } -- If you want insert `(` after select function or method item local cmp_autopairs = require 'nvim-autopairs.completion.cmp' diff --git a/.config/nvim/lua/plugins/functionality.lua b/.config/nvim/lua/plugins/functionality.lua index 763bb23..1127454 100644 --- a/.config/nvim/lua/plugins/functionality.lua +++ b/.config/nvim/lua/plugins/functionality.lua @@ -160,40 +160,6 @@ local M = { }) end, }, - { - 'desdic/greyjoy.nvim', - cmd = { 'Greyjoy' }, - init = function() - require('user.menu').add_actions('Greyjoy', { - ['Run command (:Greyjoy)'] = function() - vim.cmd.Greyjoy() - end, - }) - end, - config = function(_, opts) - local greyjoy = require 'greyjoy' - greyjoy.setup(opts) - greyjoy.load_extension 'generic' - greyjoy.load_extension 'makefile' - greyjoy.load_extension 'docker_compose' - end, - opts = { - extensions = { - generic = { - commands = { - ['run python {filename}'] = { - command = { 'python3', '{filename}' }, - filetype = 'python', - }, - ['run go {filename}'] = { - command = { 'go', 'run', '{filename}' }, - filetype = 'go', - }, - }, - }, - }, - }, - }, { 'iamcco/markdown-preview.nvim', build = 'cd app && yarn install', diff --git a/.config/nvim/lua/plugins/look-and-feel.lua b/.config/nvim/lua/plugins/look-and-feel.lua index 8a2a50b..3f30452 100644 --- a/.config/nvim/lua/plugins/look-and-feel.lua +++ b/.config/nvim/lua/plugins/look-and-feel.lua @@ -19,9 +19,24 @@ local M = { require('onedark').load() end, }, + { + 'rose-pine/neovim', + name = 'rose-pine', + opts = { + styles = { + bold = true, + italic = true, + transparency = true, + }, + }, + config = function(_, opts) + require('rose-pine').setup(opts) + vim.cmd [[colorscheme rose-pine]] + end, + }, { 'sainnhe/sonokai', - enabled = true, + enabled = false, config = function() vim.cmd [[ let g:sonokai_style = 'shusia' diff --git a/.config/nvim/lua/user/utils.lua b/.config/nvim/lua/user/utils.lua index 096c026..20ee2e3 100644 --- a/.config/nvim/lua/user/utils.lua +++ b/.config/nvim/lua/user/utils.lua @@ -38,6 +38,12 @@ function! ReplaceMotion(motion, text) endfunction ]] +---Execute a shell command and return its output +---@param cmd table The command to execute as a table where the first element is the command and the rest are arguments +---@param cwd? string The working directory to execute the command in (optional) +---@return table stdout The standard output as a table of lines +---@return number? ret The return code of the command +---@return table stderr The standard error as a table of lines M.get_os_command_output = function(cmd, cwd) local Job = require 'plenary.job' if not cwd then @@ -97,6 +103,10 @@ M.country_os_to_emoji = function(iso) return emoji or '' end +--- Get the next index in a table after the current element +--- @param tbl table The table to search in +--- @param cur any The current element to find +--- @return number index The next index in the table (loops back to 1) M.tbl_get_next = function(tbl, cur) local idx = 1 for i, v in ipairs(tbl) do diff --git a/zsh.d/aliases.zsh b/zsh.d/aliases.zsh index ed03280..d33763e 100755 --- a/zsh.d/aliases.zsh +++ b/zsh.d/aliases.zsh @@ -25,12 +25,16 @@ alias tf='terraform' alias tg='terragrunt' alias ls='eza ' alias git_current_branch='git branch --show-current' +alias server='python -m http.server 3030' alias dotfiles='cd ~/Repos/dotfiles' alias dc='cd ' alias pj='fdf ~/Repos' alias repos="~/Repos" +# file aliases +alias -s {lua,yml,yaml}=nvim + # global aliases alias -g Wt='while :;do ' alias -g Wr=' | while read -r line;do echo "=== $line ==="; '