summaryrefslogtreecommitdiff
path: root/.bashrc
diff options
context:
space:
mode:
authorMarc Vertes <mvertes@free.fr>2022-02-03 14:39:21 +0100
committerMarc Vertes <mvertes@free.fr>2022-02-03 14:39:21 +0100
commit70375b4962152133c0423115427d7eaa006822d6 (patch)
treed5608c6638f202ff17566fce60b5460da1d26304 /.bashrc
parent053556962bb2d29ac76bcca51cabd1df238f80e3 (diff)
parente200c8d78ca1d3388c25c1cef8892b1dd015bbf7 (diff)
update
Diffstat (limited to '.bashrc')
-rw-r--r--.bashrc64
1 files changed, 37 insertions, 27 deletions
diff --git a/.bashrc b/.bashrc
index 642c6d7..00fdd0a 100644
--- a/.bashrc
+++ b/.bashrc
@@ -32,7 +32,8 @@ fixab() { printf "\x1f\x8b\x08\x00\x00\x00\x00\x00" ; tail -c +25 "$1"; }
#export LESS_TERMCAP_us=$(tput setaf 5) # underline (magenta)
#export LESS_TERMCAP_ue=$'\E[0m' # end underline
-export BACKUP=bip:/home/backup/marc@yoda
+export BACKUP=bip:/home/backup/marc@$(hostname -s)
+export LESS=Rx4
# gnuplot display in terminal
export GNUTERM='sixelgd enhanced truecolor font "arial,9"'
@@ -49,47 +50,52 @@ alias ll='ls -AlFhv'
alias more='less'
alias vi='vim'
alias view='vim -R'
+alias ldd='otool -L'
+alias ibrew='arch -x86_64 /usr/local/bin/brew'
#alias op='xdg-open'
#alias git='hub'
#alias go='go1.14.1'
-alias go11='go1.11.13'
-alias go12='go1.12.10'
-alias go13='go1.13.8'
-alias go14='go1.14.2'
+#alias go11='go1.11.13'
+#alias go12='go1.12.10'
+#alias go13='go1.13.8'
+#alias go14='go1.14.2'
alias gob='go build'
alias goh='p go help'
alias god='p go doc'
+alias gol='GO111MODULE=off go'
alias gtr='go test -v -run'
alias gtb='go test -v -cpuprofile cpu.out -memprofile mem.out -benchmem -bench'
alias kd='sudo cat /sys/kernel/debug/tracing/trace_pipe'
-#alias vi='vim'
+
alias rvi='sudo vim'
alias rxt='sudo xt'
alias rxvi='sudo xvi'
-alias ww='vi ~/Wiki/HomePage'
+alias ww='vi ~/Wiki/home_page.md'
alias dotfiles='git --git-dir=$HOME/dotfiles --work-tree=$HOME'
-alias uc='systemctl --user'
-alias wpa='sudo wpa_gui -i wlan0'
+#alias uc='systemctl --user'
+#alias wpa='sudo wpa_gui -i wlan0'
-alias ifre='echo "ip link set wlo1 down; ip link set wlo1 up"|sudo sh'
+#alias ifre='echo "ip link set wlo1 down; ip link set wlo1 up"|sudo sh'
# Some admin command
-alias dmesg='sudo dmesg'
-alias mount='sudo mount'
-alias umount='sudo umount'
-alias cryptsetup='sudo cryptsetup'
+#alias dmesg='sudo dmesg'
+#alias mount='sudo mount'
+#alias umount='sudo umount'
+#alias cryptsetup='sudo cryptsetup'
alias by='go build ./cmd/yaegi'
alias cy='cd ~/go/src/github.com/traefik/yaegi'
#alias ty='go test -v -short ./interp'
-alias ya='rlwrap -pblue yaegi'
-alias dya='YAEGI_AST_DOT=1 YAEGI_CFG_DOT=1 ./yaegi'
+alias y='rlwrap -pblue yaegi'
+alias dy='YAEGI_AST_DOT=1 YAEGI_CFG_DOT=1 ./yaegi'
alias wai='~/go/src/github.co/traefik/whoami/whoami'
# yaegi debug
export YAEGI_DOT_CMD='dotty -'
-export YAEGI_BPF=1 YAEGI_UNSAFE=1 YAEGI_SYSCALL=1 YAEGI_UNRESTRICTED=1
+export YAEGI_UNSAFE=1
+export YAEGI_UNRESTRICTED=1
+export YAEGI_SYSCALL=1
mosht() { mosh "$@" -- tmux new -A; }
export -f mosht
@@ -112,29 +118,33 @@ export -f ws
wsd() (cd ~/Wiki && git add . && git diff --cached)
export -f wsd
+man() {
+ local width=''
+ [ $(tput cols) -gt 88 ] && width='MANWIDTH=88'
+ env $width man "$@"
+}
+
meteo() {
local request="wttr.in/${1-Toulouse}?F&T"
[ "$(tput cols)" -lt 125 ] && request+='&n'
- curl -H "Accept-Language: ${LANG%_*}" --compressed "$request"
+ curl -H "Accept-Language: fr" --compressed "$request"
}
#PS1='[\u@\h \W]\$ '
# fzf
+[ -f ~/.fzf.bash ] && source ~/.fzf.bash
# Accomodate different base prefix on termux
-[ -d "$HOME/../usr" ] && base=..
-[ -f "$base/usr/share/fzf/completion.bash" ] && . "$base/usr/share/fzf/completion.bash"
-[ -f "$base/usr/share/fzf/key-bindings.bash" ] && . "$base/usr/share/fzf/key-bindings.bash"
-unset base
+#[ -d "$HOME/../usr" ] && base=..
+#[ -f "$base/usr/share/fzf/completion.bash" ] && . "$base/usr/share/fzf/completion.bash"
+#[ -f "$base/usr/share/fzf/key-bindings.bash" ] && . "$base/usr/share/fzf/key-bindings.bash"
+#unset base
# Arch: display package to install for missing commands
-[ -f '/usr/share/doc/pkgfile/command-not-found.bash' ] && . /usr/share/doc/pkgfile/command-not-found.bash
+#[ -f '/usr/share/doc/pkgfile/command-not-found.bash' ] && . /usr/share/doc/pkgfile/command-not-found.bash
# Display git status in prompt
. ~/.bash-powerline.sh
-# export PS1='; '
-# load Nix config files (aka auto-completion etc.)
-#export XDG_DATA_DIRS="$HOME/.nix-profile/share:${XDG_DATA_DIRS:-/usr/local/share:/usr/share}"
-
eval "$(direnv hook bash)"
+#export GITHUB_TOKEN=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