improved about page to include BUGs and TODO, still better formatting required,and build date to be handled separate to last commit date
This commit is contained in:
@@ -11,11 +11,12 @@ static/Metadata/*
|
||||
.pa_bin
|
||||
.python
|
||||
__pycache__
|
||||
BUGS
|
||||
README
|
||||
TODO
|
||||
DB_BACKUP
|
||||
db-container
|
||||
.gitignore
|
||||
.dockerignore
|
||||
Dockerfile
|
||||
internal/git-log.txt
|
||||
internal/TODO
|
||||
internal/BUGs
|
||||
|
||||
@@ -21,6 +21,8 @@ EXPOSE 443
|
||||
EXPOSE 55432
|
||||
COPY . .
|
||||
RUN git log -n 15 > ./internal/git-log.txt
|
||||
RUN ln -s /code/TODO /code/internal/TODO
|
||||
RUN ln -s /code/BUGs /code/internal/BUGs
|
||||
RUN rm -rf .git
|
||||
RUN chown mythtv:mythtv /code
|
||||
RUN chown mythtv:mythtv ./static
|
||||
|
||||
2
TODO
2
TODO
@@ -1,4 +1,6 @@
|
||||
## GENERAL
|
||||
* get Dockerfile to timestamp when it ran so Built on in about page is accurate (not the last commit time)
|
||||
|
||||
* after move, instead of back to home page, go to an ammended view of the thumbs to keep moving
|
||||
|
||||
* ignore face should ignore ALL matching faces (re: Declan)
|
||||
|
||||
29
main.py
29
main.py
@@ -172,7 +172,34 @@ def about():
|
||||
|
||||
# add last commit (or fake commit if no file)
|
||||
commits.append(o)
|
||||
return render_template("about.html", commits=commits)
|
||||
|
||||
bugs=[]
|
||||
try:
|
||||
with open( 'internal/BUGs', 'r' ) as fp:
|
||||
can_add=False
|
||||
for l in fp:
|
||||
print(l)
|
||||
if not l.startswith( 'BUG' ):
|
||||
if can_add:
|
||||
b['str']=b['str']+'<br>'+l
|
||||
else:
|
||||
pass
|
||||
else:
|
||||
if can_add:
|
||||
bugs.append(b)
|
||||
b={}
|
||||
b['str']=l
|
||||
can_add=True
|
||||
except FileNotFoundError:
|
||||
b={}
|
||||
b['str']="No BUGs defined - cannot find BUGs file!?"
|
||||
bugs.append(b)
|
||||
try:
|
||||
with open( 'internal/TODO', 'r' ) as fp:
|
||||
todo=fp.read()
|
||||
except FileNotFoundError:
|
||||
todo="No TODOs defined - cannot find TODO file!?"
|
||||
return render_template("about.html", commits=commits, bugs=bugs, todo=todo)
|
||||
|
||||
@app.route('/logout')
|
||||
@login_required
|
||||
|
||||
@@ -12,13 +12,25 @@
|
||||
</div>
|
||||
<h5><b>
|
||||
Recent commits:
|
||||
</b></h4>
|
||||
</b></h5>
|
||||
{% for c in commits %}
|
||||
<dl class="row">
|
||||
<div class="dt col-3 bg-light">{{c.date}}</div>
|
||||
<div class="dd col-9 bg-light">{{c.str}}</div>
|
||||
</dl>
|
||||
{% endfor %}
|
||||
<h5><b>
|
||||
Known Bugs:
|
||||
</b></h5>
|
||||
{% for b in bugs %}
|
||||
<dl class="row bg-light">{{b.str|safe}}</dl>
|
||||
{% endfor %}
|
||||
<h5><b>
|
||||
TODO:
|
||||
</b></h5>
|
||||
<pre>
|
||||
{{todo}}
|
||||
</pre>
|
||||
</div class="container">
|
||||
|
||||
{% endblock main_content %}
|
||||
|
||||
Reference in New Issue
Block a user