@@ -10,21 +10,8 @@ if [ -z "$VERSION" ]; then
1010 exit 1
1111fi
1212
13- # Format the package name similar to common software package conventions
14- # You can choose one of these formats by uncommenting the preferred one:
15-
16- # Option 1: Simple format with version only
13+ # Format the package name
1714PACKAGE_NAME=" rider-waite-smith-${VERSION} "
18-
19- # Option 2: RPM-like format with version and build date
20- # PACKAGE_NAME="rider-waite-smith-${VERSION}-${TIMESTAMP}"
21-
22- # Option 3: Debian-like format
23- # PACKAGE_NAME="rider-waite-smith_${VERSION}_all"
24-
25- # Option a standard format
26- # PACKAGE_NAME="rider-waite-smith-v${VERSION}"
27-
2815ZIP_FILE=" ${PACKAGE_NAME} .zip"
2916
3017# Create a temporary directory for packaging
@@ -36,7 +23,7 @@ mkdir -p "${DECK_DIR}"
3623cp -r rider-waite-smith/* " ${DECK_DIR} /"
3724
3825# Include metadata file with package info
39- cat > " ${DECK_DIR} /PACKAGE-INFO.txt" << EOL
26+ cat > " ${DECK_DIR} /PACKAGE-INFO.txt" << EOL
4027Package: Rider-Waite-Smith Tarot Deck
4128Version: ${VERSION}
4229Build Date: $( date -u +" %Y-%m-%d %H:%M:%S UTC" )
@@ -46,14 +33,22 @@ Repository: ${GITHUB_REPOSITORY:-"arcanaland/specifications"}
4633This package follows the Tarot Deck Specification v1.0.
4734EOL
4835
49- # Create the zip file
50- (cd " ${TEMP_DIR} " && zip -r " ${ZIP_FILE} " " ${PACKAGE_NAME} " )
36+ # Create the zip file and suppress the output
37+ (cd " ${TEMP_DIR} " && zip -r " ${ZIP_FILE} " " ${PACKAGE_NAME} " > /dev/null)
38+
39+ # Check if zip command was successful
40+ if [ $? -ne 0 ]; then
41+ echo " ERROR: Failed to create zip file" >&2
42+ rm -rf " ${TEMP_DIR} "
43+ exit 1
44+ fi
5145
5246# Move the zip file to the current directory
5347mv " ${TEMP_DIR} /${ZIP_FILE} " .
5448
5549# Clean up the temporary directory
5650rm -rf " ${TEMP_DIR} "
5751
58- # Output the path to the zip file
59- echo " ${ZIP_FILE} "
52+ # Output just the filename, no other text
53+ echo " ${ZIP_FILE} "
54+
0 commit comments