Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add semantic release config #199

Merged
merged 3 commits into from
Oct 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 38 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Release
on:
push:
branches:
- main
jobs:
release:
name: "Release"
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
# Workaround for issue: https://github.com/cycjimmy/semantic-release-action/issues/159
# Had to pin to version 14
- name: "Pin node version"
uses: actions/setup-node@v2
with:
node-version: '14'
# Use haskell environment to run cabal configure needed for semantic-release-hackage
- name: Setup Haskell
id: setup-haskell-cabal
uses: haskell-actions/setup@v2
with:
ghc-version: "9.0"
cabal-version: "3.8"
- name: Semantic Release
run: cabal configure --enable-tests
- name: Semantic Release
uses: cycjimmy/semantic-release-action@v4
with:
extra_plugins: |
@semantic-release/commit-analyzer
@semantic-release/release-notes-generator
@semantic-release/github
[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
HACKAGE_TOKEN: ${{ secrets.HACKAGE_TOKEN }}
18 changes: 18 additions & 0 deletions .releaserc
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"$schema": "https://json.schemastore.org/semantic-release",
"branches": ["main"],
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
[
"semantic-release-hackage",
{
"packageName": "dotenv",
"versionPrefix": "0.",
"publishDocumentation": true
}
],
"@semantic-release/github"
],
"tagFormat": "v0.${version}"
}
2 changes: 1 addition & 1 deletion dotenv.cabal
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: dotenv
version: 0.12.0.0
version: 0.0.0.0
synopsis: Loads environment variables from dotenv files
homepage: https://github.com/stackbuilders/dotenv-hs
description:
Expand Down
Loading