Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into 219-withr
Browse files Browse the repository at this point in the history
* origin/main: (199 commits)
  [skip actions] Bump version to 0.3.1.9018
  corrects typo
  chore: #221 update spelling
  ci: remove admiral string that was helping identifying action on UI
  revert deliberate errors
  Trigger CI
  ci: reusing workflows from admiralci
  [skip actions] Bump version to 0.3.1.9017
  [skip actions] Bump version to 0.3.1.9016
  Update pull_request_template.md
  chore: removed duplicated documentation section in news
  chore: breaking news - turn to channel 6!
  docs: #192 remove non-user functions from reference files
  docs: #230 #188 PR template tweaks
  [skip actions] Bump version to 0.3.1.9015
  lint:reduce lenght of line
  Reduce line length less than 120 characters
  Update NEWS.md
  change argument name to length_source
  Change argument name to source_length in test-length
  ...
  • Loading branch information
averissimo committed Feb 15, 2024
2 parents 80bddf9 + 87c2127 commit 4467be6
Show file tree
Hide file tree
Showing 64 changed files with 1,476 additions and 866 deletions.
11 changes: 6 additions & 5 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ We have developed a Pull Request template to aid you and our reviewers. Completi

`{xportr}`'s scope is to enable R users to write out submission compliant `xpt` files that can be delivered to a Health Authority or to downstream validation software programs. We see labels, lengths, types, ordering and formats from a dataset specification object (SDTM and ADaM) as being our primary focus. We also see messaging and warnings to users around applying information from the specification file as a primary focus. Please make sure your Pull Request meets this **scope of {xportr}**. If your Pull Request moves beyond this scope, please get in touch with the `{xportr}` team on [slack](https://pharmaverse.slack.com/archives/C030EB2M4GM) or create an issue to discuss.

Please check off each task box as an acknowledgment that you completed the task. This checklist is part of the Github Action workflows and the Pull Request will not be merged into the `devel` branch until you have checked off each task.
Please check off each task box as an acknowledgment that you completed the task. This checklist is part of the Github Action workflows and the Pull Request will not be merged into the `main` branch until you have checked off each task.

### Changes Description

