mirror of
https://github.com/GNS3/gns3-registry.git
synced 2024-12-18 20:37:57 +00:00
Docker build: Include time of pull request to calculation of change time
This commit is contained in:
parent
8ce745ad14
commit
32538f7d1f
5
.github/bin/docker_build
vendored
5
.github/bin/docker_build
vendored
@ -62,9 +62,9 @@ import re
|
|||||||
import shlex
|
import shlex
|
||||||
import subprocess
|
import subprocess
|
||||||
import time
|
import time
|
||||||
|
import dateutil.parser
|
||||||
import dxf
|
import dxf
|
||||||
import requests.exceptions
|
import requests.exceptions
|
||||||
import dateutil.parser
|
|
||||||
|
|
||||||
docker_login = {}
|
docker_login = {}
|
||||||
image_info = {}
|
image_info = {}
|
||||||
@ -379,7 +379,8 @@ def needs_rebuild(image, default_repository=None):
|
|||||||
rebuild_reason = "Files in docker context more recent than image"
|
rebuild_reason = "Files in docker context more recent than image"
|
||||||
else:
|
else:
|
||||||
# clean git repository: use "git log" to get commit time
|
# clean git repository: use "git log" to get commit time
|
||||||
proc = subprocess.run(["git", "-C", image["dir"], "log", "-n", "1",
|
proc = subprocess.run(["git", "-C", image["dir"], "log",
|
||||||
|
"--show-pulls", "-n", "1",
|
||||||
"--pretty=tformat:%ct", "--", "."],
|
"--pretty=tformat:%ct", "--", "."],
|
||||||
capture_output=True,
|
capture_output=True,
|
||||||
check=True,
|
check=True,
|
||||||
|
Loading…
Reference in New Issue
Block a user