improved todo
alias by changing it into a function
This commit is contained in:
parent
6f2a76ffdf
commit
c322f4899f
1 changed files with 8 additions and 2 deletions
10
.zshrc
10
.zshrc
|
@ -1,7 +1,7 @@
|
||||||
#!/bin/zsh
|
#!/bin/zsh
|
||||||
# Blake's ZSH config file
|
# Blake's ZSH config file
|
||||||
|
|
||||||
# vim:fdm=marker:fmr=>>>,<<<:expandtab:sw=3
|
# vim:fdm=marker:fmr=>>>,<<<:et:ft=zsh:sw=3
|
||||||
|
|
||||||
### Basic shell configuration >>>
|
### Basic shell configuration >>>
|
||||||
### Environment variables >>>
|
### Environment variables >>>
|
||||||
|
@ -87,7 +87,6 @@
|
||||||
alias \
|
alias \
|
||||||
nvc="(cd ~/.config/nvim && nvim)" \
|
nvc="(cd ~/.config/nvim && nvim)" \
|
||||||
zshrc="$EDITOR ~/.zshrc" \
|
zshrc="$EDITOR ~/.zshrc" \
|
||||||
todo="$EDITOR ~/todo" \
|
|
||||||
fstab="sudo $EDITOR /etc/fstab" \
|
fstab="sudo $EDITOR /etc/fstab" \
|
||||||
|
|
||||||
# Git cLONE
|
# Git cLONE
|
||||||
|
@ -157,6 +156,13 @@
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# an improved way to manage the todo list
|
||||||
|
todo() {
|
||||||
|
cd "$(dirname "$(realpath ~/todo)")"
|
||||||
|
test -d .git || git rev-parse --git-dir > /dev/null 2>&1 && echo 'pulling repository' && git pull
|
||||||
|
"$EDITOR" ~/todo
|
||||||
|
}
|
||||||
|
|
||||||
# Simple extraction script. Taken from manjaro's .bashrc
|
# Simple extraction script. Taken from manjaro's .bashrc
|
||||||
ex() {
|
ex() {
|
||||||
if [ -f $1 ] ; then
|
if [ -f $1 ] ; then
|
||||||
|
|
Loading…
Add table
Reference in a new issue