Skip to content

fledge

fledge #10

Workflow file for this run

name: fledge
on:
# for manual triggers
workflow_dispatch:
# daily run
schedule:
- cron: "30 0 * * *"
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.head_ref || '' }}-${{ github.base_ref || '' }}
cancel-in-progress: true
jobs:
check_fork:
runs-on: ubuntu-latest
outputs:
is_forked: ${{ steps.check.outputs.is_forked }}
steps:
- name: Check if the repo is forked
id: check
run: |
echo "is_forked=$(curl -s -H "Accept: application/vnd.github+json" -H 'Authorization: Bearer ${{ github.token }}' -H "X-GitHub-Api-Version: 2022-11-28" ${GITHUB_API_URL}/repos/${GITHUB_REPOSITORY} | jq .fork)" >> $GITHUB_OUTPUT
fledge:
runs-on: ubuntu-latest
needs: check_fork
if: needs.check_fork.outputs.is_forked == 'false'
permissions:
contents: write
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
FLEDGE_GHA_CI: true
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Configure Git identity
run: |
env | sort
git config --local user.name "$GITHUB_ACTOR"
git config --local user.email "[email protected]"
shell: bash
- name: Update apt
run: |
sudo apt-get update
shell: bash
- uses: r-lib/actions/setup-r@v2
with:
install-r: false
use-public-rspm: true
- uses: r-lib/actions/setup-r-dependencies@v2
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
with:
pak-version: devel
packages: cynkra/fledge
cache-version: fledge-1
- name: Bump version
run: |
if (fledge::bump_version(which = "dev", no_change_behavior = "noop")) {
fledge::finalize_version(push = TRUE)
}
shell: Rscript {0}
- name: Check release
run: |
fledge:::release_after_cran_built_binaries()
shell: Rscript {0}