Skip to content
Merged
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
15 changes: 13 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: CmdStanPy

on:
push:
branches:
Expand All @@ -8,6 +8,13 @@ on:
tags:
- '**'
pull_request:
workflow_dispatch:
inputs:
cmdstan-version:
description: 'Version to test'
required: false
default: 'latest'

jobs:
get-cmdstan-version:
# get the latest cmdstan version to use as part of the cache key
Expand All @@ -17,7 +24,11 @@ jobs:
- name: Get CmdStan version
id: check-cmdstan
run: |
echo "::set-output name=version::$(python -c 'import requests;print(requests.get("https://api.github.com/repos/stan-dev/cmdstan/releases/latest").json()["tag_name"][1:])')"
if [[ "${{ github.event.inputs.cmdstan-version }}" == "latest" ]]; then
echo "::set-output name=version::${{ github.event.inputs.cmdstan-version }}"
else
echo "::set-output name=version::$(python -c 'import requests;print(requests.get("https://api.github.com/repos/stan-dev/cmdstan/releases/latest").json()["tag_name"][1:])')"
fi
outputs:
version: ${{ steps.check-cmdstan.outputs.version }}

Expand Down