Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 0 additions & 21 deletions .github/actions/prepare-example-app/action.yml

This file was deleted.

17 changes: 0 additions & 17 deletions .github/actions/setup-tools/action.yml

This file was deleted.

71 changes: 26 additions & 45 deletions .github/workflows/continuous_integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,71 +3,52 @@ name: "Continuous Integrations"
on:
pull_request:
types: [opened, synchronize, reopened]
push:
branches:
- main
- next
- development
- '*.x'

jobs:
setup:
uses: ./.github/workflows/reusable_setup.yml

lint:
needs: 'setup'
uses: ./.github/workflows/reusable_lint.yml
runs-on: "ubuntu-latest"
timeout-minutes: 30
steps:
- uses: ionic-team/capacitor-actions/lint-plugin@v1.0.0
with:
working-directory: .
gh-token: ${{ github.token }}

build:
needs: 'setup'
uses: ./.github/workflows/reusable_build.yml
runs-on: "ubuntu-latest"
timeout-minutes: 30
steps:
- uses: ionic-team/capacitor-actions/build-plugin@v1.0.0
with:
working-directory: .
gh-token: ${{ github.token }}

verify-plugin-android:
needs: ['setup', 'lint', 'build']
needs: ['lint', 'build']
runs-on: 'xcode-27'
timeout-minutes: 30
steps:
- uses: actions/checkout@v7
- name: 'Setup Tools'
uses: ./.github/actions/setup-tools
uses: ionic-team/capacitor-actions/setup-tools@v1.0.0
with:
working-directory: .
gh-token: ${{ github.token }}
- name: 'Verify Android'
working-directory: .
run: npm run verify:android

verify-plugin-ios:
needs: ['setup', 'lint', 'build']
needs: ['lint', 'build']
runs-on: 'xcode-27'
timeout-minutes: 30
steps:
- uses: actions/checkout@v7
- name: 'Setup Tools'
uses: ./.github/actions/setup-tools
uses: ionic-team/capacitor-actions/setup-tools@v1.0.0
with:
working-directory: .
gh-token: ${{ github.token }}
- name: 'Verify iOS'
working-directory: .
run: npm run verify:ios

build-example-app-android:
needs: ['verify-plugin-ios', 'verify-plugin-android']
runs-on: 'xcode-27'
timeout-minutes: 30
steps:
- uses: actions/checkout@v7
- name: 'Setup Tools'
uses: ./.github/actions/setup-tools
- name: 'Prepare example app'
uses: ./.github/actions/prepare-example-app
- name: 'Build Android example app'
working-directory: ./example-app/android
run: ./gradlew clean assembleDebug

build-example-app-ios:
needs: ['verify-plugin-ios', 'verify-plugin-android']
runs-on: 'xcode-27'
timeout-minutes: 30
steps:
- uses: actions/checkout@v7
- name: 'Setup Tools'
uses: ./.github/actions/setup-tools
- name: 'Prepare example app'
uses: ./.github/actions/prepare-example-app
- name: 'Build iOS example app'
working-directory: ./example-app/ios/App
run: xcodebuild clean build -project App.xcodeproj -scheme App CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO
49 changes: 49 additions & 0 deletions .github/workflows/create_release_pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: "Release Plugin"

on:
workflow_dispatch:

permissions:
contents: write
issues: write
deployments: write

jobs:
lint:
runs-on: "ubuntu-latest"
timeout-minutes: 30
steps:
- uses: ionic-team/capacitor-actions/lint-plugin@v1.0.0
with:
working-directory: .
gh-token: ${{ github.token }}

build:
runs-on: "ubuntu-latest"
timeout-minutes: 30
steps:
- uses: ionic-team/capacitor-actions/build-plugin@v1.0.0
with:
working-directory: .
gh-token: ${{ github.token }}

release-please:
needs: ['build', 'lint']
runs-on: ubuntu-latest
outputs:
release_created: ${{ steps.release.outputs.release_created }}
steps:
- name: 'Setup Environment'
id: setup
uses: ionic-team/capacitor-actions/setup-tools@v1.0.0
with:
working-directory: .
gh-token: ${{ github.token }}
- name: Run release-please
id: release
uses: googleapis/release-please-action@v5
with:
token: ${{ github.token }}
config-file: ${{ github.ref_name == 'next' && 'release-please-config-next.json' || 'release-please-config.json' }}
manifest-file: .release-please-manifest.json
target-branch: ${{ github.ref_name }}
70 changes: 22 additions & 48 deletions .github/workflows/release_plugin.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
name: "Release Plugin"

on:
push:
branches:
- development
- next
workflow_dispatch:
release:
types: published

