Git ignore .pre-commit-config.yaml
Add fish abbreviation for git commit --amend Don't autoformat when writing commit message in neovim
This commit is contained in:
parent
4cb90679a2
commit
e42a6ceacf
4 changed files with 3 additions and 2 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -1,2 +1,3 @@
|
||||||
result
|
result
|
||||||
.direnv
|
.direnv
|
||||||
|
.pre-commit-config.yaml
|
||||||
|
|
|
@ -1 +0,0 @@
|
||||||
/nix/store/8f0hn1ibbqhjnmmpjq235wqp3id2cvi1-pre-commit-config.json
|
|
|
@ -179,6 +179,7 @@
|
||||||
gco = "git checkout";
|
gco = "git checkout";
|
||||||
gd = "git diff";
|
gd = "git diff";
|
||||||
gc = "git commit";
|
gc = "git commit";
|
||||||
|
gca = "git commit --amend";
|
||||||
gpl = "git pull";
|
gpl = "git pull";
|
||||||
gb = "git branch";
|
gb = "git branch";
|
||||||
ga = "git add";
|
ga = "git add";
|
||||||
|
|
|
@ -57,7 +57,7 @@ end
|
||||||
vim.api.nvim_create_autocmd("BufWritePost", {
|
vim.api.nvim_create_autocmd("BufWritePost", {
|
||||||
pattern = "*",
|
pattern = "*",
|
||||||
callback = function()
|
callback = function()
|
||||||
if has_treefmt() then
|
if vim.fn.expand("%:p") ~= vim.fn.getcwd() .. "/.git/COMMIT_EDITMSG" and has_treefmt() then
|
||||||
vim.cmd("silent !treefmt > /dev/null 2>&1")
|
vim.cmd("silent !treefmt > /dev/null 2>&1")
|
||||||
end
|
end
|
||||||
end,
|
end,
|
||||||
|
|
Loading…
Reference in a new issue