Skip to content

Commit

Permalink
Merge pull request #8 from TeamSuman/django
Browse files Browse the repository at this point in the history
Django
  • Loading branch information
dmighty007 authored Oct 7, 2024
2 parents 80e700f + 676485d commit f021480
Show file tree
Hide file tree
Showing 4 changed files with 43 additions and 31 deletions.
2 changes: 1 addition & 1 deletion contacts.html
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ <h3 class="mb-2">Send us a message</h3>
</p>
<div class="form">
<form id="my-form" method="POST" role="form" class="contactForm" novalidate="novalidate">
<input type="hidden" name="csrfmiddlewaretoken" value="3aupJkL2D56Z9XKfTNlsE4rung8yDA9SOqBA4zJGbYck1Da5YHfd8RAcOW58RWo8">
<input type="hidden" name="csrfmiddlewaretoken" value="tRwUnJowwQrawoWWPyHIS2WuuwjkjmZgAa8t0CKO8rAfHcXUu4mc7BqW5Qpe6BB7">
<div class="row g-3">
<div class="col-md-6">
<div class="form-floating">
Expand Down
Binary file modified home/__pycache__/views.cpython-312.pyc
Binary file not shown.
2 changes: 1 addition & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -576,7 +576,7 @@ <h1 class="text-white mb-4">Send us a message</h1>

<form id="my-form" method="POST" role="form"
class="contactForm" novalidate="novalidate">
<input type="hidden" name="csrfmiddlewaretoken" value="qcTpZuHrIqKdRR3qgyAFoZK8UEU2TiUujuEE6P3XG8s45SXU9GZ1P9GIOsKqzS8j">
<input type="hidden" name="csrfmiddlewaretoken" value="47YTWtZlV7vGfpboGOrEgJba26kY4gCcD8Td3fs8E23So58jFAfDusZLgW8KdHUT">
<div class="row g-3">
<div class="col-md-6">
<div class="form-floating">
Expand Down
70 changes: 41 additions & 29 deletions sync.sh
Original file line number Diff line number Diff line change
@@ -1,30 +1,42 @@
#remove the html files
rm *html
# Change sync status in views.py
sed -i "s/sync = False/sync = True/" home/views.py
#making the server up
nohup python manage.py runserver &
# Render the pages and save them
content=`wget -O - http://127.0.0.1:8000/`
wait
content=`wget -O - http://127.0.0.1:8000/research`
wait
content=`wget -O - http://127.0.0.1:8000/news`
wait
content=`wget -O - http://127.0.0.1:8000/positions`
wait
content=`wget -O - http://127.0.0.1:8000/publication`
wait
content=`wget -O - http://127.0.0.1:8000/gallery`
wait
content=`wget -O - http://127.0.0.1:8000/contacts`
wait
content=`wget -O - http://127.0.0.1:8000/team`
wait
content=`wget -O - http://127.0.0.1:8000/softwares`
wait
#change sync status in views.py
sed -i "s/sync = True/sync = False/" home/views.py
sync ()
{
#remove the html files
rm nohup.out
rm *html
# Change sync status in views.py
sed -i "s/sync = False/sync = True/" home/views.py
#making the server up
nohup python manage.py runserver &
# Render the pages and save them
content=`wget -O - http://127.0.0.1:8000/`
wait
content=`wget -O - http://127.0.0.1:8000/research`
wait
content=`wget -O - http://127.0.0.1:8000/news`
wait
content=`wget -O - http://127.0.0.1:8000/positions`
wait
content=`wget -O - http://127.0.0.1:8000/publication`
wait
content=`wget -O - http://127.0.0.1:8000/gallery`
wait
content=`wget -O - http://127.0.0.1:8000/contacts`
wait
content=`wget -O - http://127.0.0.1:8000/team`
wait
content=`wget -O - http://127.0.0.1:8000/softwares`
wait
#change sync status in views.py
sed -i "s/sync = True/sync = False/" home/views.py

#kill the server
kill -9 $(lsof -t -i:8000)
#kill the server
kill -9 $(lsof -t -i:8000)
}
#export local file to pythonanywhere.com
## rsync -avzhe ssh ./* [email protected]:/home/teamsuman/website/ --exclude "*settings.py"
#import files from pythonanywhere to local repository
## rsync -avzhe ssh [email protected]:/home/teamsuman/website .

# Sync github account after files are synced..
sync
git add . && git commit -m "message" && git push origin django

0 comments on commit f021480

Please sign in to comment.