Skip to content

Commit bf569cc

Browse files
authored
chore: Embedded UI release fix (#696)
* ci: fix build asset packing * build: disable sourcemap generation for Embedded UI build
1 parent 9a50a34 commit bf569cc

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

.github/workflows/publication.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,17 +16,18 @@ jobs:
1616
node-version: 16
1717
registry-url: https://registry.npmjs.org
1818
- run: npm ci
19-
- run: npm run build:embedded
2019
- run: npm publish
2120
env:
2221
NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }}
22+
- run: npm run build:embedded
2323
- name: Embedded UI Artifact Upload
2424
env:
2525
GITHUB_TOKEN: ${{ secrets.YDB_PLATFORM_BOT_TOKEN_REPO }}
2626
run: |
2727
mv build /tmp/$ASSET_NAME
28-
zip -r /tmp/$ASSET_NAME.zip /tmp/$ASSET_NAME
29-
gh release upload ${{ github.event.release.tag_name }} /tmp/$ASSET_NAME.zip
28+
cd /tmp
29+
zip -r $ASSET_NAME.zip $ASSET_NAME
30+
gh release upload ${{ github.event.release.tag_name }} $ASSET_NAME.zip
3031
- name: Embedded UI Refresh Event Dispatch
3132
uses: peter-evans/repository-dispatch@v2
3233
continue-on-error: true

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,9 @@
5353
"scripts": {
5454
"start": "react-app-rewired start",
5555
"dev": "DISABLE_ESLINT_PLUGIN=true TSC_COMPILE_ON_ERROR=true REACT_APP_BACKEND=http://localhost:8765 npm start",
56-
"build": "DISABLE_ESLINT_PLUGIN=true react-app-rewired build",
56+
"build": "rm -rf build && DISABLE_ESLINT_PLUGIN=true react-app-rewired build",
5757
"//build:embedded": "echo 'PUBLIC_URL is a setting for create-react-app. Embedded version is built and hosted as is on ydb servers, with no way of knowing the final URL pattern. PUBLIC_URL=. keeps paths to all static relative, allowing servers to handle them as needed'",
58-
"build:embedded": "rm -rf build && PUBLIC_URL=. REACT_APP_BACKEND=http://localhost:8765 npm run build",
58+
"build:embedded": "GENERATE_SOURCEMAP=false PUBLIC_URL=. REACT_APP_BACKEND=http://localhost:8765 npm run build",
5959
"lint:styles": "stylelint 'src/**/*.scss'",
6060
"unimported": "npx unimported --no-cache",
6161
"package": "rm -rf dist && copyfiles -u 1 'src/**/*' dist",

0 commit comments

Comments
 (0)