Skip to content

Commit

Permalink
Merge pull request #18 from rapidsurveys/dev
Browse files Browse the repository at this point in the history
tidyup dependencies
  • Loading branch information
ernestguevarra authored Oct 21, 2023
2 parents 5ef2dc9 + cad9e19 commit dcdd57e
Show file tree
Hide file tree
Showing 9 changed files with 104 additions and 33 deletions.
22 changes: 11 additions & 11 deletions .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Workflow derived from https://github.com/r-lib/actions/tree/master/examples
# 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:
Expand All @@ -18,7 +18,7 @@ jobs:
fail-fast: false
matrix:
config:
- {os: macOS-latest, r: 'release'}
- {os: macos-latest, r: 'release'}
- {os: windows-latest, r: 'release'}
- {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'}
- {os: ubuntu-latest, r: 'release'}
Expand All @@ -27,23 +27,23 @@ jobs:
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
R_KEEP_PKG_SOURCE: yes
ONA_USERNAME: okapi_bot
ONA_PASSWORD: ${{ secrets.ONA_PASSWORD }}
ONA_TOKEN: ${{ secrets.ONA_TOKEN }}

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- uses: r-lib/actions/setup-pandoc@v1
- uses: r-lib/actions/setup-pandoc@v2

- uses: r-lib/actions/setup-r@v1
- 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@v1
- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: rcmdcheck
extra-packages: any::rcmdcheck
needs: check

- uses: r-lib/actions/check-r-package@v1
- uses: r-lib/actions/check-r-package@v2
with:
upload-snapshots: true
32 changes: 26 additions & 6 deletions .github/workflows/test-coverage.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Workflow derived from https://github.com/r-lib/actions/tree/master/examples
# 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:
Expand All @@ -15,16 +15,36 @@ jobs:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- uses: r-lib/actions/setup-r@v1
- uses: r-lib/actions/setup-r@v2
with:
use-public-rspm: true

- uses: r-lib/actions/setup-r-dependencies@v1
- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: covr
extra-packages: any::covr
needs: coverage

- name: Test coverage
run: covr::codecov()
run: |
covr::codecov(
quiet = FALSE,
clean = FALSE,
install_path = file.path(Sys.getenv("RUNNER_TEMP"), "package")
)
shell: Rscript {0}

- name: Show testthat output
if: always()
run: |
## --------------------------------------------------------------------
find ${{ runner.temp }}/package -name 'testthat.Rout*' -exec cat '{}' \; || true
shell: bash

- name: Upload test results
if: failure()
uses: actions/upload-artifact@v3
with:
name: coverage-test-failures
path: ${{ runner.temp }}/package
7 changes: 4 additions & 3 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Package: okapi
Type: Package
Title: Open Data Kit (ODK)-based Computer-assisted Personal Interviewing (CAPI)
Tools
Version: 0.1.0
Version: 0.1.0.9000
Authors@R: person(given = "Ernest",
family = "Guevarra",
comment = c(ORCID = "0000-0002-4887-4415"),
Expand All @@ -18,14 +18,15 @@ License: GPL-3
Imports:
httr,
tibble,
jsonlite
jsonlite,
askpass
Suggests:
spelling,
covr
Encoding: UTF-8
Language: en-GB
LazyData: true
RoxygenNote: 7.1.2
RoxygenNote: 7.2.3
Roxygeon: list(markdown = TRUE)
URL: https://rapidsurveys.io/okapi/, https://github.com/rapidsurveys/okapi
BugReports: https://github.com/rapidsurveys/okapi/issues
2 changes: 2 additions & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ export(kobo_get_data)
export(kobo_list_assets)
export(ona_auth_password)
export(ona_auth_token)
export(ona_configure)
export(ona_data_get)
export(ona_data_list)
export(ona_form_delete)
Expand All @@ -19,6 +20,7 @@ export(ona_project_info)
export(ona_project_list)
export(ona_project_register)
export(ona_project_share)
importFrom(askpass,askpass)
importFrom(httr,GET)
importFrom(httr,add_headers)
importFrom(httr,authenticate)
Expand Down
2 changes: 2 additions & 0 deletions R/okapi.R
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
#' @importFrom httr GET authenticate add_headers
#' @importFrom tibble tibble
#' @importFrom jsonlite fromJSON
#' @importFrom askpass askpass
#'
#'
#
################################################################################
Expand Down
2 changes: 2 additions & 0 deletions R/ona_misc.R
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
#'
#' @return An object of class request for HTTP requests
#'
#' @export
#'
#
################################################################################

Expand Down
18 changes: 11 additions & 7 deletions README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -16,21 +16,18 @@ knitr::opts_chunk$set(
# okapi: Open Data Kit (ODK)-based Computer-assisted Personal Interview (CAPI) Tools <img src="man/figures/logo.png" width="200" align="right" />

<!-- badges: start -->
[![Project Status: WIP – Initial development is in progress, but there has not yet been a stable, usable release suitable for the public.](https://www.repostatus.org/badges/latest/wip.svg)](https://www.repostatus.org/#wip)
[![Lifecycle: experimental](https://img.shields.io/badge/lifecycle-experimental-orange.svg)](https://www.tidyverse.org/lifecycle/#experimental)
[![R-CMD-check](https://github.com/rapidsurveys/okapi/workflows/R-CMD-check/badge.svg)](https://github.com/rapidsurveys/okapi/actions)
[![R-CMD-check](https://github.com/rapidsurveys/okapi/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/rapidsurveys/okapi/actions/workflows/R-CMD-check.yaml)
[![test-coverage](https://github.com/rapidsurveys/okapi/workflows/test-coverage/badge.svg)](https://github.com/rapidsurveys/okapi/actions)
[![Codecov test coverage](https://codecov.io/gh/rapidsurveys/okapi/branch/master/graph/badge.svg)](https://codecov.io/gh/rapidsurveys/okapi?branch=master)
[![Codecov test coverage](https://codecov.io/gh/rapidsurveys/okapi/branch/main/graph/badge.svg)](https://codecov.io/gh/rapidsurveys/okapi?branch=main)
[![CodeFactor](https://www.codefactor.io/repository/github/rapidsurveys/okapi/badge)](https://www.codefactor.io/repository/github/rapidsurveys/okapi)
<!-- badges: end -->

Data collection using computer-assisted personal interviewing or CAPI tools is now the standard approach for conducting surveys and studies. A wide range of CAPI systems are currently being used. The ability to interface with these systems helps in the overall data process. This package provides interface functions to CAPI systems based on the [Open Data Kit or ODK](https://getodk.org) technology.

## Motivation and development history


## What does `okapi` do?


## The ODK ecosystem

## What does `okapi` do?
Expand All @@ -55,13 +52,20 @@ install.packages("okapi")

You can install the development version of `okapi` from [GitHub](https://github.com/rapidsurveys/okapi) with:

```{r instal_github, eval = FALSE}
```{r install_github, eval = FALSE}
if(!require(remotes)) install.packages("remotes")
remotes::install_github("rapidsurveys/okapi")
```

## Usage

## Citation

If you find the `okapi` package useful, please cite using the suggested citation provided by a call to the `citation` function as follows:

```{r cite}
citation("okapi")
```

## Community guidelines

Expand Down
36 changes: 30 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,15 @@

<!-- badges: start -->

[![Project Status: WIP – Initial development is in progress, but there
has not yet been a stable, usable release suitable for the
public.](https://www.repostatus.org/badges/latest/wip.svg)](https://www.repostatus.org/#wip)
[![Lifecycle:
experimental](https://img.shields.io/badge/lifecycle-experimental-orange.svg)](https://www.tidyverse.org/lifecycle/#experimental)
[![R-CMD-check](https://github.com/rapidsurveys/okapi/workflows/R-CMD-check/badge.svg)](https://github.com/rapidsurveys/okapi/actions)
[![R-CMD-check](https://github.com/rapidsurveys/okapi/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/rapidsurveys/okapi/actions/workflows/R-CMD-check.yaml)
[![test-coverage](https://github.com/rapidsurveys/okapi/workflows/test-coverage/badge.svg)](https://github.com/rapidsurveys/okapi/actions)
[![Codecov test
coverage](https://codecov.io/gh/rapidsurveys/okapi/branch/master/graph/badge.svg)](https://codecov.io/gh/rapidsurveys/okapi?branch=master)
coverage](https://codecov.io/gh/rapidsurveys/okapi/branch/main/graph/badge.svg)](https://codecov.io/gh/rapidsurveys/okapi?branch=main)
[![CodeFactor](https://www.codefactor.io/repository/github/rapidsurveys/okapi/badge)](https://www.codefactor.io/repository/github/rapidsurveys/okapi)
<!-- badges: end -->

Expand All @@ -23,8 +26,6 @@ Data Kit or ODK](https://getodk.org) technology.

## Motivation and development history

## What does `okapi` do?

## The ODK ecosystem

## What does `okapi` do?
Expand All @@ -46,8 +47,7 @@ current set of functions perform the following tasks:

<!---
You can install `okapi` from [CRAN](https://cran.r-project.org):
&#10;
```r
install.packages("okapi")
```
Expand All @@ -63,6 +63,30 @@ remotes::install_github("rapidsurveys/okapi")

## Usage

## Citation

If you find the `okapi` package useful, please cite using the suggested
citation provided by a call to the `citation` function as follows:

``` r
citation("okapi")
#> To cite okapi in publications use:
#>
#> Ernest Guevarra (2023). okapi: Open Data Kit (ODK)-based
#> Computer-assisted Personal Interview (CAPI) Tools R package version
#> 0.1.0.9000 URL https://rapidsurveys.io/okapi/
#>
#> A BibTeX entry for LaTeX users is
#>
#> @Manual{,
#> title = {okapi: Open Data Kit (ODK)-based Computer-assisted Personal Interview (CAPI) Tools},
#> author = {{Ernest Guevarra}},
#> year = {2023},
#> note = {R package version 0.1.0.9000},
#> url = {https://rapidsurveys.io/okapi/},
#> }
```

## Community guidelines

Feedback, bug reports and feature requests are welcome; file issues or
Expand Down
16 changes: 16 additions & 0 deletions inst/CITATION
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
citHeader("To cite okapi in publications use:")

citEntry(
entry = "Manual",
title = "okapi: Open Data Kit (ODK)-based Computer-assisted Personal Interview (CAPI) Tools",
author = person("Ernest Guevarra"),
year = "2023",
note = "R package version 0.1.0.9000",
url = "https://rapidsurveys.io/okapi/",
textVersion = paste(
"Ernest Guevarra (2023).",
"okapi: Open Data Kit (ODK)-based Computer-assisted Personal Interview (CAPI) Tools",
"R package version 0.1.0.9000",
"URL https://rapidsurveys.io/okapi/"
)
)

0 comments on commit dcdd57e

Please sign in to comment.