mirror of
https://github.com/ivuorinen/gh-action-readme.git
synced 2026-02-12 03:48:43 +00:00
* feat(deps): update go version, renovate config, tooling * chore(deps): update google/go-github to v74 * feat(deps): migrate from yaml.v3 to goccy/go-yaml * chore(deps): update goccy/go-yaml to v1.18.0 and address security concerns * feat: improve issue templates and project configuration - Update GitHub issue templates with CLI-specific fields for better bug reports - Add specialized templates for documentation, theme, and performance issues - Update pre-commit config to include comprehensive documentation linting - Remove outdated Snyk configuration and security references - Update Go version from 1.23+ to 1.24+ across project - Streamline README.md organization and improve clarity - Update CHANGELOG.md and CLAUDE.md formatting - Create comprehensive CONTRIBUTING.md with development guidelines - Remove TODO.md (replaced by docs/roadmap.md) - Move SECURITY.md to docs/security.md * docs: fix markdown linting violations across documentation * fix: resolve template placeholder issues and improve uses statement generation * fix: remove trailing whitespace from GitHub issue template
= {{.Name}}
:toc: left
:toclevels: 3
:icons: font
:source-highlighter: highlight.js
{{if .Branding}}image:https://img.shields.io/badge/icon-{{.Branding.Icon}}-{{.Branding.Color}}[{{.Branding.Icon}}] {{end}}+
image:https://img.shields.io/badge/GitHub%20Action-{{.Name | replace " " "%20"}}-blue[GitHub Action] +
image:https://img.shields.io/badge/license-MIT-green[License]
[.lead]
{{.Description}}
== Quick Start
Add this action to your GitHub workflow:
[source,yaml]
----
name: CI Workflow
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: {{.Name}}
uses: {{gitUsesString .}}
{{if .Inputs}}with:
{{- range $key, $val := .Inputs}}
{{$key}}: {{if $val.Default}}"{{$val.Default}}"{{else}}"value"{{end}}
{{- end}}{{end}}
----
{{if .Inputs}}
== Input Parameters
[cols="1,3,1,2", options="header"]
|===
| Parameter | Description | Required | Default
{{range $key, $input := .Inputs}}
| `{{$key}}`
| {{$input.Description}}
| {{if $input.Required}}✓{{else}}✗{{end}}
| {{if $input.Default}}`{{$input.Default}}`{{else}}_none_{{end}}
{{end}}
|===
=== Parameter Details
{{range $key, $input := .Inputs}}
==== {{$key}}
{{$input.Description}}
[horizontal]
Type:: String
Required:: {{if $input.Required}}Yes{{else}}No{{end}}
{{if $input.Default}}Default:: `{{$input.Default}}`{{end}}
.Example
[source,yaml]
----
with:
{{$key}}: {{if $input.Default}}"{{$input.Default}}"{{else}}"your-value"{{end}}
----
{{end}}
{{end}}
{{if .Outputs}}
== Output Parameters
[cols="1,3", options="header"]
|===
| Parameter | Description
{{range $key, $output := .Outputs}}
| `{{$key}}`
| {{$output.Description}}
{{end}}
|===
=== Using Outputs
[source,yaml]
----
- name: {{.Name}}
id: action-step
uses: {{gitUsesString .}}
- name: Use Output
run: |
{{- range $key, $output := .Outputs}}
echo "{{$key}}: \${{"{{"}} steps.action-step.outputs.{{$key}} {{"}}"}}"
{{- end}}
----
{{end}}
== Examples
=== Basic Usage
[source,yaml]
----
- name: Basic {{.Name}}
uses: {{gitUsesString .}}
{{if .Inputs}}with:
{{- range $key, $val := .Inputs}}
{{$key}}: {{if $val.Default}}"{{$val.Default}}"{{else}}"example-value"{{end}}
{{- end}}{{end}}
----
=== Advanced Configuration
[source,yaml]
----
- name: Advanced {{.Name}}
uses: {{gitUsesString .}}
{{if .Inputs}}with:
{{- range $key, $val := .Inputs}}
{{$key}}: {{if $val.Default}}"{{$val.Default}}"{{else}}"\${{"{{"}} vars.{{$key | upper}} {{"}}"}}"{{end}}
{{- end}}{{end}}
env:
GITHUB_TOKEN: \${{"{{"}} secrets.GITHUB_TOKEN {{"}}"}}
----
=== Conditional Usage
[source,yaml]
----
- name: Conditional {{.Name}}
if: github.event_name == 'push'
uses: {{gitUsesString .}}
{{if .Inputs}}with:
{{- range $key, $val := .Inputs}}
{{$key}}: {{if $val.Default}}"{{$val.Default}}"{{else}}"production-value"{{end}}
{{- end}}{{end}}
----
== Troubleshooting
[TIP]
====
Common issues and solutions:
1. **Authentication Errors**: Ensure required secrets are configured
2. **Permission Issues**: Verify GitHub token permissions
3. **Configuration Errors**: Validate input parameters
====
== Development
For development information, see the link:./action.yml[action.yml] specification.
=== Contributing
Contributions are welcome! Please:
1. Fork the repository
2. Create a feature branch
3. Make your changes
4. Add tests
5. Submit a pull request
== License
This project is licensed under the MIT License.
---
_Documentation generated with https://github.com/ivuorinen/gh-action-readme[gh-action-readme]_