add bash func to start django project
This commit is contained in:
parent
82de8a8cd1
commit
a1be3129ad
@ -181,4 +181,17 @@ most-often-commands() {
|
|||||||
# Enable X11Forwarding and disable mux session
|
# Enable X11Forwarding and disable mux session
|
||||||
sshx() {
|
sshx() {
|
||||||
ssh -X -o ControlMaster=no -o ControlPath=none "$@"
|
ssh -X -o ControlMaster=no -o ControlPath=none "$@"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
django_start_project() (
|
||||||
|
set -ue
|
||||||
|
local -r project_name="$1"
|
||||||
|
|
||||||
|
mkdir "$project_name"
|
||||||
|
cd "$project_name"
|
||||||
|
python3 -m virtualenv venv
|
||||||
|
. venv/bin/activate
|
||||||
|
pip install django
|
||||||
|
django-admin startproject core .
|
||||||
|
git init
|
||||||
|
)
|
||||||
Loading…
x
Reference in New Issue
Block a user