irongit

A combination of vim and bash that I find useful

ghostshell/ghost.sh
64 lines1.4 KBBourne Again Shell (bash)
1touch ~/.ghost/secret.sh
2source ~/.ghost/secret.sh
3if uname -a | grep -q MINGW;then
4 git config --global core.autocrlf true
5 alias python3=python
6 alias Python=python
7else
8 git config --global core.autocrlf input
9 alias python=python3
10fi
11#alias python=python3
12alias Vim='vim ~/.vimrc'
13alias Gvim='vim ~/.ghost/ghost.vimrc'
14alias Gbash='vim ~/.ghost/ghost.sh'
15alias clip=clip.exe
16alias Bash='vim ~/.bashrc'
17alias Source='source ~/.bashrc'
18alias gcom='git add . && git commit -m'
19alias ghook='~/.ghost/ghook/startproject.sh'
20alias venv='python -m venv venv'
21alias Gsecret='vim ~/.ghost/secret.sh'
22function vsource() {
23 local start=`pwd`
24 for i in $(seq 1 5);do
25 if ! source venv/**/activate; then
26 cd ..
27 else
28 cd $start
29 break
30 fi
31 done
32}
33function Gpush() {
34 local start=`pwd`
35 local message=$@
36 cd ~/.ghost
37 gcom "$message"
38 git push -u origin main
39 cd $start
40}
41function Djs() {
42 local start=`pwd`
43 for i in $(seq 1 5);do
44 if test -f manage.py;then
45 python manage.py runserver $1
46 break
47 fi
48 done
49}
50function Dj() {
51 local start=`pwd`
52 for i in $(seq 1 5);do
53 if test -f manage.py;then
54 python manage.py $@
55 break
56 fi
57 done
58}
59function Gupdate() {
60 local start=`pwd`
61 cd ~/.ghost && git pull
62 Source
63 cd $start
64}