Yoonjunhyeon

자동화 부분 수정 (자동화 미완성...)

#!/bin/bash
cd ../frontend
npm install
npm run build
cd ../backend
. env/bin/activate
pip install -r requirements.txt
rm -rf static
./manage.py collectstatic
rm -rf static/admin
rm -rf static/rest_framework
python manage.py makemigrations
python manage.py migrate
python manage.py runserver 0.0.0.0:8000
\ No newline at end of file
# python vue2djangoTemplate.py (자동화 - 작성예정, 어캐함??ㅠ)
# 현재 vue index를 django template으로 자동화 하는 코드를 작성하지 못하여,
# 수동으로 바꿔야 합니다.
# 이 스크립트를 실행 후에 생기는 static/index.html의
# href, src 링크를 templates/index.html의 href, src로 변경하면 정상적으로 작동합니다.
\ No newline at end of file
......
#!/bin/bash
cd ../frontend
npm install
npm run build
cd ../backend
. env/bin/activate
pip install -r requirements.txt
rm -rf static
./manage.py collectstatic
rm -rf static/admin
rm -rf static/rest_framework
python vue2djangoTemplate.py
\ No newline at end of file
python manage.py makemigrations
python manage.py migrate
python vue2djangoTemplate.py
python manage.py runserver 0.0.0.0:8000
\ No newline at end of file
......
#!/bin/bash
. env/bin/activate
python manage.py migrate
python manage.py runserver 0.0.0.0:8000
\ No newline at end of file
......
......@@ -25,30 +25,4 @@
<script src="{% static '/js/app.a2bbd68a.js' %}"></script>
</body>
</html>
<!DOCTYPE html>
<html lang=en>
<head>
<meta charset=utf-8>
<meta http-equiv=X-UA-Compatible content="IE=edge">
<meta name=viewport content="width=device-width,initial-scale=1">
<link rel=icon href=/favicon.ico>
<title>Profit-Hunter</title>
<link href=/css/app.1dc1d4aa.css rel=preload as=style>
<link href=/css/chunk-vendors.abb36e73.css rel=preload as=style>
<link href=/js/app.a2bbd68a.js rel=preload as=script>
<link href=/js/chunk-vendors.c489da91.js rel=preload as=script>
<link href=/css/chunk-vendors.abb36e73.css rel=stylesheet>
<link href=/css/app.1dc1d4aa.css rel=stylesheet>
</head>
<body><noscript><strong>We're sorry but front doesn't work properly without JavaScript enabled. Please enable it to
continue.</strong></noscript>
<div id=app></div>
<script src=/js/chunk-vendors.c489da91.js></script>
<script src=/js/app.a2bbd68a.js></script>
</body>
</html>
\ No newline at end of file
......
import os
read = open("static/index.html", 'r')
write = open("templates/index.html", 'w')
......