Skip to content

provides a protoc installation with the php gen plugin compiled from source.

License

Notifications You must be signed in to change notification settings

OA/protoc-php-action

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

protoc php action

this action runs the protoc compiler with the php plugin.

example usage

github action

name: build

on:
  release:
    types: [ published ]

permissions: write-all

env:
  ARTIFACT_NAME: generated-artifact.zip

jobs:
  release:
    runs-on: ubuntu-latest
    steps:
      - name: checkout repository
        uses: actions/checkout@v4

      - name: compile proto files
        uses: oa/[email protected]
        with:
          php-out: client/target
          grpc-out: client/target
          proto-file-directory: proto

      - name: archive composer package with generated files
        run: zip -r $ARTIFACT_NAME client

      - name: release
        uses: softprops/action-gh-release@v2
        with:
          files: ${{ env.ARTIFACT_NAME }}

docker run

docker run --rm -v $(pwd):/project ghcr.io/oa/protoc-php-action:0.2.2 client/target client/target proto