Skip to content

Commit 6c0398c

Browse files
committed
chore: readd jira
1 parent 4997828 commit 6c0398c

File tree

14 files changed

+94
-2721
lines changed

14 files changed

+94
-2721
lines changed

Brewfile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@ brew 'ripgrep'
4242
brew 'rust'
4343
brew 'sops'
4444
brew 'tig'
45-
brew 'tmux'
4645
brew 'tree'
4746
brew 'utf8proc', args: ['HEAD']
4847
brew 'watch'

Brewfile.lock.json

Lines changed: 0 additions & 2660 deletions
This file was deleted.
Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
#!/usr/bin/env bash
22
# vim: ft=bash
33

4+
if !type jira &> /dev/null
5+
then
6+
go install github.com/ankitpokhrel/jira-cli/cmd/jira@latest
7+
fi
8+
49
readonly ISSUE=$(
510
jira issue list -a $(jira me) -q 'status NOT IN (Done, Closed)' --plain --columns key,summary --no-headers |
611
fzf --query="$1" --no-multi --select-1 --exit-0 \
@@ -11,22 +16,23 @@ if [[ -z $ISSUE ]]; then
1116
exit 0
1217
fi
1318

14-
readonly JIRA_URL="https://${JIRA_ORG}.atlassian.net/browse"
1519
readonly ISSUE_NUMBER=$(echo $ISSUE | awk '{print $1}')
1620
readonly ISSUE_TITLE=$(echo $ISSUE | awk '{$1=""; print $0}')
21+
readonly TITLE_SANITIZED=$(echo "$ISSUE_TITLE" | tr '[:upper:]' '[:lower:]' | tr -s ' ' '-' | sed 's/^-//;s/-$//')
22+
readonly ISSUE_BRANCH="$ISSUE_NUMBER-$TITLE_SANITIZED"
1723

18-
if [ $(git branch | grep $ISSUE_NUMBER) ]
24+
if [ $(git branch | grep $ISSUE_BRANCH) ]
1925
then
2026
echo "Already exists, switching!"
21-
git switch $ISSUE_NUMBER
27+
git switch $ISSUE_BRANCH
2228
exit 0
2329
fi
2430

25-
git checkout -b $ISSUE_NUMBER
26-
git commit --allow-empty -m "$ISSUE_TITLE"
31+
git checkout -b "$ISSUE_BRANCH"
32+
git commit --allow-empty -m "$ISSUE_NUMBER: $ISSUE_TITLE"
2733

2834
gh pr create \
2935
--assignee @me \
3036
--draft \
31-
--title "$ISSUE_NUMBER:$ISSUE_TITLE" \
32-
--body "[Ticket]($JIRA_URL/$ISSUE_NUMBER): ${ISSUE_TITLE}"
37+
--fill \
38+
--title "$ISSUE_NUMBER: $ISSUE_TITLE" \
File renamed without changes.

bin/pr-title

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
#!/usr/bin/env bash
2+
# vim: ft=bash
3+
4+
read -p "Enter Jira title: " ISSUE
5+
6+
if [[ -z $ISSUE ]]; then
7+
exit 0
8+
fi
9+
10+
readonly ISSUE_BRANCH="$(echo $ISSUE | awk -F': ' '{print $1}')"
11+
readonly ISSUE_TITLE="$(echo $ISSUE | awk -F': ' '{print $2}')"
12+
13+
if git branch | grep $ISSUE_BRANCH
14+
then
15+
echo "Already exists, switching!"
16+
git switch $ISSUE_BRANCH
17+
exit 0
18+
fi
19+
20+
git checkout -b $ISSUE_BRANCH
21+
git commit --allow-empty -m "$ISSUE_TITLE"
22+
23+
gh pr create \
24+
--assignee @me \
25+
--draft \
26+
--fill \
27+
--title "$ISSUE_TITLE"

ghostty/config

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1+
window-inherit-working-directory = true
12
font-size = 16
23
theme = dark:GruvboxDarkHard,light:GruvboxLight
3-
# Change when nvim supports as well.
4-
# theme = GruvboxDarkHard
4+
keybind = super+enter=unbind
5+
fullscreen = true

git/gitconfig.symlink

Lines changed: 20 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -6,33 +6,36 @@
66
format = ssh
77
[gpg "ssh"]
88
allowedSignersFile = ~/.git_signers
9-
[alias]
10-
compare = log --oneline master..
11-
author = shortlog -s -e
12-
ci = commit
13-
co = checkout
14-
br = branch
15-
st = status -s
16-
edit = !nvim $(git ls-files -m) -p
17-
flux = log --author="flux" --oneline
18-
pr = !pull-request
19-
wip = commit -am 'wip'
20-
web = !gh pr view -w
21-
fswitch = !git branch | fzf | xargs git switch
9+
[branch]
10+
sort = -committerdate
11+
[fetch]
12+
prune = true
13+
pruneTags = true
14+
all = true
2215
[push]
2316
default = simple
2417
autoSetupRemote = true
2518
[color]
2619
ui = true
27-
[color "branch"]
28-
current = yellow reverse
29-
local = yellow
30-
remote = green
3120
[merge]
3221
tool = nvimdiff
3322
[diff]
3423
tool = nvimdiff
24+
algorithm = histogram
3525
[difftool]
3626
prompt = false
3727
[mergetool]
3828
keepBackup = false
29+
[alias]
30+
compare = log --oneline main..
31+
author = !git shortlog -s -e | sort -r
32+
ci = commit
33+
co = checkout
34+
br = branch
35+
st = status -s
36+
edit = !nvim $(git ls-files -m) -p
37+
flux = log --author="flux" --oneline
38+
pr = !pr-jira
39+
wip = commit -am 'wip'
40+
web = !gh pr view -w
41+
fswitch = !git branch | fzf | xargs git switch

go/install.sh

Lines changed: 0 additions & 14 deletions
This file was deleted.

nvim/config/init.lua

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,10 @@ require('options')
33
require('keymaps')
44

55
vim.api.nvim_create_autocmd("BufWritePre", {
6-
pattern = "*.go",
7-
command = "lua vim.lsp.buf.format()",
6+
pattern = {"*.go", "*.tf"},
7+
callback = function()
8+
vim.lsp.buf.format()
9+
end
810
})
911

1012
vim.api.nvim_create_autocmd({"BufRead", "BufNewFile"}, {

nvim/config/lazy-lock.json

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
11
{
22
"auto-dark-mode.nvim": { "branch": "master", "commit": "02ef9553e2a1d6e861bc6955d58ce5883d28a6ad" },
3-
"blink.cmp": { "branch": "main", "commit": "b6f11a0aa33e601c469a126e3ed6e35208fe3ea3" },
4-
"copilot.vim": { "branch": "release", "commit": "87038123804796ca7af20d1b71c3428d858a9124" },
3+
"blink.cmp": { "branch": "main", "commit": "dcda20d3aa345025699a920c45b0a0603551f41d" },
4+
"copilot.vim": { "branch": "release", "commit": "cd7f01009fb7b30e22840cadc4faad88b05c6eef" },
55
"friendly-snippets": { "branch": "main", "commit": "efff286dd74c22f731cdec26a70b46e5b203c619" },
6-
"fzf-lua": { "branch": "main", "commit": "6607312ca0e0656e64c98ce748b79be713ca8f76" },
6+
"fzf-lua": { "branch": "main", "commit": "ae9378a48fcf07475d93b3dc7775c2aab0b9fa7b" },
77
"git-blame.nvim": { "branch": "master", "commit": "2883a7460f611c2705b23f12d58d398d5ce6ec00" },
8-
"lazy.nvim": { "branch": "main", "commit": "d8f26efd456190241afd1b0f5235fe6fdba13d4a" },
9-
"lualine.nvim": { "branch": "master", "commit": "2a5bae925481f999263d6f5ed8361baef8df4f83" },
10-
"mason.nvim": { "branch": "main", "commit": "e2f7f9044ec30067bc11800a9e266664b88cda22" },
11-
"nvim-base16": { "branch": "master", "commit": "6ac181b5733518040a33017dde654059cd771b7c" },
12-
"nvim-lspconfig": { "branch": "master", "commit": "e5bf88e5ea1c4cea5ea96b1e970cb264f7a401a1" },
8+
"lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" },
9+
"lualine.nvim": { "branch": "master", "commit": "f4f791f67e70d378a754d02da068231d2352e5bc" },
10+
"mason.nvim": { "branch": "main", "commit": "fc98833b6da5de5a9c5b1446ac541577059555be" },
11+
"nvim-base16": { "branch": "master", "commit": "3f13e15c53ea2aaf79c24ceab725309d87f0619c" },
12+
"nvim-lspconfig": { "branch": "master", "commit": "8e8fd432f05b126a9dd1635e8022c7e7d1a04e60" },
1313
"nvim-test": { "branch": "main", "commit": "e06f3d029ee161f3ead6193cf27354d1eb8723c3" },
14-
"nvim-treesitter": { "branch": "master", "commit": "d34e62afd3e483fe0fa2f24b6323f3bb1d35ddcc" },
15-
"nvim-treesitter-context": { "branch": "master", "commit": "bece284c5322ddf6946fa4bdc383a2bc033269d7" },
16-
"nvim-treesitter-textobjects": { "branch": "master", "commit": "ad8f0a472148c3e0ae9851e26a722ee4e29b1595" },
17-
"nvim-web-devicons": { "branch": "master", "commit": "37334adf4517fecfd97c0b44e1d4718e377e9e52" },
18-
"oil.nvim": { "branch": "master", "commit": "a3fc6623fa9a3c49ed94b5dbe9f181fbd2e93e64" },
19-
"quick-scope": { "branch": "master", "commit": "51ba865a7bf984fd2361fe219449df452337b10d" },
20-
"vim-fugitive": { "branch": "master", "commit": "d74a7cff4cfcf84f83cc7eccfa365488f3bbabc2" },
14+
"nvim-treesitter": { "branch": "master", "commit": "c1efc9a9058bb54cfcb6f0a4fc14a4ac8a66bdaa" },
15+
"nvim-treesitter-context": { "branch": "master", "commit": "198720b4016af04c9590f375d714d5bf8afecc1a" },
16+
"nvim-treesitter-textobjects": { "branch": "master", "commit": "ab0950c53d1ae04da8e488aa762b450d5241dca2" },
17+
"nvim-web-devicons": { "branch": "master", "commit": "1020869742ecb191f260818234517f4a1515cfe8" },
18+
"oil.nvim": { "branch": "master", "commit": "975a77cce3c8cb742bc1b3629f4328f5ca977dad" },
19+
"quick-scope": { "branch": "master", "commit": "f2b6043e04d9ef05205c8953e389304a4c1946f2" },
20+
"vim-fugitive": { "branch": "master", "commit": "4a745ea72fa93bb15dd077109afbb3d1809383f2" },
2121
"vim-gurl": { "branch": "master", "commit": "de3e14440fa72e0deaa5cf6c02eef91be706d75a" },
2222
"vim-repeat": { "branch": "master", "commit": "65846025c15494983dafe5e3b46c8f88ab2e9635" },
2323
"vim-searchindex": { "branch": "master", "commit": "b0788c8213210b3bd23b62847dd5a9ebbe4ad648" },

0 commit comments

Comments
 (0)