发版脚本版本tag改读package.json,消除v1.0.0与README v1.0.1漂移
This commit is contained in:
1 parent
f2ac228849
commit
9f99325936
1 file changed
+3
-2
@@ -8,11 +8,12 @@
|
||||
# 即可拉取(拉取是 GET 响应,不受请求体积限制影响)。
|
||||
#
|
||||
# 用法:bash scripts/push_registry.sh [镜像:tag] [版本tag]
|
||||
# 默认:unicut-src-unicut:latest → :latest + :v1.0.0
|
||||
# 默认:unicut-src-unicut:latest → :latest + :v<package.json 版本>
|
||||
set -euo pipefail
|
||||
|
||||
IMG="${1:-unicut-src-unicut:latest}"
|
||||
VERSION_TAG="${2:-v1.0.0}"
|
||||
DEFAULT_VER="v$(grep -oP '"version":\s*"\K[^"]+' package.json | head -1)"
|
||||
VERSION_TAG="${2:-${DEFAULT_VER:-v1.0.0}}"
|
||||
REG="192.168.68.19:3200" # 内网 Gitea(绕开公网 nginx)
|
||||
OWNER="jinghui"
|
||||
PKG="unicut"
|
||||
|
||||
Reference in new issue
Block a user