Skip to content

Commit

Permalink
Tweak formatting of run script
Browse files Browse the repository at this point in the history
  • Loading branch information
philgyford committed Nov 18, 2021
1 parent d8c4da7 commit e4b7cb2
Showing 1 changed file with 16 additions and 5 deletions.
21 changes: 16 additions & 5 deletions run
Original file line number Diff line number Diff line change
Expand Up @@ -37,31 +37,28 @@ function cmd {
_dc web "${@}"
}


function sh {
# Start a Shell session in the web container
cmd sh "${@}"
}


function manage {
# Run any manage.py commands

cmd pipenv run python manage.py "${@}"
}




function tests {
# Run the Django tests

manage collectstatic --settings=config.settings.tests --no-input
manage test --settings=config.settings.tests "${@}"
}


function coverage {
# Run the tests and generate a coverage report in htmlcov/

manage collectstatic --settings=config.settings.tests --no-input
cmd pipenv run coverage run manage.py test --settings=config.settings.tests tests
cmd pipenv run coverage html
Expand Down Expand Up @@ -106,6 +103,13 @@ function pipenv:update {
}


# function pipenv:install {
# # Install pip3 dependencies and write lock file
# # (untested)
# _build_run_down web sh -c "pipenv install"
# }


function yarn:outdated {
# List any installed yarn packages that are outdated
_dc yarn outdated
Expand All @@ -118,6 +122,13 @@ function yarn:upgrade {
}


# function yarn:install {
# # Install yarn dependencies and write lock file
# # (untested)
# _build_run_down webpack yarn install
# }


function help {
printf "%s <task> [args]\n\nTasks:\n" "${0}"

Expand Down

0 comments on commit e4b7cb2

Please sign in to comment.