4 Commits c1ea6ac416 ... c74b5646a6

Autor SHA1 Mensagem Data
  Tom McKenzie c74b5646a6 feat: update ac alias to use staged diff and improved commit message prompt 6 meses atrás
  Tom McKenzie 89a1be6dde To effectively write a concise, imperative-mood git commit message for the given changes, you need to describe the changes made. Since the details of the changes aren't provided, I'll guide you through a general approach to crafting such a commit message. 6 meses atrás
  Tom McKenzie 0a2b2ede7a Configure shell and Git settings for improved functionality. 6 meses atrás
  Tom McKenzie 6faa2371fe ( ͡° ͜ʖ ͡°) 1 ano atrás
6 arquivos alterados com 18 adições e 20 exclusões
  1. 2 0
      .bashrc
  2. 9 18
      .gitconfig
  3. 1 0
      .gitignore_global
  4. 2 0
      .rc.d/aliases.sh
  5. 1 1
      .rc.d/git.sh
  6. 3 1
      .zshrc

+ 2 - 0
.bashrc

@@ -25,3 +25,5 @@ PS1="\[\e[1;32m\]\h:\W \u$\[\e[0m\] "
 # better back-searching
 bind '"\e[A": history-search-backward'
 bind '"\e[B": history-search-forward'
+
+. "$HOME/.cargo/env"

+ 9 - 18
.gitconfig

@@ -27,25 +27,16 @@
 [help]
     autocorrect = 10
 
-
-[merge]
-    tool = vscode
-[mergetool "vscode"]
-    cmd = code --wait --diff $LOCAL $REMOTE
-
-[diff]
-    tool = vscode
-[difftool "vscode"]
-    cmd = code --wait --diff $LOCAL $REMOTE
-
 [alias]
     p = push
     pp = publish
+    s = switch
+    sc = switch create
     rb = pull --rebase
     rbc = rebase --continue
     rba = rebase --abort
-    fancy-log = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(cyan)<%an>%Creset' --abbrev-commit --date=relative
-    branches = for-each-ref --count=10 --sort='-authordate:iso8601' --format=' %(color:green)%(authordate:relative) %09%(color:white)%(objectname:short) %(color:yellow)%(refname:short) %09%(color:white)%(upstream:track) %(contents:subject)' refs/heads --no-merged
+    l = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(cyan)<%an>%Creset' --abbrev-commit --date=relative
+    b = for-each-ref --count=10 --sort='-authordate:iso8601' --format=' %(color:green)%(authordate:relative) %09%(color:white)%(objectname:short) %(color:yellow)%(refname:short) %09%(color:white)%(upstream:track) %(contents:subject)' refs/heads --no-merged
     edit-conflicted = ! git diff --name-only | uniq | xargs $(echo $EDITOR)
     history = log -p --
 	pushf = push --force-with-lease
@@ -58,11 +49,7 @@
 	excludesfile = /Users/tom/.gitignore_global
 	whitespace = tab-in-indent,trailing-space,space-before-tab
 	ignorecase = false
-	editor = vim -c 'startinsert'
-
-[merge]
-	tool = code
-#       conflictstyle = diff3
+# editor = vim -c 'startinsert'
 
 [push]
 	default = upstream
@@ -82,3 +69,7 @@
 	smudge = git-lfs smudge -- %f
 	process = git-lfs filter-process
 	required = true
+
+[include]
+    path = ~/dotfiles/.gitconfig_difftastic
+    condition = command -v difft >/dev/null 2>&1

+ 1 - 0
.gitignore_global

@@ -9,3 +9,4 @@ Icon
 
 .todo
 bak
+_docs

+ 2 - 0
.rc.d/aliases.sh

@@ -84,5 +84,7 @@ checkout() {
   cd "$HOME/repos/$DIR" || return
 }
 
+alias ac="git diff --staged | llm -m openrouter/meta-llama/llama-4-maverick:free -s 'Write a concise, imperative-mood git commit message summarizing these changes. Begin with feat, fix, bug, or chore. No preamble or yapping.' | git commit -F -"
+
 alias pbjson="pbpaste | jq -r"
 alias pbjsons="pbpaste | jq -sRr '@json'"

+ 1 - 1
.rc.d/git.sh

@@ -62,7 +62,6 @@ alias gsb='git status -sb'
 alias gsd='git svn dcommit'
 alias gsi='git submodule init'
 alias gsps='git show --pretty=short --show-signature'
-alias gsr='git svn rebase'
 alias gss='git status -s'
 alias gst='git status'
 alias gsta='git stash save'
@@ -75,4 +74,5 @@ alias gsts='git stash show --text'
 alias gsu='git submodule update'
 
 alias gp='git push'
+alias gpf='git push --force-with-lease'
 alias gpl='git pull'

+ 3 - 1
.zshrc

@@ -21,7 +21,7 @@ fi
 if [[ -n $SSH_CONNECTION ]]; then
   export EDITOR='vim'
 else
-  export EDITOR='code --wait'
+  export EDITOR='zed --wait'
 fi
 
 # The next line updates PATH for the Google Cloud SDK.
@@ -41,3 +41,5 @@ export PATH="$BUN_INSTALL/bin:$PATH"
 
 # zoxide
 if command -v zoxide >/dev/null 2>&1; then eval "$(zoxide init zsh)"; fi
+
+. "$HOME/.cargo/env"