My personal website, available at aku.ren
After cloning this repo, run these commands to install the venv
python -m venv venv
. venv/bin/activate
pip install -r requirements.txt
You should probably also run the CV submodule to populate the publications and CV pages
cd CV
make pdf
make html
make clean
cd ..
And create the pdf directories
mkdir static/pdfs
mkdir static/pdfs/{papers,slides}
For an apache2 server on debian, mod_wsgi is required.
The VirtualHost must be setup to use a WSGI Daemon, and that daemon must use
the previously created venv, and point to ./app.wsgi
Then, edit ./app.wsgi
and change the path and secret key.
flask shell
from app import *
db.drop_all()
db.create_all()
Use this when the database structure was changed
flask db migrate -m "<Migration message>"
And this to apply the changes
flask db upgrade
flask shell
from app import *
cookie = Algo(name="ccgarden", short_title="Cookie Clicker Garden", title="Maximal number of unmarked cells with at least 3 marked neighboring cells in the n X n kings' graph", content='''{{ code('cookie.py') }}
<p>
Time complexity: \(O(m 2^{3n})\)<br />
There is a solution in \(O(nm 2^{2n+3})\)
The resulting sequences for \(N\\times N\) grids and \(N\\times(N+1)\) grids can be found at ??? and ???
</p>''')
db.session.add(cookie)
db.session.commit()
flask run