Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add pkgdown fix #79 #80

Merged
merged 2 commits into from
Dec 26, 2023
Merged
Show file tree
Hide file tree
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
3 changes: 3 additions & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -42,3 +42,6 @@
^rawdata/
^CRAN-SUBMISSION$
^\.editorconfig$
^_pkgdown\.yml$
^docs$
^pkgdown$
51 changes: 51 additions & 0 deletions .github/workflows/pkgdown.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples
# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help

on:
push:
branches:
- v*
pull_request:
branches:
- v*
release:
types: [published]
workflow_dispatch:

name: pkgdown

jobs:
pkgdown:
runs-on: ubuntu-latest
# Only restrict concurrency for non-PR jobs
concurrency:
group: pkgdown-${{ github.event_name != 'pull_request' || github.run_id }}
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
permissions:
contents: write
steps:
- uses: actions/checkout@v3

- 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: Build site
run: pkgdown::build_site_github_pages(new_process = FALSE, install = FALSE)
shell: Rscript {0}

- name: Deploy to GitHub pages 🚀
if: github.event_name != 'pull_request'
uses: JamesIves/[email protected]
with:
clean: false
branch: gh-pages
folder: docs
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
doc
Meta
^cran-comments\.md$
docs
6 changes: 4 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,12 @@ Package: oolong
Title: Create Validation Tests for Automated Content Analysis
Version: 0.5.1
Authors@R:
c(person(given = "Chung-hong", family = "Chan", role = c("aut", "cre"), email = "[email protected]", comment = c(ORCID = "0000-0002-6232-7530")), person(given = "Marius", family = "Sältzer", role = c("aut"), email = "[email protected]", comment = c(ORCID = "0000-0002-8604-4666")))
c(person(given = "Chung-hong", family = "Chan", role = c("aut", "cre"), email = "[email protected]", comment = c(ORCID = "0000-0002-6232-7530")),
person(given = "Marius", family = "Sältzer", role = c("aut"), email = "[email protected]", comment = c(ORCID = "0000-0002-8604-4666")))
Description: Intended to create standard human-in-the-loop validity tests for typical automated content analysis such as topic modeling and dictionary-based methods. This package offers a standard workflow with functions to prepare, administer and evaluate a human-in-the-loop validity test. This package provides functions for validating topic models using word intrusion, topic intrusion (Chang et al. 2009, <https://papers.nips.cc/paper/3700-reading-tea-leaves-how-humans-interpret-topic-models>) and word set intrusion (Ying et al. 2021) <doi:10.1017/pan.2021.33> tests. This package also provides functions for generating gold-standard data which are useful for validating dictionary-based methods. The default settings of all generated tests match those suggested in Chang et al. (2009) and Song et al. (2020) <doi:10.1080/10584609.2020.1723752>.
License: LGPL (>= 2.1)
Encoding: UTF-8
URL: https://github.com/gesistsa/oolong
URL: https://gesistsa.github.io/oolong, https://github.com/gesistsa/oolong
LazyData: true
Depends:
R (>= 4.0)
Expand Down Expand Up @@ -43,3 +44,4 @@ Suggests:
BugReports: https://github.com/gesistsa/oolong/issues
VignetteBuilder: knitr
Config/testthat/edition: 3
Config/Needs/website: gesistsa/tsatemplate
33 changes: 2 additions & 31 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,37 +1,8 @@
all: vignettes overviewgh build ghdocs
all: build

.FORCE:

vignettes: .FORCE
cat vig_head.Rmd | sed 's/{title}/Overview/g' > vig_temp.Rmd
cat vig_temp.Rmd vig_body.Rmd > vignettes/overview.Rmd
rm vig_temp.Rmd
cat vig_head.Rmd | sed 's/{title}/BTM/g' > vig_temp.Rmd
cat vig_temp.Rmd btm.Rmd > vignettes/btm.Rmd
rm vig_temp.Rmd
cat vig_head.Rmd | sed 's/{title}/Deploy/g' > vig_temp.Rmd
cat vig_temp.Rmd deploy.Rmd > vignettes/deploy.Rmd
rm vig_temp.Rmd

overviewgh: vignettes
cat gh_head.Rmd | sed 's/{title}/Overview/g' > gh_temp.Rmd
cat gh_temp.Rmd vig_body.Rmd > overview_gh.Rmd
rm gh_temp.Rmd
cat gh_head.Rmd | sed 's/{title}/BTM/g' > gh_temp.Rmd
cat gh_temp.Rmd btm.Rmd > btm_gh.Rmd
rm gh_temp.Rmd
cat gh_head.Rmd | sed 's/{title}/Deploy/g' > gh_temp.Rmd
cat gh_temp.Rmd deploy.Rmd > gh_temp2.Rmd
cat gh_temp2.Rmd | sed 's;figures;vignettes/figures;g' > deploy_gh.Rmd
rm gh_temp.Rmd gh_temp2.Rmd

build: vignettes
build:
Rscript -e "devtools::document()"
Rscript -e "devtools::install(quick = TRUE, upgrade = 'never')"
Rscript -e "devtools::check()"

ghdocs: overviewgh
Rscript -e "rmarkdown::render('README.Rmd')"
Rscript -e "rmarkdown::render('overview_gh.Rmd')"
Rscript -e "rmarkdown::render('btm_gh.Rmd')"
Rscript -e "rmarkdown::render('deploy_gh.Rmd')"
4 changes: 2 additions & 2 deletions README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ knitr::opts_chunk$set(
set.seed(42)
```

# oolong <img src="man/figures/oolong_logo.svg" align="right" height="200" />
# oolong <img src="man/figures/oolong_logo.png" align="right" width="120" />

<!-- badges: start -->
[![Codecov test coverage](https://codecov.io/gh/gesistsa/oolong/branch/v0.5/graph/badge.svg)](https://codecov.io/gh/gesistsa/oolong?branch=v0.5)
Expand All @@ -26,7 +26,7 @@ set.seed(42)

The goal of oolong ^[/ˈuːlʊŋ/ 烏龍, literally means "Dark Dragon", is a semi-oxidized tea from Asia. It is very popular in Taiwan, Japan and Hong Kong. In Cantonese and Taiwanese Mandarin, the same word can also mean "confused". It perfectly captures the spirit of human-in-the-loop validation. ] is to generate and administrate validation tests easily for typical automated content analysis tools such as topic models and dictionary-based tools.

Please refer to the [overview](overview_gh.md) for an introduction to this package. If you need to deploy the test online, please refer to the [Deployment Vignette](deploy_gh.md). If you use BTM, please refer to the [BTM Vignette](btm_gh.md).
Please refer to the [overview](https://gesistsa.github.io/oolong/articles/overview.html) for an introduction to this package. If you need to deploy the test online, please refer to the [Deployment Vignette](https://gesistsa.github.io/oolong/articles/deploy.html). If you use BTM, please refer to the [BTM Vignette](https://gesistsa.github.io/oolong/articles/btm.html).

## Citation

Expand Down
13 changes: 8 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

<!-- README.md is generated from README.Rmd. Please edit that file -->

# oolong <img src="man/figures/oolong_logo.svg" align="right" height="200" />
# oolong <img src="man/figures/oolong_logo.png" align="right" width="120" />

<!-- badges: start -->

Expand All @@ -19,10 +19,13 @@ The goal of oolong \[1\] is to generate and administrate validation
tests easily for typical automated content analysis tools such as topic
models and dictionary-based tools.

Please refer to the [overview](overview_gh.md) for an introduction to
this package. If you need to deploy the test online, please refer to the
[Deployment Vignette](deploy_gh.md). If you use BTM, please refer to the
[BTM Vignette](btm_gh.md).
Please refer to the
[overview](https://gesistsa.github.io/oolong/articles/overview.html) for
an introduction to this package. If you need to deploy the test online,
please refer to the [Deployment
Vignette](https://gesistsa.github.io/oolong/articles/deploy.html). If
you use BTM, please refer to the [BTM
Vignette](https://gesistsa.github.io/oolong/articles/btm.html).

## Citation

Expand Down
3 changes: 3 additions & 0 deletions _pkgdown.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
url: https://gesistsa.github.io/oolong/
template:
package: tsatemplate
94 changes: 0 additions & 94 deletions btm.Rmd

This file was deleted.

110 changes: 0 additions & 110 deletions btm_gh.Rmd

This file was deleted.

Loading