mirror of https://github.com/turtlebasket/env
updates
parent
cf0d26c454
commit
764a757bfd
|
@ -1,106 +1,124 @@
|
|||
-- INSTALL PACKER:
|
||||
-- git clone --depth 1 https://github.com/wbthomason/packer.nvim\
|
||||
-- ~/.local/share/nvim/site/pack/packer/start/packer.nvim
|
||||
|
||||
-- check for vscode nvim plugin
|
||||
-- (https://github.com/vscode-neovim/vscode-neovim)
|
||||
if not vim.g.vscode then
|
||||
|
||||
-- aliases
|
||||
|
||||
|
||||
local o = vim.o
|
||||
local c = vim.cmd
|
||||
local map = vim.api.nvim_set_keymap
|
||||
|
||||
-- options
|
||||
|
||||
o.termguicolors = true
|
||||
o.mouse = 'a'
|
||||
-- o.autoindent = true
|
||||
o.smartindent = true -- replacing autoindent with this
|
||||
o.wrap = true
|
||||
o.nobinary = true
|
||||
o.relativenumber = true
|
||||
o.tabstop = 4
|
||||
o.shiftwidth = 4
|
||||
o.expandtab = true
|
||||
|
||||
-- NOTE: pcall prevents plugin system from shitting itself on first load
|
||||
if not pcall(function()
|
||||
c.colorscheme 'catppuccin'
|
||||
end) then
|
||||
print("Failed to load colorscheme - probably has not been installed")
|
||||
if vim.g.vscode then
|
||||
do return end
|
||||
else
|
||||
if vim.g.neovide then
|
||||
vim.o.guifont = "CaskaydiaCove Nerd Font:h14"
|
||||
vim.g.neovide_hide_mouse_when_typing = true
|
||||
end
|
||||
|
||||
-- keybinds
|
||||
|
||||
-- file management
|
||||
map('n', '<c-t>', ':CHADopen<cr>', {silent = true})
|
||||
|
||||
map('n', '<c-`>', ':ToggleTerm direction="float"<cr>', {silent = true})
|
||||
-- exit terminal requires <Cmd> prefix
|
||||
map('t', '<c-`>', '<Cmd>:ToggleTerm<cr>', {silent = true})
|
||||
|
||||
map('n', '<Space>gs', ':Telescope git_status<cr>', {silent = true})
|
||||
map('n', '<Space>gc', ':Telescope git_commits<cr>', {silent = true})
|
||||
map('n', '<Space>:', ':Telescope commands<cr>', {silent = true})
|
||||
map('n', '<Space><Space>', ':Telescope find_files<cr>', {silent = true})
|
||||
map('n', '<Space>f', ':Telescope grep_string<cr>', {silent = true})
|
||||
|
||||
-- buffer management
|
||||
map('n', '<c-h>', ':bp<cr>', {silent = true})
|
||||
map('n', '<c-l>', ':bn<cr>', {silent = true})
|
||||
|
||||
-- plugin configs
|
||||
|
||||
vim.g['airline_powerline_fonts'] = 1
|
||||
vim.g['airline_theme'] = 'powerlineish'
|
||||
vim.g['airline#extensions#tabline#enabled'] = 1
|
||||
vim.g['airline#extensions#tabline#fnamemod'] = ':t'
|
||||
|
||||
-- plugin imports
|
||||
|
||||
return require('packer').startup(function(use)
|
||||
|
||||
-- Packer can manage itself
|
||||
use 'wbthomason/packer.nvim'
|
||||
|
||||
-- Visual
|
||||
use 'vim-airline/vim-airline'
|
||||
use 'vim-airline/vim-airline-themes'
|
||||
use { "catppuccin/nvim", as = "catppuccin" }
|
||||
use 'airblade/vim-gitgutter'
|
||||
|
||||
-- Editor
|
||||
use {'neovim/nvim-lspconfig', config = function()
|
||||
local lspc = require('lspconfig')
|
||||
lspc['pyright'].setup{}
|
||||
lspc['tsserver'].setup{}
|
||||
lspc['clojure_lsp'].setup{}
|
||||
lspc['racket_langserver'].setup{}
|
||||
lspc['rust_analyzer'].setup{}
|
||||
lspc['gopls'].setup{}
|
||||
end}
|
||||
use 'hrsh7th/cmp-nvim-lsp'
|
||||
use {'hrsh7th/nvim-cmp', config = function()
|
||||
local cmp = require 'cmp'
|
||||
cmp.setup {
|
||||
sources = {
|
||||
{ name = 'nvim_lsp' },
|
||||
}
|
||||
}
|
||||
end}
|
||||
|
||||
use {'ms-jpq/chadtree', branch = 'chad'}
|
||||
use 'nvim-lua/plenary.nvim'
|
||||
use 'nvim-telescope/telescope.nvim'
|
||||
use {"akinsho/toggleterm.nvim", tag = '*', config = function()
|
||||
require("toggleterm").setup()
|
||||
end}
|
||||
use {'nvim-treesitter/nvim-treesitter', run = ':TSUpdate', config = function()
|
||||
require'nvim-treesitter.configs'.setup{
|
||||
highlight = {enable = true}
|
||||
}
|
||||
end}
|
||||
|
||||
end)
|
||||
end
|
||||
|
||||
-- aliases
|
||||
|
||||
local o = vim.o
|
||||
local c = vim.cmd
|
||||
local map = vim.api.nvim_set_keymap
|
||||
|
||||
-- options
|
||||
|
||||
o.termguicolors = true
|
||||
o.mouse = 'a'
|
||||
-- o.autoindent = true
|
||||
o.smartindent = true -- replacing autoindent with this
|
||||
o.wrap = false
|
||||
o.nobinary = true
|
||||
o.relativenumber = true
|
||||
o.tabstop = 4
|
||||
o.shiftwidth = 4
|
||||
o.expandtab = true
|
||||
|
||||
-- NOTE: pcall prevents plugin system from shitting itself on first load
|
||||
if not pcall(function()
|
||||
c.colorscheme 'catppuccin'
|
||||
end) then
|
||||
print("Failed to load colorscheme - probably has not been installed")
|
||||
end
|
||||
|
||||
-- keybinds
|
||||
|
||||
-- file management
|
||||
-- map('n', '<c-t>', ':CHADopen<cr>', {silent = true})
|
||||
map('n', '<c-b>', ':NvimTreeToggle<cr>', {silent = true})
|
||||
|
||||
map('n', '<c-`>', ':ToggleTerm direction="float"<cr>', {silent = true})
|
||||
-- exit terminal requires <Cmd> prefix
|
||||
map('t', '<c-`>', '<Cmd>:ToggleTerm<cr>', {silent = true})
|
||||
|
||||
map('n', '<Space>gs', ':Telescope git_status<cr>', {silent = true})
|
||||
map('n', '<Space>gc', ':Telescope git_commits<cr>', {silent = true})
|
||||
map('n', '<Space>:', ':Telescope commands<cr>', {silent = true})
|
||||
map('n', '<Space><Space>', ':Telescope find_files<cr>', {silent = true})
|
||||
map('n', '<Space>f', ':Telescope grep_string<cr>', {silent = true})
|
||||
|
||||
-- buffer management
|
||||
map('n', '<c-h>', ':bp<cr>', {silent = true})
|
||||
map('n', '<c-l>', ':bn<cr>', {silent = true})
|
||||
|
||||
-- plugin configs
|
||||
|
||||
vim.g['airline_powerline_fonts'] = 1
|
||||
vim.g['airline_theme'] = 'powerlineish'
|
||||
vim.g['airline#extensions#tabline#enabled'] = 1
|
||||
vim.g['airline#extensions#tabline#fnamemod'] = ':t'
|
||||
|
||||
-- plugin imports
|
||||
|
||||
return require('packer').startup(function(use)
|
||||
|
||||
-- Packer can manage itself
|
||||
use 'wbthomason/packer.nvim'
|
||||
|
||||
-- Visual
|
||||
use 'vim-airline/vim-airline'
|
||||
use 'vim-airline/vim-airline-themes'
|
||||
use { "catppuccin/nvim", as = "catppuccin" }
|
||||
use 'airblade/vim-gitgutter'
|
||||
|
||||
-- Editor
|
||||
use {'neovim/nvim-lspconfig', config = function()
|
||||
local lspc = require('lspconfig')
|
||||
lspc['pyright'].setup{}
|
||||
lspc['tsserver'].setup{}
|
||||
lspc['clojure_lsp'].setup{}
|
||||
lspc['racket_langserver'].setup{}
|
||||
lspc['rust_analyzer'].setup{}
|
||||
lspc['gopls'].setup{}
|
||||
end}
|
||||
use 'hrsh7th/cmp-nvim-lsp'
|
||||
use {'hrsh7th/nvim-cmp', config = function()
|
||||
local cmp = require 'cmp'
|
||||
cmp.setup {
|
||||
sources = {
|
||||
{ name = 'nvim_lsp' },
|
||||
}
|
||||
}
|
||||
end}
|
||||
|
||||
-- use {'ms-jpq/chadtree', branch = 'chad'}
|
||||
use {"nvim-tree/nvim-tree.lua", config = function()
|
||||
require("nvim-tree").setup()
|
||||
end}
|
||||
use {"nvim-tree/nvim-web-devicons"}
|
||||
|
||||
use 'nvim-lua/plenary.nvim'
|
||||
use 'nvim-telescope/telescope.nvim'
|
||||
use {"akinsho/toggleterm.nvim", tag = '*', config = function()
|
||||
require("toggleterm").setup()
|
||||
end}
|
||||
use {'nvim-treesitter/nvim-treesitter', run = ':TSUpdate', config = function()
|
||||
require'nvim-treesitter.configs'.setup{
|
||||
highlight = {enable = true}
|
||||
}
|
||||
end}
|
||||
|
||||
-- NOTE: requires Node.js >= 17
|
||||
-- use {'github/copilot.vim', run = ':Copilot setup'}
|
||||
|
||||
end)
|
||||
|
||||
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
// Keybinds in here override the editor defaults
|
||||
|
||||
// Place your key bindings in this file to override the defaultsauto[]
|
||||
[
|
||||
{
|
||||
"key": "cmd+1",
|
||||
|
@ -74,11 +73,132 @@
|
|||
"command": "-workbench.action.openEditorAtIndex9"
|
||||
},
|
||||
{
|
||||
"key": "cmd",
|
||||
"command": "workbench.action.openEditorAtIndex"
|
||||
"key": "alt+cmd+1",
|
||||
"command": "workbench.action.focusFirstEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "cmd+1",
|
||||
"command": "-workbench.action.focusFirstEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "alt+cmd+3",
|
||||
"command": "workbench.action.focusThirdEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "cmd+3",
|
||||
"command": "-workbench.action.focusThirdEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "alt+cmd+6",
|
||||
"command": "workbench.action.focusSixthEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "cmd+6",
|
||||
"command": "-workbench.action.focusSixthEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "alt+cmd+7",
|
||||
"command": "workbench.action.focusSeventhEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "cmd+7",
|
||||
"command": "-workbench.action.focusSeventhEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "alt+cmd+2",
|
||||
"command": "workbench.action.focusSecondEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "cmd+2",
|
||||
"command": "-workbench.action.focusSecondEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "alt+cmd+4",
|
||||
"command": "workbench.action.focusFourthEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "cmd+4",
|
||||
"command": "-workbench.action.focusFourthEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "alt+cmd+5",
|
||||
"command": "workbench.action.focusFifthEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "cmd+5",
|
||||
"command": "-workbench.action.focusFifthEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "alt+cmd+8",
|
||||
"command": "workbench.action.focusEighthEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "cmd+8",
|
||||
"command": "-workbench.action.focusEighthEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "alt+cmd+0",
|
||||
"command": "workbench.action.focusLastEditorGroup"
|
||||
},
|
||||
{
|
||||
"key": "cmd+h",
|
||||
"command": "workbench.action.toggleAuxiliaryBar"
|
||||
},
|
||||
{
|
||||
"key": "cmd+g",
|
||||
"command": "git-graph.view"
|
||||
},
|
||||
{
|
||||
"key": "cmd+m",
|
||||
"command": "editor.action.toggleMinimap"
|
||||
}
|
||||
"command": "-markdown.extension.editing.toggleMath",
|
||||
"when": "editorTextFocus && !editorReadonly && editorLangId == 'markdown'"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+tab",
|
||||
"command": "workbench.action.showPreviousWindowTab"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+tab",
|
||||
"command": "workbench.action.showNextWindowTab"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+tab",
|
||||
"command": "-workbench.action.quickOpenLeastRecentlyUsedEditorInGroup",
|
||||
"when": "!activeEditorGroupEmpty"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+tab",
|
||||
"command": "-workbench.action.quickOpenNavigatePreviousInEditorPicker",
|
||||
"when": "inEditorsPicker && inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+tab",
|
||||
"command": "-workbench.action.quickOpenPreviousRecentlyUsedEditorInGroup",
|
||||
"when": "!activeEditorGroupEmpty"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+tab",
|
||||
"command": "-workbench.action.quickOpenNavigateNextInEditorPicker",
|
||||
"when": "inEditorsPicker && inQuickOpen"
|
||||
},
|
||||
{
|
||||
"key": "shift+cmd+z",
|
||||
"command": "workbench.action.toggleZenMode"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+1",
|
||||
"command": "workbench.action.terminal.focusAtIndex1"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+2",
|
||||
"command": "workbench.action.terminal.focusAtIndex2"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+3",
|
||||
"command": "workbench.action.terminal.focusAtIndex3"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+4",
|
||||
"command": "workbench.action.terminal.focusAtIndex4"
|
||||
},
|
||||
]
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
#!/bin/bash
|
||||
|
||||
# PROJECT DIR PRUNING SCRIPT
|
||||
|
||||
# Lists projects in current directory with a clean git status,
|
||||
# sorted in reverse by date modified
|
||||
|
||||
printf "%-40s%-20s%s\n" 'Clean git, oldest to newest' 'Date Modified' 'Size'
|
||||
printf "%-40s%-20s%s\n" '===========================' '=============' '===='
|
||||
|
|
|
@ -1,12 +0,0 @@
|
|||
|
||||
_____ _ _ _____ _ _ _ ________ ___ ______
|
||||
|_ _| | | |_ _| \ | || | / /| ___ \/ _ \| _ \
|
||||
| | | |_| | | | | \| || |/ / | |_/ / /_\ \ | | |
|
||||
| | | _ | | | | . ` || \ | __/| _ | | | |
|
||||
| | | | | |_| |_| |\ || |\ \| | | | | | |/ /
|
||||
\_/ \_| |_/\___/\_| \_/\_| \_/\_| \_| |_/___/
|
||||
|
||||
===========================================================
|
||||
WARNING: DO NOT RESTART. THIS MACHINE'S SSD IS ENCRYPTED.
|
||||
===========================================================
|
||||
|
Loading…
Reference in New Issue