Skip to content

Commit

Permalink
feat: add example .releaserc.yaml to README
Browse files Browse the repository at this point in the history
  • Loading branch information
rwaffen authored Sep 24, 2024
1 parent f90c029 commit d4cd771
Showing 1 changed file with 70 additions and 0 deletions.
70 changes: 70 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,76 @@ This container can be used to create project releases. It encapsulates [semantic

## Usage

### Example `.releaserc.yaml` for a Gitlab project

```yaml
---
branches:
- 'main'
- 'master'
- 'production'

ci: true
debug: true
dryRun: false
tagFormat: '${version}'
preset: 'conventionalcommits'

gitlabUrl: 'https://gitlab.example.com'
gitlabApiPathPrefix: '/api/v4'

plugins:
- path: '@semantic-release/commit-analyzer'
releaseRules:
- { breaking: true, release: major }
- { type: build, release: patch }
- { type: chore, release: false }
- { type: ci, release: false }
- { type: dep, release: patch }
- { type: docs, release: patch }
- { type: feat, release: minor }
- { type: fix, release: patch }
- { type: perf, release: patch }
- { type: refactor, release: false }
- { type: revert, release: patch }
- { type: test, release: false }

- path: '@semantic-release/release-notes-generator'
writerOpts:
groupBy: 'type'
commitGroupsSort: 'title'
commitsSort: 'header'
linkCompare: true
linkReferences: true
parserOpts:
# detect JIRA issues in merge commits
issuePrefixes: ['SUP', 'BUG', 'FEATURE']
mergePattern: "^Merge branch '(.*)' into (.*)$"
mergeCorrespondence: ['branch_src', 'branch_dst']
noteKeywords: ["BREAKING CHANGE", "BREAKING CHANGES", "BREAKING"]
presetConfig:
issueUrlFormat: "https://jira.example.com/browse/{{prefix}}{{id}}"
types:
- { type: 'build', section: 'πŸ‘· Build' }
- { type: 'chore', section: '🧹 Chorses' }
- { type: 'ci', section: '🚦 CI/CD' }
- { type: 'dep', section: 'πŸ‘Ύ Dependencies' }
- { type: 'docs', section: 'πŸ“š Docs' }
- { type: 'feat', section: 'πŸš€ Features' }
- { type: 'fix', section: 'πŸ› οΈ Fixes' }
- { type: 'perf', section: '⏩ Performance' }
- { type: 'refactor', section: 'πŸ”¨ Refactor' }
- { type: 'revert', section: 'πŸ™…β€β™‚οΈ Reverts' }
- { type: 'test', section: 'πŸš₯ Tests' }

- path: '@semantic-release/changelog'
- path: '@semantic-release/git'

verifyConditions:
- '@semantic-release/changelog'
- '@semantic-release/git'
```
### Gitlab
This is a example to use this container in Gitlab.
Expand Down

0 comments on commit d4cd771

Please sign in to comment.