@daemux/store-automator 0.9.1 → 0.10.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/marketplace.json +3 -3
- package/README.md +5 -23
- package/bin/cli.mjs +7 -66
- package/package.json +1 -2
- package/plugins/store-automator/.claude-plugin/plugin.json +1 -1
- package/plugins/store-automator/agents/architect.md +1 -1
- package/plugins/store-automator/agents/devops.md +28 -75
- package/plugins/store-automator/agents/product-manager.md +5 -5
- package/scripts/check_changed.sh +1 -1
- package/src/ci-config.mjs +0 -10
- package/src/install-paths.mjs +1 -75
- package/src/install.mjs +8 -19
- package/src/mcp-setup.mjs +1 -35
- package/src/prompt.mjs +1 -19
- package/src/templates.mjs +0 -1
- package/src/uninstall.mjs +0 -4
- package/src/utils.mjs +0 -9
- package/templates/CLAUDE.md.template +18 -18
- package/templates/ci.config.yaml.template +0 -11
- package/templates/fastlane/android/Fastfile.template +2 -2
- package/templates/fastlane/android/Pluginfile.template +1 -1
- package/templates/fastlane/ios/Fastfile.template +8 -6
- package/templates/fastlane/ios/Pluginfile.template +1 -1
- package/templates/fastlane/ios/Snapfile.template +1 -1
- package/templates/github/workflows/android-release.yml +6 -4
- package/templates/github/workflows/ios-release.yml +15 -4
- package/templates/scripts/check_changed.sh +1 -1
- package/templates/scripts/ci/android/sync-iap.sh +8 -11
- package/templates/scripts/ci/android/update-data-safety.sh +20 -21
- package/templates/scripts/ci/android/upload-metadata.sh +11 -21
- package/templates/scripts/ci/common/ci-notify.sh +39 -0
- package/templates/scripts/ci/common/link-fastlane.sh +1 -1
- package/templates/scripts/ci/common/read-config.sh +1 -5
- package/templates/scripts/ci/ios/sync-iap.sh +13 -26
- package/templates/scripts/ci/ios/upload-metadata.sh +6 -13
- package/templates/scripts/update_data_safety.py +14 -10
- package/scripts/codemagic-setup.mjs +0 -44
- package/scripts/generate.sh +0 -107
- package/src/codemagic-api.mjs +0 -75
- package/src/codemagic-setup.mjs +0 -190
- package/src/github-setup.mjs +0 -43
- package/templates/codemagic.template.yaml +0 -551
- package/templates/github/workflows/codemagic-trigger.yml +0 -78
- package/templates/scripts/generate.sh +0 -107
|
@@ -1,107 +0,0 @@
|
|
|
1
|
-
#!/bin/bash
|
|
2
|
-
set -euo pipefail
|
|
3
|
-
|
|
4
|
-
# Usage: ./scripts/generate.sh [path/to/ci.config.yaml]
|
|
5
|
-
# Generates codemagic.yaml in the current directory from codemagic.template.yaml
|
|
6
|
-
|
|
7
|
-
CONFIG="${1:-ci.config.yaml}"
|
|
8
|
-
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
|
|
9
|
-
TEMPLATE_DIR="$SCRIPT_DIR/.."
|
|
10
|
-
TEMPLATE="$TEMPLATE_DIR/codemagic.template.yaml"
|
|
11
|
-
|
|
12
|
-
if [ ! -f "$CONFIG" ]; then
|
|
13
|
-
echo "ERROR: $CONFIG not found"
|
|
14
|
-
exit 1
|
|
15
|
-
fi
|
|
16
|
-
|
|
17
|
-
if [ ! -f "$TEMPLATE" ]; then
|
|
18
|
-
TEMPLATE="ci-templates/codemagic.template.yaml"
|
|
19
|
-
if [ ! -f "$TEMPLATE" ]; then
|
|
20
|
-
echo "ERROR: codemagic.template.yaml not found"
|
|
21
|
-
exit 1
|
|
22
|
-
fi
|
|
23
|
-
fi
|
|
24
|
-
|
|
25
|
-
if ! command -v yq &>/dev/null; then
|
|
26
|
-
echo "ERROR: yq is required. Install with: brew install yq"
|
|
27
|
-
exit 1
|
|
28
|
-
fi
|
|
29
|
-
|
|
30
|
-
# Validate that a config value does not contain characters that break sed
|
|
31
|
-
validate_value() {
|
|
32
|
-
local name="$1"
|
|
33
|
-
local value="$2"
|
|
34
|
-
if [[ "$value" =~ [|/\\] ]]; then
|
|
35
|
-
echo "ERROR: $name contains invalid characters (|, /, or \\) that would break substitution."
|
|
36
|
-
echo " Current value: $value"
|
|
37
|
-
echo " Please remove |, /, and \\ characters from $name in $CONFIG"
|
|
38
|
-
exit 1
|
|
39
|
-
fi
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
# Read app values from ci.config.yaml
|
|
43
|
-
BUNDLE_ID=$(yq -r '.app.bundle_id' "$CONFIG")
|
|
44
|
-
PACKAGE_NAME=$(yq -r '.app.package_name' "$CONFIG")
|
|
45
|
-
APP_NAME=$(yq -r '.app.name' "$CONFIG")
|
|
46
|
-
SKU=$(yq -r '.app.sku' "$CONFIG")
|
|
47
|
-
APPLE_ID=$(yq -r '.app.apple_id' "$CONFIG")
|
|
48
|
-
TRACK=$(yq -r '.android.track' "$CONFIG")
|
|
49
|
-
ROLLOUT=$(yq -r '.android.rollout_fraction' "$CONFIG")
|
|
50
|
-
UPDATE_PRIORITY=$(yq -r '.android.in_app_update_priority' "$CONFIG")
|
|
51
|
-
PRIMARY_CAT=$(yq -r '.ios.primary_category' "$CONFIG")
|
|
52
|
-
SECONDARY_CAT=$(yq -r '.ios.secondary_category' "$CONFIG")
|
|
53
|
-
PRICE_TIER=$(yq -r '.ios.price_tier' "$CONFIG")
|
|
54
|
-
SUBMIT_REVIEW=$(yq -r '.ios.submit_for_review' "$CONFIG")
|
|
55
|
-
AUTO_RELEASE=$(yq -r '.ios.automatic_release' "$CONFIG")
|
|
56
|
-
|
|
57
|
-
# Read flutter_root (defaults to "." if not set)
|
|
58
|
-
APP_ROOT=$(yq -r '.flutter_root // "."' "$CONFIG")
|
|
59
|
-
|
|
60
|
-
# Read credentials from ci.config.yaml
|
|
61
|
-
P8_KEY_PATH=$(yq -r '.credentials.apple.p8_key_path' "$CONFIG")
|
|
62
|
-
APPLE_KEY_ID=$(yq -r '.credentials.apple.key_id' "$CONFIG")
|
|
63
|
-
APPLE_ISSUER_ID=$(yq -r '.credentials.apple.issuer_id' "$CONFIG")
|
|
64
|
-
GOOGLE_SA_JSON_PATH=$(yq -r '.credentials.google.service_account_json_path' "$CONFIG")
|
|
65
|
-
KEYSTORE_PASSWORD=$(yq -r '.credentials.android.keystore_password' "$CONFIG")
|
|
66
|
-
|
|
67
|
-
# Validate all values before sed substitution
|
|
68
|
-
validate_value "app.bundle_id" "$BUNDLE_ID"
|
|
69
|
-
validate_value "app.package_name" "$PACKAGE_NAME"
|
|
70
|
-
validate_value "app.name" "$APP_NAME"
|
|
71
|
-
validate_value "app.sku" "$SKU"
|
|
72
|
-
validate_value "app.apple_id" "$APPLE_ID"
|
|
73
|
-
validate_value "android.track" "$TRACK"
|
|
74
|
-
validate_value "ios.primary_category" "$PRIMARY_CAT"
|
|
75
|
-
validate_value "ios.secondary_category" "$SECONDARY_CAT"
|
|
76
|
-
validate_value "credentials.apple.key_id" "$APPLE_KEY_ID"
|
|
77
|
-
validate_value "credentials.apple.issuer_id" "$APPLE_ISSUER_ID"
|
|
78
|
-
validate_value "flutter_root" "$APP_ROOT"
|
|
79
|
-
|
|
80
|
-
# Generate codemagic.yaml from template
|
|
81
|
-
sed \
|
|
82
|
-
-e "s|\${BUNDLE_ID}|$BUNDLE_ID|g" \
|
|
83
|
-
-e "s|\${PACKAGE_NAME}|$PACKAGE_NAME|g" \
|
|
84
|
-
-e "s|\${APP_NAME}|$APP_NAME|g" \
|
|
85
|
-
-e "s|\${SKU}|$SKU|g" \
|
|
86
|
-
-e "s|\${APPLE_ID}|$APPLE_ID|g" \
|
|
87
|
-
-e "s|\${TRACK}|$TRACK|g" \
|
|
88
|
-
-e "s|\${ROLLOUT_FRACTION}|$ROLLOUT|g" \
|
|
89
|
-
-e "s|\${IN_APP_UPDATE_PRIORITY}|$UPDATE_PRIORITY|g" \
|
|
90
|
-
-e "s|\${PRIMARY_CATEGORY}|$PRIMARY_CAT|g" \
|
|
91
|
-
-e "s|\${SECONDARY_CATEGORY}|$SECONDARY_CAT|g" \
|
|
92
|
-
-e "s|\${PRICE_TIER}|$PRICE_TIER|g" \
|
|
93
|
-
-e "s|\${SUBMIT_FOR_REVIEW}|$SUBMIT_REVIEW|g" \
|
|
94
|
-
-e "s|\${AUTOMATIC_RELEASE}|$AUTO_RELEASE|g" \
|
|
95
|
-
-e "s|\${P8_KEY_PATH}|$P8_KEY_PATH|g" \
|
|
96
|
-
-e "s|\${APPLE_KEY_ID}|$APPLE_KEY_ID|g" \
|
|
97
|
-
-e "s|\${APPLE_ISSUER_ID}|$APPLE_ISSUER_ID|g" \
|
|
98
|
-
-e "s|\${GOOGLE_SA_JSON_PATH}|$GOOGLE_SA_JSON_PATH|g" \
|
|
99
|
-
-e "s|\${KEYSTORE_PASSWORD}|$KEYSTORE_PASSWORD|g" \
|
|
100
|
-
-e "s|\${APP_ROOT}|$APP_ROOT|g" \
|
|
101
|
-
"$TEMPLATE" > codemagic.yaml
|
|
102
|
-
|
|
103
|
-
echo "Generated codemagic.yaml for $APP_NAME ($BUNDLE_ID)"
|
|
104
|
-
echo " iOS: bundle_id=$BUNDLE_ID, category=$PRIMARY_CAT"
|
|
105
|
-
echo " Android: package=$PACKAGE_NAME, track=$TRACK"
|
|
106
|
-
echo " Flutter: root=$APP_ROOT"
|
|
107
|
-
echo " Credentials: P8=$P8_KEY_PATH, SA=$GOOGLE_SA_JSON_PATH"
|