更新脚本修改
This commit is contained in:
+11
-1
@@ -29,7 +29,17 @@ LINUX_DIST="$DIR/dist/production-linux-x64-glibc"
|
|||||||
[ -d "$LINUX_DIST" ] || fail "构建产物 $LINUX_DIST 不存在"
|
[ -d "$LINUX_DIST" ] || fail "构建产物 $LINUX_DIST 不存在"
|
||||||
|
|
||||||
echo "[3/5] 生成 tar.gz 和 SHA-256..."
|
echo "[3/5] 生成 tar.gz 和 SHA-256..."
|
||||||
(cd "$LINUX_DIST" && tar --no-xattrs --exclude='.DS_Store' --exclude='node_modules/@img/sharp-darwin-arm64' --exclude='node_modules/@img/sharp-libvips-darwin-arm64' -czf "$STAGE/$PACKAGE_NAME" --owner=0 --group=0 .)
|
# 属主统一为 root:GNU tar 用 --owner/--group,macOS 自带 bsdtar 用 --uid/--gid。
|
||||||
|
if tar --version 2>/dev/null | grep -q 'GNU tar'; then
|
||||||
|
TAR_OWNER_FLAGS=(--owner=0 --group=0)
|
||||||
|
else
|
||||||
|
TAR_OWNER_FLAGS=(--uid 0 --gid 0)
|
||||||
|
fi
|
||||||
|
(cd "$LINUX_DIST" && COPYFILE_DISABLE=1 COPY_EXTENDED_ATTRIBUTES_DISABLE=1 tar --no-xattrs "${TAR_OWNER_FLAGS[@]}" \
|
||||||
|
--exclude='.DS_Store' --exclude='._*' \
|
||||||
|
--exclude='node_modules/@img/sharp-darwin-arm64' --exclude='node_modules/@img/sharp-libvips-darwin-arm64' \
|
||||||
|
-czf "$STAGE/$PACKAGE_NAME" .)
|
||||||
|
tar -tzf "$STAGE/$PACKAGE_NAME" >/dev/null || fail "压缩包校验失败"
|
||||||
(cd "$STAGE" && shasum -a 256 "$PACKAGE_NAME" > "$PACKAGE_NAME.sha256")
|
(cd "$STAGE" && shasum -a 256 "$PACKAGE_NAME" > "$PACKAGE_NAME.sha256")
|
||||||
ls -lh "$STAGE/$PACKAGE_NAME" "$STAGE/$PACKAGE_NAME.sha256"
|
ls -lh "$STAGE/$PACKAGE_NAME" "$STAGE/$PACKAGE_NAME.sha256"
|
||||||
|
|
||||||
|
|||||||
Vendored
+2
-2
@@ -1,7 +1,7 @@
|
|||||||
/// <reference types="next" />
|
/// <reference types="next" />
|
||||||
/// <reference types="next/image-types/global" />
|
/// <reference types="next/image-types/global" />
|
||||||
import "./.next-dev/dev/types/routes.d.ts";
|
import "./.next/types/routes.d.ts";
|
||||||
import "./.next-dev/dev/types/root-params.d.ts";
|
import "./.next/types/root-params.d.ts";
|
||||||
|
|
||||||
// NOTE: This file should not be edited
|
// NOTE: This file should not be edited
|
||||||
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.
|
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.
|
||||||
|
|||||||
Reference in New Issue
Block a user