Compare commits

..
10 Commits
Author SHA1 Message Date
tgrosinger b183a97a56 Fish: Add config to set JAVA_HOME in distrobox 2026-07-24 09:38:41 -07:00
tgrosinger 8e55eae23e Fish: Add del-wt function 2026-07-24 09:38:24 -07:00
tgrosinger 774df0b7a8 Fish: Show distrobox container name in prompt 2026-07-24 09:38:10 -07:00
tgrosinger 2113743644 Fish: Prevent Atuin from loading when unavailable
This fixes an issue when entering distrobox containers.
2026-07-24 09:37:50 -07:00
tgrosinger 932f4f7f2e Claude: Remove unused functionality from system prompt 2026-07-24 09:37:10 -07:00
tgrosinger c463fff8e4 Claude: Add blocks on file deletion commands 2026-07-24 09:36:15 -07:00
tgrosinger c9e82e5756 Fish: Improve dev-wt-pr completions and required args
The branch name can now be omitted and will be looked up if not
provided. This makes it much easier to run this script manually from the
CLI.
2026-07-24 09:36:13 -07:00
tgrosinger 46431d0532 Mouseless: Install 2026-07-24 09:36:11 -07:00
tgrosinger d8997c8df8 Neeovim: Disable persistence plugin
This plugin was causing problems with worktrees, and I didn't really
like the functionality anyway. It was added when I was having trouble
with my computer crashing a bunch, but that issue seems to be occurring
less often now.
2026-07-24 09:36:09 -07:00
tgrosinger 39329e2607 Fish: Add alias for common typo 2026-07-24 09:36:06 -07:00
10 changed files with 76 additions and 5 deletions
+20 -1
View File
@@ -17,7 +17,19 @@
"Bash(git push *)",
"Bash(ssh *)",
"Bash(ssh)",
"Bash(scp *)"
"Bash(scp *)",
"Bash(rm:*)",
"Bash(unlink:*)",
"Bash(rmdir:*)",
"Bash(shred:*)",
"Bash(truncate:*)",
"Bash(trash:*)",
"CronCreate",
"CronDelete",
"CronList",
"PushNotification",
"NotebookEdit",
"DesignSync"
],
"defaultMode": "auto"
},
@@ -29,6 +41,10 @@
{
"type": "command",
"command": "~/.claude/hooks/block-dangerous-git.sh"
},
{
"type": "command",
"command": "~/.claude/hooks/block-file-deletion.sh"
}
]
}
@@ -103,5 +119,8 @@
"theme": "light",
"editorMode": "vim",
"agentPushNotifEnabled": true,
"disableClaudeAiConnectors": true,
"disableWorkflows": true,
"disableArtifact": true,
"skipAutoPermissionPrompt": true
}
@@ -0,0 +1,16 @@
function __dev_wt_pr_numbers
# Open PRs in the current repo: number<TAB>title. gh resolves the repo from
# the remote, so this only yields anything inside a GitHub checkout.
gh pr list --json number,title --jq '.[] | "\(.number)\t\(.title)"' 2>/dev/null
end
function __dev_wt_pr_branch
# Second arg is the branch; default to the head branch of the PR already typed.
set -l tokens (commandline -opc)
test (count $tokens) -ge 2; or return
gh pr view $tokens[2] --json headRefName --jq .headRefName 2>/dev/null
end
complete -c dev-wt-pr -f -n __fish_is_first_arg -a '(__dev_wt_pr_numbers)'
complete -c dev-wt-pr -f -n 'test (count (commandline -opc)) -eq 2' -a '(__dev_wt_pr_branch)'
complete -c dev-wt-pr -n 'test (count (commandline -opc)) -eq 3' -a '(__fish_complete_directories)' -d 'Repo path'
+6
View File
@@ -0,0 +1,6 @@
# Gradle needs a JDK it can actually run on. Fedora 43's default is JDK 25,
# which Gradle 8.13 rejects with "Unsupported class file major version 69".
# $HOME is shared with the host, so scope this to the distrobox via CONTAINER_ID.
if set -q CONTAINER_ID; and test -x /usr/lib/jvm/java-21-openjdk/bin/javac
set -gx JAVA_HOME /usr/lib/jvm/java-21-openjdk
end
+2 -1
View File
@@ -12,7 +12,7 @@ if status is-interactive
if test -f /home/linuxbrew/.linuxbrew/bin/brew
/home/linuxbrew/.linuxbrew/bin/brew shellenv | source
end
if test -f $(which atuin)
if command -q atuin
atuin init fish | source
end
@@ -24,6 +24,7 @@ if status is-interactive
alias lg="lazygit"
alias la="eza --long --header --git --group --time-style long-iso -a"
alias record='wf-recorder -g "$(slurp)"'
alias claer="clear"
# Set a location to store variables that should not be tracked in git.
if test -f ~/.local/fish_env.fish
+6
View File
@@ -0,0 +1,6 @@
function del-wt -d "Remove current git worktree and cd into the main worktree"
set -l main_wt (git worktree list --porcelain | head -1 | string replace "worktree " "")
set -l current (git rev-parse --show-toplevel 2>/dev/null)
cd "$main_wt"; or return 1
git worktree remove "$current" # git handles dirty/main-worktree guards itself
end
+7 -1
View File
@@ -1,6 +1,6 @@
function dev-wt-pr -d "Open a GitHub PR in a worktree in a new tmux window (Octo review + Claude)" -a pr_number branch repo_path
if test -z "$pr_number"
echo "Usage: dev-wt-pr <pr-number> <branch> [repo-path]"
echo "Usage: dev-wt-pr <pr-number> [branch] [repo-path]"
return 1
end
@@ -22,6 +22,12 @@ function dev-wt-pr -d "Open a GitHub PR in a worktree in a new tmux window (Octo
return 1
end
# gh-dash passes the branch to save a lookup; manual callers can omit it and
# we resolve it from the PR number here.
if test -z "$branch"
set branch (gh pr view $pr_number --json headRefName --jq .headRefName 2>/dev/null)
end
set -l main_wt_path (git worktree list --porcelain | head -1 | string replace "worktree " "")
set -l parent_dir (dirname "$main_wt_path")
# Key the worktree on the PR number to stay unique and avoid slashes in
+8 -1
View File
@@ -6,6 +6,7 @@ function fish_prompt
set -l red (set_color -o red)
set -l green (set_color -o green)
set -l blue (set_color -o blue)
set -l magenta (set_color -o magenta)
set -l normal (set_color normal)
set -l arrow_color "$green"
@@ -20,5 +21,11 @@ function fish_prompt
set -l cwd $cyan(prompt_pwd | path basename)
echo -n -s $arrow ' '$cwd $repo_info $normal ' '
# distrobox exports CONTAINER_ID inside the container
set -l box ""
if set -q CONTAINER_ID
set box $magenta"📦$CONTAINER_ID "
end
echo -n -s $arrow ' ' $box $cwd $repo_info $normal ' '
end
+1 -1
View File
@@ -18,7 +18,7 @@ pnpm = "latest"
"npm:@anthropic-ai/sandbox-runtime" = "latest"
"npm:typescript-language-server" = "latest"
"npm:typescript" = "latest"
"github:Satty-org/Satty" = "0.21.1"
"github:Satty-org/Satty" = "0.20.1"
"github:DarthSim/overmind" = "latest"
"github:F1bonacc1/process-compose" = "latest"
"github:modem-dev/hunk" = "latest"
@@ -1,5 +1,12 @@
-- Disabled: broke git worktrees. On launch with no file arg, the VimEnter
-- autoload restored a session whose buffers belonged to another worktree (the
-- crash-save autocmd had written them in). The stale buffer became current, and
-- since snacks-explorer, LazyVim.root(), and diffview are all current-buffer
-- relative, they all followed it to the wrong worktree/branch even though :pwd
-- was correct. Re-enable only with per-worktree session isolation.
return {
"folke/persistence.nvim",
enabled = false,
init = function()
vim.api.nvim_create_autocmd("VimEnter", {
group = vim.api.nvim_create_augroup("PersistenceAutoload", { clear = true }),
+3
View File
@@ -91,6 +91,9 @@ flatpak install flathub org.kde.skanpage
flatpak install flathub org.libreoffice.LibreOffice
flatpak install flathub org.musicbrainz.Picard
flatpak remote-add --user --if-not-exists sonuscape https://dl.sonuscape.net/flatpak/sonuscape.flatpakrepo
flatpak install net.sonuscape.mouseless//preview
# Install devbox
# https://www.jetify.com/docs/devbox/installing-devbox
curl -fsSL https://get.jetify.com/devbox | bash