Skip to content

Commit

Permalink
Work on #7.
Browse files Browse the repository at this point in the history
  • Loading branch information
mjordan committed Oct 24, 2017
1 parent 877ea5f commit f128473
Showing 1 changed file with 15 additions and 2 deletions.
17 changes: 15 additions & 2 deletions modules/islandora_doi_datacite/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,22 @@ There is also an option to use both the object's DC.creator and DC.contributor v

## Assigning DataCite DOIs from a list of PIDs

This module includes a drush script that can assign DOIs from a list of PIDS. The script provides two commands, `islandora_doi_datacite_assign_dois_preflight` and `islandora_doi_datacite_assign_dois`.
This module includes a drush script that can assign DOIs from a list of PIDS. The PID file contains one PID per line, and lines can be commented:

The preflight command checks each object identified in the PID file to confirm that its DC datastream contains the values required by the DataCite metadata schema, specifically, for a dc.title, dc.creator, dc.publisher. It also checks the dc.date field for a YYYY year. Running the file produces two output files, named after the PID file with `.passed' and `.errors` appended. The 'passed' file contains PIDs of objects that had all the required values, and the 'errors' file contains a log of the missing elements in each object. For example:
```
islandora:10
islandora:11
example:5782
# This line will be ignored.
// So will this one.
islandora:948
someothernamespace:1
someothernamespace:2
```

The script provides two commands, `islandora_doi_datacite_assign_dois_preflight` and `islandora_doi_datacite_assign_dois`. You should run the preflight command on your list of PIDs before running the assign command. Configuration options set in the admin GUI as described above are used by the drush commands.

The preflight command checks each object identified in the PID file to confirm that its DC datastream contains the values required by the DataCite metadata schema, specifically, for a dc.title, dc.creator, dc.publisher. It also checks the dc.date field for a YYYY year. Running the file produces two output files, named after the PID file with `.passed` and `.errors` appended. The 'passed' file contains PIDs of objects that had all the required values, and the 'errors' file contains a log of the missing elements in each object. For example:

```
drush -u 1 islandora_doi_datacite_assign_dois_preflight --pid_file=/tmp/dois.pids
Expand Down

0 comments on commit f128473

Please sign in to comment.