Something went wrong. Try again.
forked from nix-community/nixvim
Something went wrong. Try again.
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186{ empty = { plugins.tinygit.enable = true; };
defaults = { plugins.tinygit = { enable = true;
settings = { stage = { contextSize = 1; stagedIndicator = ""; keymaps = { stagingToggle = "<Space>"; gotoHunk = "<CR>"; resetHunk = "<C-r>"; }; moveToNextHunkOnStagingToggle = false; telescopeOpts = { layout_strategy = "horizontal"; layout_config = { horizontal = { preview_width = 0.65; height = { __unkeyed = 0.7; min = 20; }; }; }; }; }; commit = { keepAbortedMsgSecs = 300; border = "rounded"; spellcheck = false; wrap = "hard"; keymaps = { normal = { abort = "q"; confirm = "<CR>"; }; insert = { confirm = "<C-CR>"; }; }; subject = { autoFormat.__raw = '' function(subject) ---@type nil|fun(subject: string): string subject = subject:gsub("%.$", "") -- remove trailing dot https://commitlint.js.org/reference/rules.html#body-full-stop return subject end ''; enforceType = false; types = [ "fix" "feat" "chore" "docs" "refactor" "build" "test" "perf" "style" "revert" "ci" "break" ]; }; body = { enforce = false; }; }; push = { preventPushingFixupCommits = true; confirmationSound = true; openReferencedIssues = false; }; github = { icons = { openIssue = "🟢"; closedIssue = "🟣"; notPlannedIssue = "⚪"; openPR = "🟩"; mergedPR = "🟪"; draftPR = "⬜"; closedPR = "🟥"; }; }; history = { diffPopup = { width = 0.8; height = 0.8; border = "rounded"; }; autoUnshallowIfNeeded = false; }; appearance = { mainIcon = ""; backdrop = { enabled = true; blend = 40; }; }; statusline = { blame = { ignoreAuthors.__empty = { }; hideAuthorNames.__empty = { }; maxMsgLen = 40; icon = "ﰖ"; }; branchState = { icons = { ahead = ""; behind = ""; diverge = ""; }; }; }; }; }; };
example = { plugins.tinygit = { enable = true;
settings = { stage.moveToNextHunkOnStagingToggle = true; commit = { keepAbortedMsgSecs.__raw = "60 * 10"; spellcheck = true; subject = { autoFormat.__raw = '' function(subject) -- remove trailing dot https://commitlint.js.org/reference/rules.html#body-full-stop subject = subject:gsub("%.$", "")
-- sentence case of title after the type subject = subject :gsub("^(%w+: )(.)", function(c1, c2) return c1 .. c2:lower() end) -- no scope :gsub("^(%w+%b(): )(.)", function(c1, c2) return c1 .. c2:lower() end) -- with scope return subject end ''; enforceType = true; types = [ "fix" "feat" "chore" "docs" "refactor" "build" "test" "perf" "style" "revert" "ci" "break" "improv" ]; }; }; push.openReferencedIssues = true; history = { autoUnshallowIfNeeded = true; diffPopup = { width = 0.9; height = 0.9; }; }; statusline = { blame = { hideAuthorNames = [ "John Doe" "johndoe" ]; ignoreAuthors = [ "🤖 automated" ]; maxMsgLen = 55; }; }; }; }; };}