Removed extra global defs and added chmod

This commit is contained in:
lfield 2018-10-26 15:29:02 +02:00
parent 237375a6b9
commit 3d7281d21c
2 changed files with 3 additions and 6 deletions

View File

@ -186,9 +186,6 @@ function show_status_html($x) {
}
end_table();
global $server_version;
global $git_commit;
if ( isset($server_version) && isset($git_commit) ) {
echo "Server version: $server_version (<a href=https://github.com/BOINC/boinc/commit/$git_commit>$git_commit)</a>)<br>";
}

View File

@ -353,14 +353,14 @@ def install_boinc_files(dest_dir, install_web_files, install_server_files):
content = '''<?php
global $git_commit;
global $server_version;
$git_commit = {commit}
$server_version = {version}
$git_commit = "{commit}";
$server_version = "{version}";
\?>
'''.format(commit=commit, version=version)
f = open(os.path.join(dest_dir, 'release.inc'), 'w')
f.write(content)
f.close()
os.chmod(os.path.join(dest_dir, 'release.inc'), 0o644)
except Exception, e:
print 'Not running from git source, no version or commit detected.'