Expand All @@ -18,13 +18,14 @@ _(descriptions of changes)_
- [ ] Place Closes #<insert_issue_number> into the beginning of your Pull Request Title (Use Edit button in top-right if you need to update)
- [ ] Summary of changes filled out in the above Changes Description. Can be removed or left blank if changes are minor/self-explanatory.
- [ ] Code is formatted according to the [tidyverse style guide](https://style.tidyverse.org/). Use `styler` package and functions to style files accordingly.
- [ ] New functions or arguments follow established convention found in the [Wiki](https://github.com/atorus-research/xportr/wiki/Style-Guide-for-Roxygen-Headers).
- [ ] Updated relevant unit tests or have written new unit tests. See our [Wiki](https://github.com/atorus-research/xportr/wiki/Style-Guide-for-Unit-Tests) for conventions used in this package.
- [ ] Creation/updated relevant roxygen headers and examples. See our [Wiki](https://github.com/atorus-research/xportr/wiki/Style-Guide-for-Roxygen-Headers) for conventions used in this package.
- [ ] Run `devtools::document()` so all `.Rd` files in the `man` folder and the `NAMESPACE` file in the project root are updated appropriately
- [ ] Run `pkgdown::build_site()` and check that all affected examples are displayed correctly and that all new/updated functions occur on the "Reference" page.
- [ ] Update NEWS.md if the changes pertain to a user-facing function (i.e. it has an @export tag) or documentation aimed at users (rather than developers)
- [ ] Make sure that the pacakge version in the NEWS.md and DESCRIPTION file is same. Don't worry about updating the version because it will be auto-updated using the `vbump.yaml` CI.
- [ ] Address any updates needed for vignettes and/or templates
- [ ] Update `NEWS.md` if the changes pertain to a user-facing function (i.e. it has an `@export` tag) or documentation aimed at users (rather than developers)
- [ ] The `NEWS.md` entry should go under the `# xportr development version` section. Don't worry about updating the version because it will be auto-updated using the `vbump.yaml` CI.
- [ ] Address any updates needed for vignettes and/or templates.
- [ ] Link the issue Development Panel so that it closes after successful merging.
- [ ] Fix merge conflicts
- [ ] The developer is responsible for fixing merge conflicts not the Reviewer.
- [ ] Pat yourself on the back for a job well done! Much love to your accomplishment!
38 changes: 0 additions & 38 deletions .github/workflows/check-links.yml

This file was deleted.

42 changes: 30 additions & 12 deletions .github/workflows/check-standard.yaml
Original file line number Diff line number Diff line change
@@ -1,21 +1,34 @@
---
# Workflow derived from https://github.com/r-lib/actions/tree/master/examples
# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help
name: R-CMD-check 📦

on:
# 'push' events are triggered when commits
# are pushed to one of these branches
push:
branches:
- main
tags:
- "v*"
# 'pull_request' events are triggered when PRs are
# created against one of these target branches.
pull_request:
types:
- opened
- synchronize
- reopened
- ready_for_review
branches:
- main
# 'workflow_dispatch' gives you the ability
# to run this workflow on demand, anytime
workflow_dispatch:

jobs:
R-CMD-check:
runs-on: ${{ matrix.config.os }}

check:
name: ${{ matrix.config.os }} (${{ matrix.config.r }})

runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
Expand All @@ -25,24 +38,29 @@ jobs:
- { os: ubuntu-latest, r: "devel", http-user-agent: "release" }
- { os: ubuntu-latest, r: "release" }
- { os: ubuntu-latest, r: "oldrel-1" }

env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
R_KEEP_PKG_SOURCE: yes

if: >
!contains(github.event.commits[0].message, '[skip checks]')
steps:
- uses: actions/checkout@v3
- name: Checkout repository 🛎
uses: actions/checkout@v4

- uses: r-lib/actions/setup-pandoc@v2
- name: Install Pandoc
uses: r-lib/actions/setup-pandoc@v2

- uses: r-lib/actions/setup-r@v2
- name: Setup R 📊
uses: r-lib/actions/setup-r@v2
with:
r-version: ${{ matrix.config.r }}
http-user-agent: ${{ matrix.config.http-user-agent }}
use-public-rspm: true

- uses: r-lib/actions/setup-r-dependencies@v2
- name: Install R package dependencies 📦
uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: rcmdcheck
extra-packages: any::rcmdcheck

- uses: r-lib/actions/check-r-package@v2
- name: Run R CMD check 🎯
uses: r-lib/actions/check-r-package@v2
113 changes: 113 additions & 0 deletions .github/workflows/common.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,113 @@
---
name: xportr CI/CD Workflows

on:
# 'push' events are triggered when commits
# are pushed to one of these branches
push:
branches:
- main
tags:
- "v*"
# 'pull_request' events are triggered when PRs are
# created against one of these target branches.
pull_request:
types:
- opened
- synchronize
- reopened
- ready_for_review
branches:
- main
# 'workflow_dispatch' gives you the ability
# to run this workflow on demand, anytime
workflow_dispatch:

concurrency:
group: common-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

env:
R_VERSION: "release"

jobs:
# Get R version from environmental variable
# and use it in downstream jobs
get_r_version:
name: Get R version
runs-on: ubuntu-latest
outputs:
r-version: ${{ steps.get_r_version.outputs.R_VERSION }}
steps:
- name: Get R Version for Downstream Container Jobs
id: get_r_version
run: echo "R_VERSION=$R_VERSION" >> $GITHUB_OUTPUT
shell: bash

# Test code coverage of R Package
coverage:
name: Code Coverage
uses: pharmaverse/admiralci/.github/workflows/code-coverage.yml@main
if: >
github.event_name != 'release'
needs: get_r_version
with:
r-version: "${{ needs.get_r_version.outputs.r-version }}"
# Whether to skip code coverage badge creation
# Setting to 'false' will require you to create
# an orphan branch called 'badges' in your repository
skip-coverage-badges: true

# Ensure that styling guidelines are followed
style:
name: Code Style
uses: pharmaverse/admiralci/.github/workflows/style.yml@main
if: github.event_name == 'pull_request'
needs: get_r_version
with:
r-version: "${{ needs.get_r_version.outputs.r-version }}"

# Ensure there are no broken URLs in the package documentation
links:
name: Links
uses: pharmaverse/admiralci/.github/workflows/links.yml@main
if: github.event_name == 'pull_request'

# Build the website and deploy to `gh-pages` branch
site:
name: Documentation
uses: pharmaverse/admiralci/.github/workflows/pkgdown.yml@main
if: github.event_name == 'push' || startsWith(github.ref, 'refs/tags/v')
needs: get_r_version
with:
r-version: "release"
skip-multiversion-docs: true
secrets:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}

# Ensure there are no linter errors in the package
linter:
name: Lint
uses: pharmaverse/admiralci/.github/workflows/lintr.yml@main
if: github.event_name == 'pull_request'
needs: get_r_version
with:
r-version: "${{ needs.get_r_version.outputs.r-version }}"

# Ensure there are no spelling errors in the package
spellcheck:
name: Spelling
uses: pharmaverse/admiralci/.github/workflows/spellcheck.yml@main
if: github.event_name == 'pull_request'
needs: get_r_version
with:
r-version: "${{ needs.get_r_version.outputs.r-version }}"

# Bumps development version of the package
vbump:
name: Version Bump 🤜🤛
if: github.event_name == 'push'
uses: insightsengineering/r.pkg.template/.github/workflows/version-bump.yaml@main
secrets:
REPO_GITHUB_TOKEN: ${{ secrets.REPO_GITHUB_TOKEN }}

34 changes: 0 additions & 34 deletions .github/workflows/lint.yaml

This file was deleted.

48 changes: 0 additions & 48 deletions .github/workflows/pkgdown.yaml

This file was deleted.

Loading

0 comments on commit 4467be6

Please sign in to comment.