Skip to content

Commit

Permalink
Merge pull request #178 from kristenpeach/master
Browse files Browse the repository at this point in the history
Updates to improve pkgdown website
  • Loading branch information
jeanetteclark authored Oct 1, 2020
2 parents 29e64e9 + 25274b3 commit 6193636
Show file tree
Hide file tree
Showing 7 changed files with 117 additions and 23 deletions.
2 changes: 2 additions & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,5 @@
^\.travis\.yml$
^LICENSE$
^MAINTENANCE\.md$
^_pkgdown\.yml$
^pkgdown$
3 changes: 2 additions & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ Authors@R: c(
person("Emily", "O'Dean", email = "[email protected]", role = "ctb"),
person("Robyn", "Thiessen-Bock", email = "[email protected]", role = "ctb"),
person("Derek", "Strong", email = "[email protected]", role = "ctb"),
person("Rachel", "Sun", email = "[email protected]", role = "ctb")
person("Rachel", "Sun", email = "[email protected]", role = "ctb"),
person("Jasmine", "Lai", email = "[email protected]", role = "ctb")
)
Description: A set of utilities for working with the Arctic Data Center
(https://arcticdata.io).
Expand Down
8 changes: 4 additions & 4 deletions R/eml.R
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Helper functions for creating EML metadata

#' Create EML entity with physical section from a DataONE PID
#' Create EML entity with physical section from any DataONE PID
#'
#' @param mn (MNode) Member Node where the PID is associated with an object.
#' @param pid (character) The PID of the object to create the sub-tree for.
Expand Down Expand Up @@ -74,7 +74,7 @@ pid_to_eml_entity <- function(mn,

#' Create an EML physical object from system metadata
#'
#' This function creates a pre-canned EML physical object from what's in the
#' This function creates an EML physical object based on what's in the
#' System Metadata of an object. Note that it sets an Online Distribution URL
#' of the DataONE v2 resolve service for the PID.
#'
Expand Down Expand Up @@ -276,7 +276,7 @@ eml_party <- function(type="associatedParty",
}


#' Create an EML creator
#' Create an EML creator.
#'
#' See [eml_party()] for details.
#'
Expand All @@ -298,7 +298,7 @@ eml_creator <- function(...) {
}


#' Create an EML contact
#' Create an EML contact. Contact information is passed on to [eml_party()]
#'
#' See [eml_party()] for details.
#'
Expand Down
12 changes: 6 additions & 6 deletions R/helpers.R
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ create_dummy_metadata <- function(mn, data_pids = NULL) {

#' Create a test object
#'
#' Create a test data object.
#' Create a test data object. Make sure the member node you use is not a production node.
#'
#' @param mn (MNode) The Member Node.
#'
Expand Down Expand Up @@ -121,7 +121,7 @@ create_dummy_object <- function(mn) {

#' Create a test package
#'
#' Create a test data package.
#' Create a full test data package with data objects and 1 metadata object. Size = the number of data objects you want in the dummy package + 1 metadata object.
#'
#' @param mn (MNode) The Member Node.
#' @param size (numeric) The number of files in the package, including the metadata file.
Expand Down Expand Up @@ -195,7 +195,7 @@ create_dummy_package <- function(mn, size = 2) {

#' Create a test parent package
#'
#' Create a test parent data package.
#' Create a test parent data package. Make sure the node is not a production node.
#'
#' @param mn (MNode) The Member Node.
#' @param children (character) Child package (resource maps) PIDs.
Expand Down Expand Up @@ -324,7 +324,7 @@ create_dummy_enumeratedDomain_dataframe <- function(factors) {

#' Create dummy package with fuller metadata
#'
#' Creates a fuller package than [create_dummy_package()]
#' Creates a more complete package than [create_dummy_package()]
#' but is otherwise based on the same concept. This dummy
#' package includes multiple data objects, responsible parties,
#' geographic locations, method steps, etc.
Expand Down Expand Up @@ -579,7 +579,7 @@ list_submissions <- function(mn, from = Sys.Date(), to = Sys.Date(), formatType

#' Read a shapefile from a pid
#'
#' Read a shapefile from a pid that points to the zipped directory of the shapefile and associated files
#' Read a shapefile 'sf' from a pid that points to the zipped directory of the shapefile and associated files
#' on a given member node.
#'
#' @param mn (MNode) A DataOne Member Node
Expand Down Expand Up @@ -626,7 +626,7 @@ read_zip_shapefile <- function(mn, pid){

#' Recovers failed submissions
#'
#' Recovers failed submissions and write the new, valid EML to a given path
#' Recovers failed submissions and writes the new, valid EML to a given path
#'
#' @param node (MNode) The Member Node to publish the object to.
#' @param pid The PID of the EML metadata document to be recovered.
Expand Down
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,12 @@ Note: The package is intended to be used by NCEAS staff and may not make much se

## Installing

We recommend installing from the latest [release](https://github.com/NCEAS/arcticdatautils/releases) (aka tag) instead of from `master`. Install the latest release with the [`remotes`](https://github.com/r-lib/remotes) package:
To install the latest version of this package we recommend installing from Github:

```r
remotes::install_github("nceas/arcticdatautils@*release")
```

If you're feeling adventurous, you can install from the bleeding edge:

```r
remotes::install_github("nceas/arcticdatautils")

```

## Contributing
Expand Down Expand Up @@ -64,3 +60,7 @@ If you *do* want to run integration tests
options(dataone_test_token = "{YOUR_TOKEN_HERE}") # <- Modify this line
devtools::test()
```

<div>
<p align="center"> <a href="https://www.nceas.ucsb.edu/"> <img src="https://www.nceas.ucsb.edu/files/logos/NCEAS/NCEAS-full%20logo-4C.jpg" width="250px" align="center" /></a> <a rel="license" href="http://creativecommons.org/licenses/by-sa/4.0/"><img alt="Creative Commons License" style="border-width:0" src="https://i.creativecommons.org/l/by-sa/4.0/88x31.png" /> </p>
</div>
90 changes: 90 additions & 0 deletions _pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,93 @@ navbar:
right:
- icon: fa-github
href: https://github.com/NCEAS/arcticdatautils

reference:
- title: Access functions
desc: High-level utility functions for getting and setting access rules for DataONE objects
contents:
- set_rights_holder
- set_access
- remove_access
- set_rights_and_access
- set_public_read
- remove_public_read
- is_public_read

- title: DataOne Functions
desc: Helper functions for the dataone package
contents:
- is_token_set
- get_token
- is_token_expired
- get_mn_base_url
- is_authorized

- title: NetCDF Functions
desc: Get a data.frame of attributes from a NetCDF object
contents:
- get_ncdf4_attributes
- get_token
- is_token_expired
- get_mn_base_url
- is_authorized

- title: Sysmeta Function
desc: Utility function for modifying System Metadata objects
contents:
- get_all_sysmeta


- title: Package editing functions
desc: Functions for managing package contents
contents:
- publish_object
- update_object
- publish_update
- create_resource_map
- update_resource_map
- set_file_name
- reformat_file_name

- title: Functions to help test a package
desc: Various helper functions for things like testing a package
contents:
- starts_with('create_')
- get_orcid_name
- get_orcid_email

- title: EML Functions
desc: Helper functions for creating EML metadata
contents:
- starts_with('pid_')
- starts_with('eml_')
- sysmeta_to_eml_physical
- get_orcid_email
- set_abstract
- which_in_eml
- reorder_pids

- title: Environment Functions
desc: Function related to loading configuriation based upon the environment
contents:
- starts_with('env_')

- title: Format Functions
desc: Functions related to data object formats
contents:
- guess_format_id
- format_eml
- format_iso

- title: QA Function
desc: Function related to metadata quality
contents:
- mdq_run








13 changes: 7 additions & 6 deletions index.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,15 @@ Note: The package is intended to be used by NCEAS staff and may not make much se

## Installing

We recommend installing from the latest [release](https://github.com/NCEAS/arcticdatautils/releases) (aka tag) instead of from `master`. Install the latest release with the [`remotes`](https://github.com/r-lib/remotes) package:

```r
remotes::install_github("nceas/arcticdatautils@*release")
```

If you're feeling adventurous, you can install from the bleeding edge:
To install the latest version of this package we recommend installing from Github:

```r

remotes::install_github("nceas/arcticdatautils")

```

<div>
<p align="center"> <a href="https://www.nceas.ucsb.edu/"><img src="https://www.nceas.ucsb.edu/files/logos/NCEAS/NCEAS-full%20logo-4C.jpg" width="250px" align="center" /></a> <a rel="license" href="http://creativecommons.org/licenses/by-sa/4.0/"><img alt="Creative Commons License" style="border-width:0" src="https://i.creativecommons.org/l/by-sa/4.0/88x31.png" /> </p>
</div>

0 comments on commit 6193636

Please sign in to comment.