mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Removed leading blanks
This commit is contained in:
parent
6a18075640
commit
bfed87df80
1 changed files with 2 additions and 2 deletions
|
@ -307,10 +307,10 @@ def _gitinfo():
|
||||||
branch = f.readline().split('/')[-1].rstrip("\n")
|
branch = f.readline().split('/')[-1].rstrip("\n")
|
||||||
branch_path = os.path.join(repo_path, "refs", "heads", branch)
|
branch_path = os.path.join(repo_path, "refs", "heads", branch)
|
||||||
with open(branch_path) as f:
|
with open(branch_path) as f:
|
||||||
commit = f.readline()[:10]
|
commit = f.readline()[:10]
|
||||||
date = time.localtime(os.stat(branch_path).st_mtime)
|
date = time.localtime(os.stat(branch_path).st_mtime)
|
||||||
offset = time.timezone if (time.daylight == 0) else time.altzone
|
offset = time.timezone if (time.daylight == 0) else time.altzone
|
||||||
result = "({0} {1}) last updated {2} (GMT {3:+04d})".format(branch, commit,
|
result = "({0} {1}) last updated {2} (GMT {3:+04d})".format(branch, commit,
|
||||||
time.strftime("%Y/%m/%d %H:%M:%S", date), offset / -36)
|
time.strftime("%Y/%m/%d %H:%M:%S", date), offset / -36)
|
||||||
return result
|
return result
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue