-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add CI for publishing chrome extension #1568
+130
−26
Merged
Changes from 16 commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
fca5f45
fix: remove the permission not needed and update the player style link
YunFeng0817 21fc35b
add change set
YunFeng0817 d1e64d8
fix: change the way of importing worker script
YunFeng0817 23ed59f
improve the extension version
YunFeng0817 0dcdf34
build: add process env to disable inline worker import
YunFeng0817 d1e932b
Apply formatting changes
YunFeng0817 6d0d320
Create extension-release.yml
YunFeng0817 56f27cd
Update extension-release.yml
YunFeng0817 9bf0a7a
Update extension-release.yml
YunFeng0817 13a85a3
Update extension-release.yml
YunFeng0817 b53c203
Merge branch 'master' into extension
YunFeng0817 6d4abc4
improve style file
YunFeng0817 6483853
upgrade svelte2tsx
YunFeng0817 4f0bf98
fix rrweb-player dts bug
YunFeng0817 3f24fcb
fix lint error
YunFeng0817 32e9577
Revert "fix rrweb-player dts bug"
YunFeng0817 d097388
try to solve the odd eslint error
YunFeng0817 df7ca9a
disable eslint check for that line
YunFeng0817 bae3268
merge the extension-release action into release action
YunFeng0817 e12b415
apply review suggestions
YunFeng0817 d09f561
add name
YunFeng0817 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@rrweb/web-extension": patch | ||
--- | ||
|
||
fix: remove the permission not needed and update the player style link |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
name: Extension Release | ||
|
||
on: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
publish-extension: | ||
name: Publish to Chrome Web Store | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.head_ref }} | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: lts/* | ||
- name: Install Dependencies | ||
run: yarn install --frozen-lockfile | ||
- name: Build Project | ||
run: NODE_OPTIONS='--max-old-space-size=4096' DISABLE_WORKER_INLINING=true yarn turbo run prepublish --filter=@rrweb/web-extension | ||
|
||
- uses: mnao305/[email protected] | ||
with: | ||
extension-id: 'pdaldeopoccdhlkabbkcjmecmmoninhe' | ||
file-path: ./packages/web-extension/dist/chrome.zip | ||
client-id: ${{ secrets.CWS_CLIENT_ID }} | ||
client-secret: ${{ secrets.CWS_CLIENT_SECRET }} | ||
refresh-token: ${{ secrets.CWS_REFRESH_TOKEN }} | ||
publish: true | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -31,7 +31,7 @@ export default function Player() { | |
|
||
const linkEl = document.createElement('link'); | ||
linkEl.href = | ||
'https://cdn.jsdelivr.net/npm/rrweb-player@latest/dist/style.css'; | ||
'https://cdn.jsdelivr.net/npm/rrweb-player@alpha/dist/style.min.css'; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is going to break once we go out of alpha, maybe you could pull in the version number directly from package.json we do in |
||
linkEl.rel = 'stylesheet'; | ||
document.head.appendChild(linkEl); | ||
playerRef.current = new Replayer({ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,14 @@ | ||
<!DOCTYPE html> | ||
<meta charset="utf-8" /> | ||
<title>rrweb</title> | ||
<html> | ||
<body> | ||
<div id="root"></div> | ||
</body> | ||
<script type="module" src="./index.tsx"></script> | ||
</html> | ||
|
||
<head> | ||
<meta charset="utf-8" /> | ||
<title>rrweb</title> | ||
</head> | ||
|
||
<body> | ||
<div id="root"></div> | ||
</body> | ||
<script type="module" src="./index.tsx"></script> | ||
|
||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As far as I can tell from here: https://github.com/changesets/action?tab=readme-ov-file#custom-publishing
You need to move the following code (including the new
if
statement) to.github/workflows/release.yml
: