mirror of
https://github.com/cookiecutter/cookiecutter-django.git
synced 2025-08-09 06:24:52 +03:00
Removing ignored files
This commit is contained in:
parent
a0ad76d988
commit
5e1ef3fb51
27
{{cookiecutter.project_slug}}/sc/create_db.sh
Executable file
27
{{cookiecutter.project_slug}}/sc/create_db.sh
Executable file
|
@ -0,0 +1,27 @@
|
||||||
|
echo 'Creating Database {{cookiecutter.project_slug}}:'
|
||||||
|
sudo -u postgres psql --command 'CREATE DATABASE {{cookiecutter.project_slug}};'
|
||||||
|
|
||||||
|
echo
|
||||||
|
|
||||||
|
echo 'Creating DB user {{cookiecutter.project_slug}}_user with password {{cookiecutter.database_user_password}}'
|
||||||
|
sudo -u postgres psql --command 'CREATE USER {{cookiecutter.project_slug}}_user WITH PASSWORD '\'{{cookiecutter.database_user_password}}\';
|
||||||
|
|
||||||
|
echo
|
||||||
|
|
||||||
|
echo 'Altering role to utf8'
|
||||||
|
sudo -u postgres psql --command 'ALTER ROLE {{cookiecutter.project_slug}}_user SET client_encoding TO '\'utf8\';
|
||||||
|
|
||||||
|
echo
|
||||||
|
|
||||||
|
echo 'setting default_transaction_isolation TO read committed'
|
||||||
|
sudo -u postgres psql --command 'ALTER ROLE {{cookiecutter.project_slug}}_user SET default_transaction_isolation TO '\'read\ committed\';
|
||||||
|
|
||||||
|
echo
|
||||||
|
|
||||||
|
echo 'setting timezone to {{cookiecutter.timezone}}'
|
||||||
|
sudo -u postgres psql --command 'ALTER ROLE {{cookiecutter.project_slug}}_user SET timezone TO '\'{{cookiecutter.timezone}}\';
|
||||||
|
|
||||||
|
echo
|
||||||
|
|
||||||
|
echo 'Granting all privileges on Database {{cookiecutter.project_slug}} to {{cookiecutter.project_slug}}_user;'
|
||||||
|
sudo -u postgres psql --command 'GRANT ALL PRIVILEGES ON DATABASE {{cookiecutter.project_slug}} TO {{cookiecutter.project_slug}}_user;'
|
4
{{cookiecutter.project_slug}}/sc/git_clean_cache.sh
Executable file
4
{{cookiecutter.project_slug}}/sc/git_clean_cache.sh
Executable file
|
@ -0,0 +1,4 @@
|
||||||
|
git rm -r --cached .
|
||||||
|
git add -A
|
||||||
|
git commit -am 'Removing ignored files'
|
||||||
|
git push
|
5
{{cookiecutter.project_slug}}/sc/git_create_repo.sh
Normal file
5
{{cookiecutter.project_slug}}/sc/git_create_repo.sh
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
git init
|
||||||
|
git add .
|
||||||
|
git commit -m "first {{cookiecutter.project_slug}} commit"
|
||||||
|
git remote add origin git@bitbucket.org:myvault/{{cookiecutter.project_slug}}.git
|
||||||
|
git push -u origin master
|
2
{{cookiecutter.project_slug}}/sc/venv_create.sh
Executable file
2
{{cookiecutter.project_slug}}/sc/venv_create.sh
Executable file
|
@ -0,0 +1,2 @@
|
||||||
|
#!/bin/bash
|
||||||
|
virtualenv -p python3 ../venv/{{cookiecutter.venv_name}}
|
Loading…
Reference in New Issue
Block a user