-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' of github.com:steadfast-collective/convertkit
- Loading branch information
Showing
11 changed files
with
166 additions
and
54 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,77 @@ | ||
# This workflow tags a release, builds front-end assets and sends various notifications & webhooks when a release has been created. | ||
|
||
# How it works: | ||
# 1. Add release notes to the CHANGELOG.md file. Commit & push them up. | ||
# 2. Create a git tag and push it up - `git tag <version number> && git push origin --tags` | ||
# 3. This action will create a release, using the latest notes from the CHANGELOG.md file. | ||
# 4. It'll build the front-end assets and attach them to the release. | ||
# 5. Finally, it'll comment on the PRs & Issues mentioned in the changelog to let everyone know a release has been tagged. | ||
|
||
name: Release | ||
|
||
on: | ||
push: | ||
tags: | ||
- "v*" | ||
|
||
jobs: | ||
release: | ||
name: Prepare & Create Release | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v1 | ||
|
||
- name: Setup PHP | ||
uses: shivammathur/setup-php@v2 | ||
with: | ||
php-version: 8.2 | ||
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick | ||
tools: composer:v2 | ||
|
||
- name: Install NPM Dependencies | ||
run: npm install | ||
|
||
- name: Install Composer Dependencies | ||
run: composer install | ||
|
||
- name: Compile assets | ||
run: npm run build | ||
|
||
- name: Create zip | ||
run: tar -czvf dist.tar.gz dist | ||
|
||
- name: Get Changelog | ||
id: changelog | ||
uses: statamic/changelog-action@v1 | ||
with: | ||
version: ${{ github.ref }} | ||
|
||
- name: Create release | ||
id: create_release | ||
uses: actions/create-release@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
tag_name: ${{ github.ref }} | ||
release_name: ${{ github.ref }} | ||
body: ${{ steps.changelog.outputs.text }} | ||
prerelease: ${{ contains(github.ref, '-beta') }} | ||
|
||
- name: Upload zip to release | ||
uses: actions/[email protected] | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
upload_url: ${{ steps.create_release.outputs.upload_url }} | ||
asset_path: ./dist.tar.gz | ||
asset_name: dist.tar.gz | ||
asset_content_type: application/tar+gz | ||
|
||
- name: Comment on related issues | ||
uses: duncanmcclean/[email protected] | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
version: ${{ github.ref }} | ||
changelog: ${{ steps.changelog.outputs.text }} |
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,4 +1,11 @@ | ||
.DS_Store | ||
.phpunit.result.cache | ||
.php_cs.cache | ||
.php-cs-fixer.cache | ||
.idea | ||
node_modules | ||
vendor | ||
mix-manifest.json | ||
resources/dist/hot | ||
dist | ||
!dist/.gitkeep | ||
vite.hot | ||
.env |
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.