Compare commits
1 Commits
master
...
b0692ec0fd
Author | SHA1 | Date | |
---|---|---|---|
b0692ec0fd
|
56
.bashrc
56
.bashrc
@ -3,20 +3,12 @@ if [ -f /etc/bashrc ]; then
|
|||||||
. /etc/bashrc
|
. /etc/bashrc
|
||||||
fi
|
fi
|
||||||
|
|
||||||
function log() {
|
function debug() {
|
||||||
if [[ -v "$VERBOSE" ]]; then
|
if [[ -v "$DEBUG" ]]; then
|
||||||
echo "$1"
|
echo "$1"
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
function success() {
|
|
||||||
log "✅ ${1}"
|
|
||||||
}
|
|
||||||
|
|
||||||
function warn() {
|
|
||||||
log "⚠️ ${1}"
|
|
||||||
}
|
|
||||||
|
|
||||||
# Run systemd generators
|
# Run systemd generators
|
||||||
if [[ -f /usr/lib/systemd/user-environment-generators/30-systemd-environment-d-generator ]]; then
|
if [[ -f /usr/lib/systemd/user-environment-generators/30-systemd-environment-d-generator ]]; then
|
||||||
set -o allexport
|
set -o allexport
|
||||||
@ -49,58 +41,32 @@ HISTFILESIZE=$HISTSIZE
|
|||||||
HISTCONTROL=ignorespace:ignoredups
|
HISTCONTROL=ignorespace:ignoredups
|
||||||
shopt -s histappend
|
shopt -s histappend
|
||||||
|
|
||||||
# OS specific environment
|
|
||||||
#
|
|
||||||
# This should be executed before the tools section, especially if we are using
|
|
||||||
# tools from Homebrew
|
|
||||||
case "$OSTYPE" in
|
|
||||||
darwin*)
|
|
||||||
# Homebrew
|
|
||||||
if [[ -f /opt/homebrew/bin/brew ]]; then
|
|
||||||
eval "$(/opt/homebrew/bin/brew shellenv)"
|
|
||||||
success "set up homebrew"
|
|
||||||
else
|
|
||||||
warn "homebrew not found"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Ruby
|
|
||||||
if [[ -d /opt/homebrew/opt/ruby ]]; then
|
|
||||||
export PATH="/opt/homebrew/opt/ruby/bin:$PATH"
|
|
||||||
export LDFLAGS="-L/opt/homebrew/opt/ruby/lib"
|
|
||||||
export CPPFLAGS="-I/opt/homebrew/opt/ruby/include"
|
|
||||||
success "set up homebrew ruby"
|
|
||||||
else
|
|
||||||
warn "homebrew ruby not found"
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
# Tools
|
|
||||||
|
|
||||||
if command -v nvim > /dev/null; then
|
if command -v nvim > /dev/null; then
|
||||||
success "setting EDITOR to nvim"
|
debug "✅ setting EDITOR to nvim"
|
||||||
export EDITOR=nvim
|
export EDITOR=nvim
|
||||||
|
|
||||||
success "setting MANPAGER viewer to nvim"
|
debug "✅ setting MANPAGER viewer to nvim"
|
||||||
export MANPAGER="nvim +Man!"
|
export MANPAGER="nvim +Man!"
|
||||||
else
|
else
|
||||||
warn "nvim not found"
|
debug "⚠️ nvim not found"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Tools
|
||||||
|
|
||||||
# fzf
|
# fzf
|
||||||
if command -v fzf > /dev/null; then
|
if command -v fzf > /dev/null; then
|
||||||
eval "$(fzf "--$(basename "$SHELL")")"
|
eval "$(fzf "--$(basename "$SHELL")")"
|
||||||
success "set up fzf"
|
debug "✅ set up fzf"
|
||||||
else
|
else
|
||||||
warn "fzf not found"
|
debug "⚠️ fzf not found"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# starship
|
# starship
|
||||||
if command -v starship > /dev/null; then
|
if command -v starship > /dev/null; then
|
||||||
eval "$(starship init "$(basename "$SHELL")")"
|
eval "$(starship init "$(basename "$SHELL")")"
|
||||||
success "set up starship"
|
debug "✅ set up starship"
|
||||||
else
|
else
|
||||||
warn "starship not found"
|
debug "⚠️ starship not found"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Aliases
|
# Aliases
|
||||||
|
1
.colordiffrc
Normal file
1
.colordiffrc
Normal file
@ -0,0 +1 @@
|
|||||||
|
newtext = green
|
@ -1,17 +1,17 @@
|
|||||||
-- Bootstrap lazy.nvim
|
-- Bootstrap lazy.nvim
|
||||||
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
|
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
|
||||||
if not (vim.uv or vim.loop).fs_stat(lazypath) then
|
if not (vim.uv or vim.loop).fs_stat(lazypath) then
|
||||||
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
|
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
|
||||||
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
|
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
|
||||||
if vim.v.shell_error ~= 0 then
|
if vim.v.shell_error ~= 0 then
|
||||||
vim.api.nvim_echo({
|
vim.api.nvim_echo({
|
||||||
{ "Failed to clone lazy.nvim:\n", "ErrorMsg" },
|
{ "Failed to clone lazy.nvim:\n", "ErrorMsg" },
|
||||||
{ out, "WarningMsg" },
|
{ out, "WarningMsg" },
|
||||||
{ "\nPress any key to exit..." },
|
{ "\nPress any key to exit..." },
|
||||||
}, true, {})
|
}, true, {})
|
||||||
vim.fn.getchar()
|
vim.fn.getchar()
|
||||||
os.exit(1)
|
os.exit(1)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
vim.opt.rtp:prepend(lazypath)
|
vim.opt.rtp:prepend(lazypath)
|
||||||
|
|
||||||
@ -23,13 +23,13 @@ vim.g.maplocalleader = "\\"
|
|||||||
|
|
||||||
-- Setup lazy.nvim
|
-- Setup lazy.nvim
|
||||||
require("lazy").setup({
|
require("lazy").setup({
|
||||||
spec = {
|
spec = {
|
||||||
-- import your plugins
|
-- import your plugins
|
||||||
{ import = "plugins" },
|
{ import = "plugins" },
|
||||||
},
|
},
|
||||||
-- Configure any other settings here. See the documentation for more details.
|
-- Configure any other settings here. See the documentation for more details.
|
||||||
-- colorscheme that will be used when installing plugins.
|
-- colorscheme that will be used when installing plugins.
|
||||||
install = { colorscheme = { "habamax" } },
|
install = { colorscheme = { "habamax" } },
|
||||||
-- automatically check for plugin updates
|
-- automatically check for plugin updates
|
||||||
checker = { enabled = true },
|
checker = { enabled = true },
|
||||||
})
|
})
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
return {
|
return {
|
||||||
"catppuccin/nvim",
|
"catppuccin/nvim",
|
||||||
name = "catppuccin",
|
name = "catppuccin",
|
||||||
priority = 1000,
|
priority = 1000,
|
||||||
}
|
}
|
||||||
|
@ -1,13 +1,13 @@
|
|||||||
return {
|
return {
|
||||||
"ThePrimeagen/harpoon",
|
"ThePrimeagen/harpoon",
|
||||||
branch = "harpoon2",
|
branch = "harpoon2",
|
||||||
dependencies = { "nvim-lua/plenary.nvim" },
|
dependencies = { "nvim-lua/plenary.nvim" },
|
||||||
config = function()
|
config = function()
|
||||||
local harpoon = require("harpoon")
|
local harpoon = require("harpoon")
|
||||||
|
|
||||||
-- REQUIRED
|
-- REQUIRED
|
||||||
harpoon:setup()
|
harpoon:setup()
|
||||||
-- REQUIRED
|
-- REQUIRED
|
||||||
|
|
||||||
-- basic telescope configuration
|
-- basic telescope configuration
|
||||||
local conf = require("telescope.config").values
|
local conf = require("telescope.config").values
|
||||||
@ -17,45 +17,27 @@ return {
|
|||||||
table.insert(file_paths, item.value)
|
table.insert(file_paths, item.value)
|
||||||
end
|
end
|
||||||
|
|
||||||
require("telescope.pickers")
|
require("telescope.pickers").new({}, {
|
||||||
.new({}, {
|
prompt_title = "Harpoon",
|
||||||
prompt_title = "Harpoon",
|
finder = require("telescope.finders").new_table({
|
||||||
finder = require("telescope.finders").new_table({
|
results = file_paths,
|
||||||
results = file_paths,
|
}),
|
||||||
}),
|
previewer = conf.file_previewer({}),
|
||||||
previewer = conf.file_previewer({}),
|
sorter = conf.generic_sorter({}),
|
||||||
sorter = conf.generic_sorter({}),
|
}):find()
|
||||||
})
|
|
||||||
:find()
|
|
||||||
end
|
end
|
||||||
|
|
||||||
vim.keymap.set("n", "<leader>a", function()
|
vim.keymap.set("n", "<leader>a", function() harpoon:list():add() end)
|
||||||
harpoon:list():add()
|
-- vim.keymap.set("n", "<C-e>", function() harpoon.ui:toggle_quick_menu(harpoon:list()) end)
|
||||||
end)
|
vim.keymap.set("n", "<C-e>", function() toggle_telescope(harpoon:list()) end, { desc = "Open harpoon window" })
|
||||||
-- vim.keymap.set("n", "<C-e>", function() harpoon.ui:toggle_quick_menu(harpoon:list()) end)
|
|
||||||
vim.keymap.set("n", "<C-e>", function()
|
|
||||||
toggle_telescope(harpoon:list())
|
|
||||||
end, { desc = "Open harpoon window" })
|
|
||||||
|
|
||||||
vim.keymap.set("n", "<C-h>", function()
|
vim.keymap.set("n", "<C-h>", function() harpoon:list():select(1) end)
|
||||||
harpoon:list():select(1)
|
vim.keymap.set("n", "<C-t>", function() harpoon:list():select(2) end)
|
||||||
end)
|
vim.keymap.set("n", "<C-n>", function() harpoon:list():select(3) end)
|
||||||
vim.keymap.set("n", "<C-t>", function()
|
vim.keymap.set("n", "<C-s>", function() harpoon:list():select(4) end)
|
||||||
harpoon:list():select(2)
|
|
||||||
end)
|
|
||||||
vim.keymap.set("n", "<C-n>", function()
|
|
||||||
harpoon:list():select(3)
|
|
||||||
end)
|
|
||||||
vim.keymap.set("n", "<C-s>", function()
|
|
||||||
harpoon:list():select(4)
|
|
||||||
end)
|
|
||||||
|
|
||||||
-- Toggle previous & next buffers stored within Harpoon list
|
-- Toggle previous & next buffers stored within Harpoon list
|
||||||
vim.keymap.set("n", "<C-S-P>", function()
|
vim.keymap.set("n", "<C-S-P>", function() harpoon:list():prev() end)
|
||||||
harpoon:list():prev()
|
vim.keymap.set("n", "<C-S-N>", function() harpoon:list():next() end)
|
||||||
end)
|
end,
|
||||||
vim.keymap.set("n", "<C-S-N>", function()
|
|
||||||
harpoon:list():next()
|
|
||||||
end)
|
|
||||||
end,
|
|
||||||
}
|
}
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
return {
|
return {
|
||||||
"lukas-reineke/indent-blankline.nvim",
|
"lukas-reineke/indent-blankline.nvim",
|
||||||
main = "ibl",
|
main = "ibl",
|
||||||
opts = {},
|
opts = {
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
@ -14,7 +14,7 @@ return {
|
|||||||
-- ruby = { "rubocop", "standardrb" },
|
-- ruby = { "rubocop", "standardrb" },
|
||||||
ruby = { "standardrb" },
|
ruby = { "standardrb" },
|
||||||
go = { "golangcilint" },
|
go = { "golangcilint" },
|
||||||
}
|
}
|
||||||
|
|
||||||
vim.api.nvim_create_autocmd({ "BufWritePost" }, {
|
vim.api.nvim_create_autocmd({ "BufWritePost" }, {
|
||||||
callback = function()
|
callback = function()
|
||||||
|
@ -1,65 +1,65 @@
|
|||||||
return {
|
return {
|
||||||
{
|
{
|
||||||
"williamboman/mason.nvim",
|
"williamboman/mason.nvim",
|
||||||
config = function()
|
config = function()
|
||||||
require("mason").setup()
|
require("mason").setup()
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"williamboman/mason-lspconfig.nvim",
|
"williamboman/mason-lspconfig.nvim",
|
||||||
dependencies = { "williamboman/mason.nvim" },
|
dependencies = { "williamboman/mason.nvim" },
|
||||||
config = function()
|
config = function()
|
||||||
require("mason-lspconfig").setup({
|
require("mason-lspconfig").setup({
|
||||||
ensure_installed = {
|
ensure_installed = {
|
||||||
"lua_ls",
|
"lua_ls",
|
||||||
"ruby_lsp",
|
"ruby_lsp",
|
||||||
-- "standardrb",
|
-- "standardrb",
|
||||||
"terraformls",
|
"terraformls",
|
||||||
"yamlls",
|
"yamlls",
|
||||||
"pyright",
|
"pyright",
|
||||||
"zls",
|
"zls",
|
||||||
"gopls",
|
"gopls",
|
||||||
"bashls",
|
"bashls",
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"neovim/nvim-lspconfig",
|
"neovim/nvim-lspconfig",
|
||||||
dependencies = { "williamboman/mason-lspconfig.nvim" },
|
dependencies = { "williamboman/mason-lspconfig.nvim" },
|
||||||
config = function()
|
config = function()
|
||||||
local lspconfig = require("lspconfig")
|
local lspconfig = require("lspconfig")
|
||||||
|
|
||||||
lspconfig.zls.setup({})
|
lspconfig.zls.setup({})
|
||||||
lspconfig.ruby_lsp.setup({
|
lspconfig.ruby_lsp.setup({
|
||||||
init_options = {
|
init_options = {
|
||||||
formatter = "standard",
|
formatter = "standard",
|
||||||
linters = { "standard" },
|
linters = { "standard" },
|
||||||
},
|
}
|
||||||
})
|
})
|
||||||
-- lspconfig.standardrb.setup({})
|
-- lspconfig.standardrb.setup({})
|
||||||
lspconfig.bashls.setup({})
|
lspconfig.bashls.setup({})
|
||||||
lspconfig.yamlls.setup({})
|
lspconfig.yamlls.setup({})
|
||||||
lspconfig.terraformls.setup({})
|
lspconfig.terraformls.setup({})
|
||||||
lspconfig.lua_ls.setup({
|
lspconfig.lua_ls.setup({
|
||||||
settings = {
|
settings = {
|
||||||
Lua = {
|
Lua = {
|
||||||
diagnostics = {
|
diagnostics = {
|
||||||
globals = { "vim" },
|
globals = { "vim" },
|
||||||
},
|
},
|
||||||
format = {
|
format = {
|
||||||
defaultConfig = {
|
defaultConfig = {
|
||||||
indent_style = "tabs",
|
indent_style = "tabs",
|
||||||
indent_size = "4",
|
indent_size = "4",
|
||||||
},
|
},
|
||||||
enable = true,
|
enable = true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
lspconfig.pyright.setup({})
|
lspconfig.pyright.setup({})
|
||||||
lspconfig.gopls.setup({})
|
lspconfig.gopls.setup({})
|
||||||
lspconfig.zls.setup({})
|
lspconfig.zls.setup({})
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
return {
|
return {
|
||||||
"nvim-tree/nvim-tree.lua",
|
"nvim-tree/nvim-tree.lua",
|
||||||
config = function()
|
config = function()
|
||||||
require("nvim-tree").setup()
|
require("nvim-tree").setup()
|
||||||
end,
|
end
|
||||||
}
|
}
|
||||||
|
@ -1,14 +1,14 @@
|
|||||||
return {
|
return {
|
||||||
"zenbones-theme/zenbones.nvim",
|
"zenbones-theme/zenbones.nvim",
|
||||||
-- Optionally install Lush. Allows for more configuration or extending the colorscheme
|
-- Optionally install Lush. Allows for more configuration or extending the colorscheme
|
||||||
-- If you don't want to install lush, make sure to set g:zenbones_compat = 1
|
-- If you don't want to install lush, make sure to set g:zenbones_compat = 1
|
||||||
-- In Vim, compat mode is turned on as Lush only works in Neovim.
|
-- In Vim, compat mode is turned on as Lush only works in Neovim.
|
||||||
dependencies = "rktjmp/lush.nvim",
|
dependencies = "rktjmp/lush.nvim",
|
||||||
lazy = false,
|
lazy = false,
|
||||||
priority = 1000,
|
priority = 1000,
|
||||||
-- you can set set configuration options here
|
-- you can set set configuration options here
|
||||||
-- config = function()
|
-- config = function()
|
||||||
-- vim.g.zenbones_darken_comments = 45
|
-- vim.g.zenbones_darken_comments = 45
|
||||||
-- vim.cmd.colorscheme('zenbones')
|
-- vim.cmd.colorscheme('zenbones')
|
||||||
-- end
|
-- end
|
||||||
}
|
}
|
||||||
|
@ -5,6 +5,6 @@ vim.cmd("set shiftwidth=4")
|
|||||||
vim.cmd("set smartindent")
|
vim.cmd("set smartindent")
|
||||||
|
|
||||||
vim.wo.number = true
|
vim.wo.number = true
|
||||||
vim.cmd.colorscheme("tokyonight")
|
vim.cmd.colorscheme "tokyonight"
|
||||||
|
|
||||||
vim.opt.termguicolors = true
|
vim.opt.termguicolors = true
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
[user]
|
[user]
|
||||||
name = Ryan Cavicchioni
|
name = Ryan Cavicchioni
|
||||||
email = ryan@cavi.cc
|
email = ryan@cavi.cc
|
||||||
signingkey = ~/.ssh/id_ed25519.pub
|
signingkey = /home/ryan/.ssh/id_ed25519.pub
|
||||||
[color]
|
[color]
|
||||||
ui = true
|
ui = true
|
||||||
[push]
|
[push]
|
||||||
@ -17,7 +17,7 @@
|
|||||||
[log]
|
[log]
|
||||||
showSignature = true
|
showSignature = true
|
||||||
[gpg "ssh"]
|
[gpg "ssh"]
|
||||||
allowedSignersFile = ~/.ssh/allowed_signers
|
allowedSignersFile = /home/ryan/.ssh/allowed_signers
|
||||||
[diff]
|
[diff]
|
||||||
tool = meld
|
tool = meld
|
||||||
[difftool]
|
[difftool]
|
||||||
|
3
.gitignore
vendored
Normal file
3
.gitignore
vendored
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
!.vim/bundle/Vundle.vim
|
||||||
|
.vim/bundle/*
|
||||||
|
.vim/swp/*
|
0
.gitmodules
vendored
Normal file
0
.gitmodules
vendored
Normal file
3
.hgrc
Normal file
3
.hgrc
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
[ui]
|
||||||
|
username = Ryan Cavicchioni <ryan@confabulator.net>
|
||||||
|
editor = vim
|
@ -1,4 +0,0 @@
|
|||||||
ryan@cavi.cc namespaces="git" ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGznaofIstAxYsX1MH8xQiZU4aOO4SUw9OlRbyFMfQTx compy386
|
|
||||||
ryan@cavi.cc namespaces="git" ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICndorpp/6aKlLq2K1YP81r8zA80VGp1qAUeCZtdVhAw lappy486
|
|
||||||
rcavicchioni@gmail.com namespaces="git" ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGznaofIstAxYsX1MH8xQiZU4aOO4SUw9OlRbyFMfQTx compy386
|
|
||||||
rcavicchioni@gmail.com namespaces="git" ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICndorpp/6aKlLq2K1YP81r8zA80VGp1qAUeCZtdVhAw lappy486
|
|
28
Makefile
Normal file
28
Makefile
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
install: install-vim install-git install-bash install-colordiff install-hg \
|
||||||
|
install-mutt
|
||||||
|
|
||||||
|
install-vim:
|
||||||
|
rm -rf ~/.vim ~/.vimrc
|
||||||
|
ln -s `pwd`/.vim ~/.vim
|
||||||
|
ln -s ~/.vim/vimrc ~/.vimrc
|
||||||
|
|
||||||
|
install-git:
|
||||||
|
rm -f ~/.gitconfig
|
||||||
|
ln -s `pwd`/.gitconfig ~/.gitconfig
|
||||||
|
|
||||||
|
install-bash:
|
||||||
|
rm -f ~/.bash_profile ~/.inputrc
|
||||||
|
ln -s `pwd`/.bash_profile ~/.bash_profile
|
||||||
|
ln -s `pwd`/.inputrc ~/.inputrc
|
||||||
|
|
||||||
|
install-colordiff:
|
||||||
|
rm -f ~/.colordiffrc
|
||||||
|
ln -s `pwd`/.colordiffrc ~/.colordiffrc
|
||||||
|
|
||||||
|
install-hg:
|
||||||
|
rm -f ~/.hgrc
|
||||||
|
ln -s `pwd`/.hgrc ~/.hgrc
|
||||||
|
|
||||||
|
install-mutt:
|
||||||
|
rm -f ~/.muttrc
|
||||||
|
ln -s `pwd`/.muttrc ~/.muttrc
|
Reference in New Issue
Block a user