Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
energy
bmon
Commits
6fa403ee
Commit
6fa403ee
authored
Apr 06, 2017
by
Alan Mitchell
Browse files
Needed to be in Correct Directory for Git command.
parent
a44ec691
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletion
+3
-1
bmsapp/view_util.py
bmsapp/view_util.py
+3
-1
No files found.
bmsapp/view_util.py
View file @
6fa403ee
...
...
@@ -2,6 +2,7 @@
Helper functions for the views in this BMS application.
'''
import
importlib
import
os
from
subprocess
import
check_output
from
django.template
import
loader
from
django.templatetags.static
import
static
...
...
@@ -321,7 +322,8 @@ def version_date_string():
"""
ver_date
=
''
try
:
result
=
check_output
([
'git'
,
'log'
,
'-n1'
])
dir_git
=
os
.
path
.
dirname
(
__file__
)
result
=
check_output
(
'cd %s; git log -n1'
%
dir_git
,
shell
=
True
)
for
lin
in
result
.
splitlines
():
if
lin
.
startswith
(
'Date:'
):
ver_date
=
lin
[
5
:].
strip
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment