Skip to content

chore(deps): update r-lib/actions digest to e6be4b3 (#74) #59

chore(deps): update r-lib/actions digest to e6be4b3 (#74)

chore(deps): update r-lib/actions digest to e6be4b3 (#74) #59

on:
push:
branches:
- devel
- RELEASE*
name: Create Github Release
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
create-release:
runs-on: ubuntu-latest
permissions:
contents: write
outputs:
tag_version: ${{ steps.create_release.outputs.tag_version }}
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
with:
fetch-depth: 0
- name: Get most recent tag
id: get_tag
run: echo "TAG_VERSION=$(git describe --tags $(git rev-list --tags --max-count=1))" >> "$GITHUB_ENV"
- name: Create Release
id: create_release
env:
GITHUB_TOKEN: ${{ github.token }}
run: |
echo "Creating release for tag $TAG_VERSION"
gh release create $TAG_VERSION --title "Release $TAG_VERSION" --notes "Release $TAG_VERSION" --target ${{ github.ref }}
echo "tag_version=$TAG_VERSION" >> "$GITHUB_OUTPUT"
create_release_artifacts:
needs: [create-release]
permissions:
contents: write
strategy:
fail-fast: false
matrix:
r_version: ['release', 'devel']
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- name: Install system dependencies
run: |
sudo apt-get install -y libxml2-dev \
libssl-dev libcurl4-openssl-dev \
libharfbuzz-dev libfribidi-dev \
pandoc
- name: Setup R
uses: r-lib/actions/setup-r@d1a6cbabea8dd2f137598ba2a70ae37ac82d7941 # v2.10.0
with:
r-version: ${{ matrix.r_version }}
use-public-rspm: true
id: r
- name: Install dependencies
uses: r-lib/actions/setup-renv@d1a6cbabea8dd2f137598ba2a70ae37ac82d7941 # v2.10.0
- name: Build Package
run: R CMD build .
- name: Rename Package
run: echo "NEWNAME=$(./utilities/rename-package.R *.tar.gz)" >> "$GITHUB_ENV"
- name: debug
run: |
echo "R version: ${{ steps.r.outputs.installed-r-version }}"
echo "Current Tag: ${{ needs.create-release.outputs.tag_version }}"
echo "Release File Name: ${{ env.NEWNAME }}"
- name: Upload Release Artifact
env:
RELEASE_TAG: ${{ needs.create-release.outputs.tag_version }}
GH_TOKEN: ${{ github.token }}
run: gh release upload ${{ env.RELEASE_TAG }} ${{ env.NEWNAME }}