diff --git a/.Rbuildignore b/.Rbuildignore index 9f82338..2198824 100644 --- a/.Rbuildignore +++ b/.Rbuildignore @@ -19,3 +19,4 @@ ^vignettes/sample_size_files$ ˆvignettes/sample_size.html$ ^CODE_OF_CONDUCT\.md$ +^vignettes/\.quarto$ diff --git a/.github/workflows/netlify.yaml b/.github/workflows/netlify.yaml new file mode 100644 index 0000000..6dcac9d --- /dev/null +++ b/.github/workflows/netlify.yaml @@ -0,0 +1,53 @@ +on: + pull_request: + branches: [main, master] + +name: pkgdown-pr + +jobs: + netlify: + runs-on: ubuntu-latest + env: + GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} + steps: + - uses: actions/checkout@v4 + + - uses: r-lib/actions/setup-tinytex@v2 + + - uses: r-lib/actions/setup-pandoc@v2 + + - uses: r-lib/actions/setup-r@v2 + with: + use-public-rspm: true + + - uses: r-lib/actions/setup-r-dependencies@v2 + with: + extra-packages: any::pkgdown, local::. + needs: website + + - name: Install package + run: R CMD INSTALL . + + - name: Create website + run: | + pkgdown::build_site() + shell: Rscript {0} + + - name: Create index file + run: | + echo ' ' > ./docs/index.html + + - name: Deploy to Netlify + uses: nwtgck/actions-netlify@v3.0 + with: + publish-dir: './docs' + production-branch: main + github-token: ${{ secrets.GITHUB_TOKEN }} + deploy-message: + 'Deploy from GHA: ${{ github.event.pull_request.title || github.event.head_commit.message }} (${{ github.sha }})' + # these default to 'true' + enable-commit-comment: false + enable-github-deployment: false + env: + NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }} + NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }} \ No newline at end of file diff --git a/.github/workflows/test-coverage.yaml b/.github/workflows/test-coverage.yaml index 619bfc9..9882260 100644 --- a/.github/workflows/test-coverage.yaml +++ b/.github/workflows/test-coverage.yaml @@ -15,7 +15,6 @@ jobs: runs-on: ubuntu-latest env: GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} - CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} steps: - uses: actions/checkout@v4 diff --git a/DESCRIPTION b/DESCRIPTION index 5361f94..e5590c5 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -2,7 +2,7 @@ Type: Package Package: mwana Title: An Efficient Workflow for Plausibility Checks and Prevalence Analysis of Wasting in R -Version: 0.2.1 +Version: 0.2.1.9000 Authors@R: c( person("Tomás", "Zaba", , "tomas.zaba@outlook.com", role = c("aut", "cre", "cph"), diff --git a/pkgdown/_pkgdown.yml b/pkgdown/_pkgdown.yml index 401d259..d73cf21 100644 --- a/pkgdown/_pkgdown.yml +++ b/pkgdown/_pkgdown.yml @@ -7,18 +7,19 @@ development: template: bootstrap: 5 - bootswatch: pulse theme: breeze-light - ganalytics: G-94YZ36XGLH + ganalytics: "G-94YZ36XGLH" bslib: + bootswatch: pulse pkgdown-nav-height: 100px + success: "#004225" navbar: bg: success - type: light + type: dark structure: left: [home, intro, reference, articles, news] - right: [search, website, mastodon, github] + right: [search, mastodon, github] components: articles: @@ -30,14 +31,10 @@ navbar: href: articles/prevalence.html - text: "IPC sample size requirements" href: articles/ipc_amn_check.html - website: - icon: "fa globe fa-lg" - href: https://nutriverse.io - aria-label: View website mastodon: icon: "fab fa-mastodon fa-lg" - href: https://mastodon.social/@nutriverse - aria-label: Follow on Mastodon + href: https://fosstodon.org/@nutriverse + aria-label: Mastodon home: links: