action.yml 763 B

12345678910111213141516171819202122232425262728293031323334
  1. name: "opencode GitHub Action"
  2. description: "Run opencode in GitHub Actions workflows"
  3. branding:
  4. icon: "code"
  5. color: "orange"
  6. inputs:
  7. model:
  8. description: "Model to use"
  9. required: true
  10. share:
  11. description: "Share the opencode session (defaults to true for public repos)"
  12. required: false
  13. prompt:
  14. description: "Custom prompt to override the default prompt"
  15. required: false
  16. runs:
  17. using: "composite"
  18. steps:
  19. - name: Install opencode
  20. shell: bash
  21. run: curl -fsSL https://opencode.ai/install | bash
  22. - name: Run opencode
  23. shell: bash
  24. id: run_opencode
  25. run: opencode github run
  26. env:
  27. MODEL: ${{ inputs.model }}
  28. SHARE: ${{ inputs.share }}
  29. PROMPT: ${{ inputs.prompt }}