8000 use our two new methods in autoconf script · pythonanywhere/helper_scripts@68d3439 · GitHub
[go: up one dir, main page]

Skip to content

Commit 68d3439

Browse files
committed
< 8000 /div>
use our two new methods in autoconf script
1 parent 2a33c8c commit 68d3439

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

scripts/pa_autoconfigure_django.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
import shutil
2424

2525
from pythonanywhere.django_project import DjangoProject
26+
from pythonanywhere.snakesay import snakesay
2627

2728

2829
def download_repo(repo, domain, nuke):
@@ -47,10 +48,10 @@ def main(repo_url, domain, python_version, nuke):
4748
project.run_collectstatic()
4849
project.create_webapp(nuke=nuke)
4950
project.update_wsgi_file()
50-
# add_static_file_mappings(domain, project_path)
51-
# reload_webapp(domain)
51+
project.add_static_file_mappings()
52+
project.webapp.reload()
5253

53-
# print(snakesay(f'All done! Your site is now live at https://{domain}'))
54+
print(snakesay(f'All done! Your site is now live at https://{domain}'))
5455

5556

5657

tests/test_pa_autoconfigure_django.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,8 @@ def test_calls_all_stuff_in_right_order(self, mock_main_functions):
4747
call.run_collectstatic(),
4848
call.create_webapp(nuke='nuke option'),
4949
call.update_wsgi_file(),
50+
call.add_static_file_mappings(),
51+
call.webapp.reload()
5052
]
5153

5254

0 commit comments

Comments
 (0)
0