Skip to content

Commit

Permalink
Test publish plugin to Automattic/create-content-model-releases
Browse files Browse the repository at this point in the history
  • Loading branch information
candy02058912 committed Aug 30, 2024
1 parent d5fca63 commit 593b13e
Showing 1 changed file with 13 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Publish plugin to Automattic/create-content-model-releases repository
name: Publish plugin to Automattic/create-content-model-releases latest on trunk merge

on:
pull_request:
Expand Down Expand Up @@ -31,6 +31,17 @@ jobs:
- name: Move plugin zip to output/
run: mv create-content-model.zip output/

- name: Get user email
id: get_email
run: |
EMAIL=$(curl -s -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
https://api.github.com/users/${{ github.actor }} \
| jq -r '.email // empty')
if [ -z "$EMAIL" ]; then
EMAIL="${{ github.actor }}@users.noreply.github.com"
fi
echo "email=$EMAIL" >> $GITHUB_OUTPUT
- name: Push zip to another repository
uses: cpina/github-action-push-to-another-repository@main
env:
Expand All @@ -40,4 +51,5 @@ jobs:
destination-github-username: "automattic"
destination-repository-name: "create-content-model-releases"
user-name: ${{ github.actor }}
user-email: ${{ steps.get_email.outputs.email }}
target-branch: latest

0 comments on commit 593b13e

Please sign in to comment.