From: Petr Štetiar Date: Mon, 14 Sep 2020 06:06:25 +0000 (+0200) Subject: ci: populate GIT_VERSION variable in index.html X-Git-Tag: v3.0.0 X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=a68c3973b8c7fb6d13bfe774928eb8d936344f45;p=web%2Ffirmware-selector-openwrt-org.git ci: populate GIT_VERSION variable in index.html Signed-off-by: Petr Štetiar --- diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index fdbe77d..a9537fb 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -52,7 +52,7 @@ build site on Python 3.8: stage: pre-build image: debian:9 before_script: - - apt-get update; apt-get install -y make python3 ca-certificates + - apt-get update; apt-get install -y make python3 ca-certificates git artifacts: expire_in: 1 week when: always @@ -63,12 +63,14 @@ build site for target environment using scrape method: extends: .build site script: - cp -R ./www ./build + - sed -i "s;%GIT_VERSION%;$(git describe --tags);" build/index.html - misc/collect.py scrape https://downloads.openwrt.org build build site for target environment using scan method: extends: .build site script: - cp -R ./www ./build + - sed -i "s;%GIT_VERSION%;$(git describe --tags);" build/index.html - misc/collect.py scan downloads.openwrt.org tests/profiles build .test site: