Skip to content

Commit 98d9192

Browse files
committed
better work command
1 parent e00f95a commit 98d9192

File tree

3 files changed

+18
-3
lines changed

3 files changed

+18
-3
lines changed

bin/gitclone

+1
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,4 @@ fi
1111

1212
git clone $1 $out
1313

14+
cd $out

dot/bash_aliases

+13-2
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@ alias ggl='fzf_log'
2828

2929
alias cg='cd $(git rev-parse --show-toplevel)'
3030

31+
alias egd='vim $(git diff --name-only)'
32+
3133
# Annoying mac uses different ls
3234
if [[ $(uname -s) == Linux ]]
3335
then
@@ -283,17 +285,26 @@ extract () {
283285
fi
284286
}
285287

288+
use_python_env()
289+
{
290+
# Better test what kind of env this is
291+
test -f ./env/bin/activate && source ./env/bin/activate || cona
292+
}
293+
286294
work()
287295
{
288296
# Activate node and activate python env
289297
nvm use node
290-
test -d ./env && cona
298+
test -d ./env && use_python_env ./env
291299
test -f .venv/bin/activate && source .venv/bin/activate
300+
test -f venv/bin/activate && source venv/bin/activate
292301
}
293302

294-
dework(){
303+
dework()
304+
{
295305
nvm deactivate
296306
conda deactivate
307+
deactivate
297308
}
298309

299310
# Get code snippets

dot/tmux.conf

+4-1
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,9 @@ bind d detach
126126
# bind-key -n C-Tab next-window
127127
# bind-key -n C-S-Tab previous-window
128128

129+
# Copy vbuf to terminal clipboard
130+
# bind x command-prompt "cat ~/.vbuf | yank"
131+
129132
# write in all panes at once
130133
bind x set-window-option synchronize-panes
131134

@@ -333,7 +336,7 @@ set -g @plugin 'tmux-plugins/tmux-copycat'
333336
# y - copy selection to system clipboard
334337
# Y (shift-y) - "put" selection - equivalent to copying a selection, and pasting it to the command line
335338
# Alt-y - performs both of the above: copy to system clipboard and put to command line (deprecated, not useful)
336-
set -g @plugin 'tmux-plugins/tmux-yank'
339+
# set -g @plugin 'tmux-plugins/tmux-yank'
337340

338341
# https://sunaku.github.io/tmux-yank-osc52.html
339342
# transfer copied text to attached terminal with yank

0 commit comments

Comments
 (0)