-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2eedbfb
commit c4dc2fa
Showing
5 changed files
with
7,635 additions
and
71 deletions.
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,25 @@ | ||
name: Deploy plugin | ||
|
||
on: | ||
push: | ||
branches: [main, beta, alpha] | ||
|
||
jobs: | ||
deploy-git-tag-and-push-npm: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write # to create git tag | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version-file: '.nvmrc' | ||
- run: npm ci | ||
|
||
- name: Deploy git tag via semantic-release | ||
uses: cycjimmy/semantic-release-action@v4 | ||
with: | ||
semantic_version: latest # since our plugin has a devDependency on semantic-release, using latest keyword here will upgrade node_modules/ copy to the latest version for deployment | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
NPM_TOKEN: ${{ secrets.NPM_PUSH_TOKEN }} |
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,41 @@ | ||
name: Run tests | ||
|
||
on: [pull_request] | ||
|
||
jobs: | ||
run-tests: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version-file: '.nvmrc' | ||
- run: npm ci | ||
- run: npm run test | ||
|
||
run-plugin-in-semantic-release: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write # to set permissions for semantic-release dry-run to pass | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version-file: '.nvmrc' | ||
- run: npm ci | ||
|
||
- name: install self to run it in semantic-release | ||
run: | | ||
npm pack | ||
npm install --no-save semantic-release-cocoapods-0.0.0.tgz | ||
- name: setup git user to run semantic-release | ||
run: | | ||
git config --global user.email "user@example.com" | ||
git config --global user.name "Example User" | ||
- name: Run semantic-release in dry run | ||
run: unset GITHUB_ACTIONS && npx semantic-release --dry-run --no-ci --branches ${REF_NAME} --plugins "semantic-release-cocoapods" | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
REF_NAME: ${{ github.ref_name }} |
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.