@taskforcehq/taskforce 0.3.169 → 0.3.170

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@taskforcehq/taskforce",
3
- "version": "0.3.169",
3
+ "version": "0.3.170",
4
4
  "description": "Mission Command center for AI-powered task management (beta - under active development)",
5
5
  "author": "Stratnexus <hello@stratnexus.ai> (https://stratnexus.ai)",
6
6
  "license": "MIT",
@@ -67,7 +67,24 @@ if [[ -z "$SHA256" ]]; then
67
67
  TMP_TGZ="$(mktemp "/tmp/${PACKAGE_NAME}-${VERSION}.XXXXXX.tgz")"
68
68
  trap 'rm -f "$TMP_TGZ"' EXIT
69
69
  echo "Downloading npm tarball: $URL"
70
- curl -fsSL "$URL" -o "$TMP_TGZ"
70
+ CURL_ARGS=(-fsSL "$URL" -o "$TMP_TGZ")
71
+ AUTH_TOKEN="${NODE_AUTH_TOKEN:-${NPM_TOKEN:-}}"
72
+ if [[ -n "$AUTH_TOKEN" ]]; then
73
+ CURL_ARGS=(-fsSL -H "Authorization: Bearer ${AUTH_TOKEN}" "$URL" -o "$TMP_TGZ")
74
+ fi
75
+ if ! curl "${CURL_ARGS[@]}"; then
76
+ echo "Direct npm tarball download failed (likely private package auth). Falling back to npm pack..."
77
+ rm -f "$TMP_TGZ"
78
+ TMP_DIR="$(mktemp -d "/tmp/${PACKAGE_NAME}-${VERSION}.XXXXXX")"
79
+ trap 'rm -rf "$TMP_DIR"' EXIT
80
+ npm pack "${NPM_PACKAGE}@${VERSION}" --pack-destination "$TMP_DIR" >/dev/null
81
+ PACKED_TGZ="$(ls "$TMP_DIR"/*.tgz | head -n 1)"
82
+ if [[ -z "$PACKED_TGZ" || ! -f "$PACKED_TGZ" ]]; then
83
+ echo "Failed to locate tarball produced by npm pack." >&2
84
+ exit 1
85
+ fi
86
+ TMP_TGZ="$PACKED_TGZ"
87
+ fi
71
88
  if command -v shasum >/dev/null 2>&1; then
72
89
  SHA256="$(shasum -a 256 "$TMP_TGZ" | awk '{print $1}')"
73
90
  else