@builder.io/sdk 3.0.5 → 3.0.7
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/CHANGELOG.md +12 -0
- package/dist/index.browser.js +20 -12
- package/dist/index.browser.js.map +1 -1
- package/dist/index.cjs.js +20 -12
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +20 -12
- package/dist/index.esm.js.map +1 -1
- package/dist/index.umd.js +20 -12
- package/dist/index.umd.js.map +1 -1
- package/dist/package.json +3 -2
- package/dist/src/builder.class.d.ts +6 -4
- package/dist/src/builder.class.js +19 -11
- package/dist/src/builder.class.js.map +1 -1
- package/dist/src/sdk-version.d.ts +1 -0
- package/dist/src/sdk-version.js +5 -0
- package/dist/src/sdk-version.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +3 -2
- package/scripts/set-sdk-version.sh +25 -0
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
#!/bin/bash
|
|
2
|
+
|
|
3
|
+
# This file finds all instances of `UNKNOWN_VERSION_TO_REPLACE` within `dist` and replaces them with the real version.
|
|
4
|
+
# It stores the package version that is sent to the visual editor.
|
|
5
|
+
#
|
|
6
|
+
# This script must execute after `npm version` (which bumps the version number), but before `npm publish`.
|
|
7
|
+
|
|
8
|
+
set -o nounset
|
|
9
|
+
|
|
10
|
+
LOCAL_DIR=$(pwd)
|
|
11
|
+
if [[ "$LOCAL_DIR" =~ .*packages/core*$ ]]; then
|
|
12
|
+
echo "Setting SDK Version for Gen1 SDK Core in '$LOCAL_DIR'."
|
|
13
|
+
else
|
|
14
|
+
echo "Must run this script from the root of the Gen1 SDK Core directory, e.g. 'packages/core'."
|
|
15
|
+
echo "Instead, you ran it from '$LOCAL_DIR'."
|
|
16
|
+
echo "Exiting."
|
|
17
|
+
exit 1
|
|
18
|
+
fi
|
|
19
|
+
|
|
20
|
+
# get version from package.json
|
|
21
|
+
VERSION=$(grep -o '"version": *"[^"]*"' package.json | sed 's/"version": "\(.*\)"/\1/')
|
|
22
|
+
echo "Found version number: $VERSION"
|
|
23
|
+
|
|
24
|
+
# Find all instances of `UNKNOWN_VERSION_TO_REPLACE` within `dist` and replace with the real version
|
|
25
|
+
find dist -type f -exec sed -i.bak "s/UNKNOWN_VERSION_TO_REPLACE/$VERSION/g" {} + && find dist -name "*.bak" -type f -delete
|