permissions:
contents: write
Expand All @@ -14,55 +12,31 @@ permissions:
id-token: write # to enable use of OIDC for npm provenance and trusted publishing

jobs:
setup:
uses: ./.github/workflows/reusable_setup.yml
secrets:
THE_GH_RELEASE_TOKEN: ${{ secrets.CAP_GH_RELEASE_TOKEN }}

lint:
needs: 'setup'
uses: ./.github/workflows/reusable_lint.yml
secrets:
THE_GH_RELEASE_TOKEN: ${{ secrets.CAP_GH_RELEASE_TOKEN }}
runs-on: "ubuntu-latest"
timeout-minutes: 30
steps:
- uses: ionic-team/capacitor-actions/lint-plugin@v1.0.0
with:
working-directory: .
gh-token: ${{ github.token }}

build-packages:
needs: 'setup'
uses: ./.github/workflows/reusable_build.yml
secrets:
THE_GH_RELEASE_TOKEN: ${{ secrets.CAP_GH_RELEASE_TOKEN }}
build:
runs-on: "ubuntu-latest"
timeout-minutes: 30
steps:
- uses: ionic-team/capacitor-actions/build-plugin@v1.0.0
with:
working-directory: .
gh-token: ${{ github.token }}

release:
needs: ['setup','lint','build-packages']
needs: [ 'lint', 'build']
runs-on: 'ubuntu-latest'
timeout-minutes: 30
steps:
- uses: actions/checkout@v7
- uses: ionic-team/capacitor-actions/release-plugin-npm@v1.0.0
with:
fetch-depth: 0
token: ${{ secrets.CAP_GH_RELEASE_TOKEN }}
- name: 'Setup Tools'
uses: ./.github/actions/setup-tools
- name: Release
env:
GITHUB_TOKEN: ${{ secrets.CAP_GH_RELEASE_TOKEN }}
GH_TOKEN: ${{ secrets.CAP_GH_RELEASE_TOKEN }}
run: npx semantic-release

publish-android:
needs: ['release']
uses: ./.github/workflows/publish_android_maven_central.yml
secrets:
ANDROID_CENTRAL_USERNAME: ${{ secrets.ANDROID_CENTRAL_USERNAME }}
ANDROID_CENTRAL_PASSWORD: ${{ secrets.ANDROID_CENTRAL_PASSWORD }}
ANDROID_SIGNING_KEY_ID: ${{ secrets.ANDROID_SIGNING_KEY_ID }}
ANDROID_SIGNING_KEY: ${{ secrets.ANDROID_SIGNING_KEY }}
ANDROID_SIGNING_PASSWORD: ${{ secrets.ANDROID_SIGNING_PASSWORD }}
ANDROID_SONATYPE_STAGING_PROFILE_ID: ${{ secrets.ANDROID_SONATYPE_STAGING_PROFILE_ID }}
CAP_GH_RELEASE_TOKEN: ${{ secrets.CAP_GH_RELEASE_TOKEN }}

publish-ios:
needs: ['release']
uses: ./.github/workflows/publish_ios_cocoapods_trunk.yml
secrets:
COCOAPODS_TRUNK_TOKEN: ${{ secrets.COCOAPODS_TRUNK_TOKEN }}
CAP_GH_RELEASE_TOKEN: ${{ secrets.CAP_GH_RELEASE_TOKEN }}
working-directory: .
gh-token: ${{ github.token }}
npm-tag: ${{ github.ref_name == 'next' && 'next' || 'latest' }}
33 changes: 0 additions & 33 deletions .github/workflows/reusable_build.yml

This file was deleted.

22 changes: 0 additions & 22 deletions .github/workflows/reusable_lint.yml

This file was deleted.

22 changes: 0 additions & 22 deletions .github/workflows/reusable_setup.yml

This file was deleted.

3 changes: 3 additions & 0 deletions .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
".": "9.0.0-beta.0"
}
16 changes: 16 additions & 0 deletions release-please-config-next.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json",
"release-type": "node",
"prerelease-type": "beta",
"prerelease": true,
"packages": {
".": {
"package-name": "@capacitor/camera",
"changelog-path": "CHANGELOG.md",
"include-component-in-tag": false,
"bump-minor-pre-major": true,
"bump-patch-for-minor-pre-major": true,
"versioning": "prerelease"
}
}
}
13 changes: 13 additions & 0 deletions release-please-config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json",
"release-type": "node",
"packages": {
".": {
"package-name": "@capacitor/camera",
"changelog-path": "CHANGELOG.md",
"include-component-in-tag": false,
"bump-minor-pre-major": true,
"bump-patch-for-minor-pre-major": true
}
}
}
Loading