Hiccup parser model #90
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build | |
on: | |
push: | |
branches: [ "v2" ] | |
paths: | |
- "src/**" | |
- "test/**" | |
- "project.clj" | |
- ".github/**" | |
pull_request: | |
types: [ opened, synchronize ] | |
branches: [ "v2" ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Cache project dependencies | |
id: cache-deps | |
uses: actions/cache@v3 | |
with: | |
path: ~/.m2/repository | |
key: ${{ runner.os }}-clojure-${{ hashFiles('**/project.clj') }} | |
restore-keys: | | |
${{ runner.os }}-clojure | |
- name: Install dependencies | |
if: steps.cache-deps.outputs.cache-hit != 'true' | |
run: lein with-profile +test deps | |
- name: Run tests and check coverage | |
run: lein cloverage | |
- name: Lint source | |
run: lein clj-kondo | |
- name: Print version | |
id: version | |
run: echo "version=$(lein pprint --no-pretty -- :version)" >> $GITHUB_OUTPUT | |
- name: Create Release | |
if: ${{ github.event_name != 'pull_request' }} | |
uses: actions/create-release@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: ${{ format('v{0}', steps.version.outputs.version) }} | |
release_name: Release ${{ steps.version.outputs.version }} | |
draft: true |