mirror of
https://github.com/starr-dusT/dotfiles.git
synced 2025-02-19 19:27:31 -08:00
Merge branch 'master' of github.com:starr-dusT/dotfiles
This commit is contained in:
commit
f5e569543f
@ -6,8 +6,11 @@ apps=(
|
|||||||
"yuzu Yuzu"
|
"yuzu Yuzu"
|
||||||
)
|
)
|
||||||
|
|
||||||
for app in "${apps[@]}"
|
if command -v steamtinkerlaunch &> /dev/null
|
||||||
do
|
then
|
||||||
set -- $app
|
for app in "${apps[@]}"
|
||||||
steamtinkerlaunch addnonsteamgame -ep="$1" -an="$2"
|
do
|
||||||
done
|
set -- $app
|
||||||
|
steamtinkerlaunch addnonsteamgame -ep="$1" -an="$2"
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
@ -1,19 +0,0 @@
|
|||||||
##⠀⠀⠀⠀⠀⠀⠀⠀⢠⡆⠀⠀⠀⠀⠀⠀⠀⠀⠀
|
|
||||||
#⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⣿⡀⠀⠀⠀⠀⠀⠀⠀⠀
|
|
||||||
#⠀⠀⠀⠀⠀⠀⠀⠀⣼⡏⠸⣧⠀⠀⠀⠀⠀⠀⠀⠀
|
|
||||||
#⠠⢤⣤⣤⣤⣤⣤⣴⡿⠀⠀⢻⣦⣤⣤⣤⣤⣤⡤⠄ Tyler Starr (starr-dusT)
|
|
||||||
#⠀⠀⠙⠻⣦⣄⠀⠀⠀⠀⠀⠀⠀⠀⣠⣴⠟⠋⠀⠀ https://github.com/starr-dusT/dotfiles
|
|
||||||
#⠀⠀⠀⠀⠀⠙⣿⡆⠀⠀⠀⠀⠰⣿⠋⠀⠀⠀⠀⠀ https://tstarr.us
|
|
||||||
#⠀⠀⠀⠀⠀⢰⡟⠀⣀⣴⣦⣀⠀⢻⡆⠀⠀⠀⠀⠀
|
|
||||||
#⠀⠀⠀⠀⢀⣾⣧⡾⠛⠁⠈⠙⠷⣼⣿⡀⠀⠀⠀⠀
|
|
||||||
# ⠀⠀⠀⡸⠟⠁⠀⠀⠀⠀⠀⠀⠈⠛⢧⠀⠀⠀⠀
|
|
||||||
#
|
|
||||||
# Work .gitconfig
|
|
||||||
|
|
||||||
[user]
|
|
||||||
email = tyler.starr.1@us.af.mil
|
|
||||||
name = Tyler Starr
|
|
||||||
signingkey = C0D188999C0697C0
|
|
||||||
|
|
||||||
[gitlab]
|
|
||||||
user = "tstarr"
|
|
@ -2,7 +2,7 @@
|
|||||||
# https://github.com/starr-dusT/dotfiles
|
# https://github.com/starr-dusT/dotfiles
|
||||||
|
|
||||||
# nixos
|
# nixos
|
||||||
alias nixos-update="cd ~/.local/share/chezmoi/provision/nixos && \
|
alias nu="cd ~/.local/share/chezmoi/provision/nixos && \
|
||||||
sudo nixos-rebuild switch --flake .#$(hostname) && \
|
sudo nixos-rebuild switch --flake .#$(hostname) && \
|
||||||
cd -"
|
cd -"
|
||||||
# sway
|
# sway
|
||||||
|
@ -1,153 +1,60 @@
|
|||||||
local Remap = require("tstarr.keymap")
|
local lsp = require("lsp-zero")
|
||||||
local nnoremap = Remap.nnoremap
|
|
||||||
local inoremap = Remap.inoremap
|
lsp.preset("recommended")
|
||||||
|
|
||||||
|
lsp.ensure_installed({
|
||||||
|
'tsserver',
|
||||||
|
'pyright',
|
||||||
|
'lua_ls',
|
||||||
|
})
|
||||||
|
|
||||||
|
-- Fix Undefined global 'vim'
|
||||||
|
lsp.nvim_workspace()
|
||||||
|
|
||||||
|
|
||||||
local cmp = require('cmp')
|
local cmp = require('cmp')
|
||||||
local lspconfig = require('lspconfig')
|
local cmp_select = {behavior = cmp.SelectBehavior.Select}
|
||||||
local configs = require('lspconfig/configs')
|
local cmp_mappings = lsp.defaults.cmp_mappings({
|
||||||
|
['<C-p>'] = cmp.mapping.select_prev_item(cmp_select),
|
||||||
cmp.setup({
|
['<C-n>'] = cmp.mapping.select_next_item(cmp_select),
|
||||||
snippet = {
|
['<C-y>'] = cmp.mapping.confirm({ select = true }),
|
||||||
expand = function(args)
|
["<C-Space>"] = cmp.mapping.complete(),
|
||||||
require('luasnip').lsp_expand(args.body) -- For `luasnip` users.
|
|
||||||
end,
|
|
||||||
},
|
|
||||||
window = {
|
|
||||||
completion = cmp.config.window.bordered(),
|
|
||||||
documentation = cmp.config.window.bordered(),
|
|
||||||
},
|
|
||||||
mapping = cmp.mapping.preset.insert({
|
|
||||||
["<Tab>"] = cmp.mapping(function(fallback)
|
|
||||||
if cmp.visible() then
|
|
||||||
cmp.select_next_item()
|
|
||||||
else
|
|
||||||
fallback()
|
|
||||||
end
|
|
||||||
end, { "i" }),
|
|
||||||
["<S-Tab>"] = cmp.mapping(function(fallback)
|
|
||||||
if cmp.visible() then
|
|
||||||
cmp.select_prev_item()
|
|
||||||
else
|
|
||||||
fallback()
|
|
||||||
end
|
|
||||||
end, { "i" }),
|
|
||||||
['<C-b>'] = cmp.mapping.scroll_docs(-4),
|
|
||||||
['<C-f>'] = cmp.mapping.scroll_docs(4),
|
|
||||||
['<C-Space>'] = cmp.mapping.complete(),
|
|
||||||
['<C-e>'] = cmp.mapping.abort(),
|
|
||||||
['<CR>'] = cmp.mapping.confirm({ select = true }), -- Accept currently selected item. Set `select` to `false` to only confirm explicitly selected items.
|
|
||||||
}),
|
|
||||||
sources = cmp.config.sources({
|
|
||||||
{ name = 'nvim_lsp' },
|
|
||||||
{ name = 'luasnip' }, -- For luasnip users.
|
|
||||||
}, {
|
|
||||||
{ name = 'buffer',
|
|
||||||
option = {
|
|
||||||
get_bufnrs = function()
|
|
||||||
local bufs = {}
|
|
||||||
for _, win in ipairs(vim.api.nvim_list_wins()) do
|
|
||||||
bufs[vim.api.nvim_win_get_buf(win)] = true
|
|
||||||
end
|
|
||||||
return vim.tbl_keys(bufs)
|
|
||||||
end
|
|
||||||
}
|
|
||||||
},
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
|
|
||||||
cmp.setup.cmdline('/', {
|
cmp_mappings['<Tab>'] = nil
|
||||||
mapping = cmp.mapping.preset.cmdline(),
|
cmp_mappings['<S-Tab>'] = nil
|
||||||
sources = {
|
|
||||||
{ name = 'buffer' }
|
lsp.setup_nvim_cmp({
|
||||||
}
|
mapping = cmp_mappings
|
||||||
})
|
})
|
||||||
|
|
||||||
cmp.setup.cmdline(':', {
|
lsp.set_preferences({
|
||||||
mapping = cmp.mapping.preset.cmdline(),
|
suggest_lsp_servers = false,
|
||||||
sources = cmp.config.sources({
|
sign_icons = {
|
||||||
{ name = 'path' },
|
error = 'E',
|
||||||
{ name = 'buffer' }
|
warn = 'W',
|
||||||
}, {
|
hint = 'H',
|
||||||
{
|
info = 'I'
|
||||||
name = 'cmdline',
|
|
||||||
option = {
|
|
||||||
ignore_cmds = { 'Man', '!' }
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
})
|
|
||||||
})
|
})
|
||||||
|
|
||||||
local function config(_config)
|
lsp.on_attach(function(client, bufnr)
|
||||||
return vim.tbl_deep_extend("force", {
|
local opts = {buffer = bufnr, remap = false}
|
||||||
on_attach = function()
|
|
||||||
local opts = { buffer = true };
|
|
||||||
nnoremap("gd", function() vim.lsp.buf.definition() end, opts)
|
|
||||||
nnoremap("K", function() vim.lsp.buf.hover() end, opts)
|
|
||||||
nnoremap("<leader>vws", function() vim.lsp.buf.workspace_symbol() end, opts)
|
|
||||||
nnoremap("<leader>vd", function() vim.diagnostic.open_float() end, opts)
|
|
||||||
nnoremap("[d", function() vim.diagnostic.goto_next() end, opts)
|
|
||||||
nnoremap("]d", function() vim.diagnostic.goto_prev() end, opts)
|
|
||||||
nnoremap("<leader>vca", function() vim.lsp.buf.code_action() end, opts)
|
|
||||||
nnoremap("<leader>vco", function() vim.lsp.buf.code_action({
|
|
||||||
filter = function(code_action)
|
|
||||||
if not code_action or not code_action.data then
|
|
||||||
return false
|
|
||||||
end
|
|
||||||
|
|
||||||
local data = code_action.data.id
|
|
||||||
return string.sub(data, #data - 1, #data) == ":0"
|
|
||||||
end,
|
|
||||||
apply = true
|
|
||||||
}) end, opts)
|
|
||||||
nnoremap("<leader>vrr", function() vim.lsp.buf.references() end, opts)
|
|
||||||
nnoremap("<leader>vrn", function() vim.lsp.buf.rename() end, opts)
|
|
||||||
inoremap("<C-h>", function() vim.lsp.buf.signature_help() end, opts)
|
|
||||||
end,
|
|
||||||
}, _config or {})
|
|
||||||
end
|
|
||||||
|
|
||||||
-- Python
|
|
||||||
lspconfig.tsserver.setup(config())
|
|
||||||
lspconfig.pyright.setup(config())
|
|
||||||
|
|
||||||
-- zk
|
|
||||||
configs.zk = {
|
|
||||||
default_config = {
|
|
||||||
cmd = {'zk', 'lsp'},
|
|
||||||
filetypes = {'markdown'},
|
|
||||||
root_dir = function()
|
|
||||||
return vim.loop.cwd()
|
|
||||||
end,
|
|
||||||
settings = {}
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
lspconfig.zk.setup({ on_attach = function(client, buffer)
|
|
||||||
-- Add keybindings here, see https://github.com/neovim/nvim-lspconfig#keybindings-and-completion
|
|
||||||
end })
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
vim.keymap.set("n", "gd", function() vim.lsp.buf.definition() end, opts)
|
||||||
|
vim.keymap.set("n", "K", function() vim.lsp.buf.hover() end, opts)
|
||||||
|
vim.keymap.set("n", "<leader>vws", function() vim.lsp.buf.workspace_symbol() end, opts)
|
||||||
|
vim.keymap.set("n", "<leader>vd", function() vim.diagnostic.open_float() end, opts)
|
||||||
|
vim.keymap.set("n", "[d", function() vim.diagnostic.goto_next() end, opts)
|
||||||
|
vim.keymap.set("n", "]d", function() vim.diagnostic.goto_prev() end, opts)
|
||||||
|
vim.keymap.set("n", "<leader>vca", function() vim.lsp.buf.code_action() end, opts)
|
||||||
|
vim.keymap.set("n", "<leader>vrr", function() vim.lsp.buf.references() end, opts)
|
||||||
|
vim.keymap.set("n", "<leader>vrn", function() vim.lsp.buf.rename() end, opts)
|
||||||
|
vim.keymap.set("i", "<C-h>", function() vim.lsp.buf.signature_help() end, opts)
|
||||||
|
end)
|
||||||
|
|
||||||
|
lsp.setup()
|
||||||
|
|
||||||
|
vim.diagnostic.config({
|
||||||
|
virtual_text = true
|
||||||
|
})
|
||||||
|
@ -13,11 +13,8 @@ return require('packer').startup(function(use)
|
|||||||
use ('alker0/chezmoi.vim')
|
use ('alker0/chezmoi.vim')
|
||||||
use ('nathangrigg/vim-beancount')
|
use ('nathangrigg/vim-beancount')
|
||||||
|
|
||||||
-- IDE
|
-- IDE
|
||||||
use('nvim-lua/plenary.nvim')
|
use('nvim-lua/plenary.nvim')
|
||||||
use("nvim-treesitter/nvim-treesitter", {
|
|
||||||
run = ":TSUpdate"
|
|
||||||
})
|
|
||||||
use ('nvim-telescope/telescope.nvim')
|
use ('nvim-telescope/telescope.nvim')
|
||||||
use ('nvim-telescope/telescope-project.nvim')
|
use ('nvim-telescope/telescope-project.nvim')
|
||||||
|
|
||||||
@ -32,13 +29,28 @@ return require('packer').startup(function(use)
|
|||||||
use('mcchrish/nnn.vim')
|
use('mcchrish/nnn.vim')
|
||||||
|
|
||||||
-- LSP
|
-- LSP
|
||||||
use ('neovim/nvim-lspconfig')
|
use("nvim-treesitter/nvim-treesitter-context");
|
||||||
use ('hrsh7th/cmp-nvim-lsp')
|
use {
|
||||||
use ('hrsh7th/cmp-buffer')
|
'VonHeikemen/lsp-zero.nvim',
|
||||||
use ('hrsh7th/cmp-path')
|
branch = 'v1.x',
|
||||||
use ('hrsh7th/cmp-cmdline')
|
requires = {
|
||||||
use ('hrsh7th/nvim-cmp')
|
-- LSP Support
|
||||||
use ('L3MON4D3/LuaSnip')
|
{'neovim/nvim-lspconfig'},
|
||||||
use ('saadparwaiz1/cmp_luasnip')
|
{'williamboman/mason.nvim'},
|
||||||
|
{'williamboman/mason-lspconfig.nvim'},
|
||||||
|
|
||||||
|
-- Autocompletion
|
||||||
|
{'hrsh7th/nvim-cmp'},
|
||||||
|
{'hrsh7th/cmp-buffer'},
|
||||||
|
{'hrsh7th/cmp-path'},
|
||||||
|
{'saadparwaiz1/cmp_luasnip'},
|
||||||
|
{'hrsh7th/cmp-nvim-lsp'},
|
||||||
|
{'hrsh7th/cmp-nvim-lua'},
|
||||||
|
|
||||||
|
-- Snippets
|
||||||
|
{'L3MON4D3/LuaSnip'},
|
||||||
|
{'rafamadriz/friendly-snippets'},
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
end)
|
end)
|
||||||
|
@ -194,7 +194,7 @@ mode launcher {
|
|||||||
}
|
}
|
||||||
bindsym $mod+o mode open
|
bindsym $mod+o mode open
|
||||||
mode open {
|
mode open {
|
||||||
bindsym b exec brave, $e
|
bindsym b exec chromium, $e
|
||||||
bindsym s exec steam || flatpak run com.valvesoftware.Steam, $e
|
bindsym s exec steam || flatpak run com.valvesoftware.Steam, $e
|
||||||
bindsym d exec discord || flatpak run com.discordapp.Discord, $e
|
bindsym d exec discord || flatpak run com.discordapp.Discord, $e
|
||||||
bindsym Escape mode default
|
bindsym Escape mode default
|
||||||
|
@ -1,13 +1,4 @@
|
|||||||
##⠀⠀⠀⠀⠀⠀⠀⠀⢠⡆⠀⠀⠀⠀⠀⠀⠀⠀⠀
|
# https://github.com/starr-dusT/dotfiles
|
||||||
#⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⣿⡀⠀⠀⠀⠀⠀⠀⠀⠀
|
|
||||||
#⠀⠀⠀⠀⠀⠀⠀⠀⣼⡏⠸⣧⠀⠀⠀⠀⠀⠀⠀⠀
|
|
||||||
#⠠⢤⣤⣤⣤⣤⣤⣴⡿⠀⠀⢻⣦⣤⣤⣤⣤⣤⡤⠄ Tyler Starr (starr-dusT)
|
|
||||||
#⠀⠀⠙⠻⣦⣄⠀⠀⠀⠀⠀⠀⠀⠀⣠⣴⠟⠋⠀⠀ https://github.com/starr-dusT/dotfiles
|
|
||||||
#⠀⠀⠀⠀⠀⠙⣿⡆⠀⠀⠀⠀⠰⣿⠋⠀⠀⠀⠀⠀ https://tstarr.us
|
|
||||||
#⠀⠀⠀⠀⠀⢰⡟⠀⣀⣴⣦⣀⠀⢻⡆⠀⠀⠀⠀⠀
|
|
||||||
#⠀⠀⠀⠀⢀⣾⣧⡾⠛⠁⠈⠙⠷⣼⣿⡀⠀⠀⠀⠀
|
|
||||||
# ⠀⠀⠀⡸⠟⠁⠀⠀⠀⠀⠀⠀⠈⠛⢧⠀⠀⠀⠀
|
|
||||||
#
|
|
||||||
# Global .gitconfig
|
# Global .gitconfig
|
||||||
|
|
||||||
[user]
|
[user]
|
||||||
@ -19,6 +10,3 @@
|
|||||||
|
|
||||||
[core]
|
[core]
|
||||||
sshCommand = "ssh -i ~/.ssh/keys/github_personal"
|
sshCommand = "ssh -i ~/.ssh/keys/github_personal"
|
||||||
|
|
||||||
[includeIf "gitdir:~/devel/work/**"]
|
|
||||||
path = ~/devel/work/.gitconfig.work
|
|
||||||
|
@ -1,13 +1,4 @@
|
|||||||
##⠀⠀⠀⠀⠀⠀⠀⠀⢠⡆⠀⠀⠀⠀⠀⠀⠀⠀⠀
|
# https://github.com/starr-dusT/dotfiles
|
||||||
#⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⣿⡀⠀⠀⠀⠀⠀⠀⠀⠀
|
|
||||||
#⠀⠀⠀⠀⠀⠀⠀⠀⣼⡏⠸⣧⠀⠀⠀⠀⠀⠀⠀⠀
|
|
||||||
#⠠⢤⣤⣤⣤⣤⣤⣴⡿⠀⠀⢻⣦⣤⣤⣤⣤⣤⡤⠄ Tyler Starr (starr-dusT)
|
|
||||||
#⠀⠀⠙⠻⣦⣄⠀⠀⠀⠀⠀⠀⠀⠀⣠⣴⠟⠋⠀⠀ https://github.com/starr-dusT/dotfiles
|
|
||||||
#⠀⠀⠀⠀⠀⠙⣿⡆⠀⠀⠀⠀⠰⣿⠋⠀⠀⠀⠀⠀ https://tstarr.us
|
|
||||||
#⠀⠀⠀⠀⠀⢰⡟⠀⣀⣴⣦⣀⠀⢻⡆⠀⠀⠀⠀⠀
|
|
||||||
#⠀⠀⠀⠀⢀⣾⣧⡾⠛⠁⠈⠙⠷⣼⣿⡀⠀⠀⠀⠀
|
|
||||||
# ⠀⠀⠀⡸⠟⠁⠀⠀⠀⠀⠀⠀⠈⠛⢧⠀⠀⠀⠀
|
|
||||||
#
|
|
||||||
# vim style tmux config
|
# vim style tmux config
|
||||||
|
|
||||||
# use C-a, since it's on the home row and easier to hit than C-b
|
# use C-a, since it's on the home row and easier to hit than C-b
|
||||||
|
Loading…
x
Reference in New Issue
Block a user