Skip to content

Instantly share code, notes, and snippets.

View rushirajnenuji's full-sized avatar

Rushiraj Nenuji rushirajnenuji

  • University of California Santa Barbara
  • Santa Barbara, California
View GitHub Profile
@rushirajnenuji
rushirajnenuji / eml_validator.js
Created August 14, 2023 23:39
ChatGPT generated EML validator, based on the algorithm mentioned in https://eml.ecoinformatics.org/validation-and-content-references
function validateXML(xmlString) {
const parser = new DOMParser();
const xmlDoc = parser.parseFromString(xmlString, 'application/xml');
const rootElement = xmlDoc.documentElement;
if (rootElement.tagName !== 'eml' && rootElement.tagName !== 'eml:eml') {
return "Invalid: Root element is not 'eml'";
}

Keybase proof

I hereby claim:

  • I am rushirajnenuji on github.
  • I am rushirajnenuji (https://keybase.io/rushirajnenuji) on keybase.
  • I have a public key ASBq022VKxqQ--tdxb44sqfX6qogRuZigd0ta2GUOeIZCQo

To claim this, I am signing this object:

This file has been truncated, but you can view the full file.
doi:10.17602/C2QP4Z: in EZID (public, exported), not in DataCite, not in Handle System
< _created: 2020-06-25T05:29:30
< _updated: 2020-06-25T05:29:30
doi:10.17610/T6W899: in EZID (public, exported), target URL mismatch in Handle System
< _created: 2020-07-27T10:16:35
< _updated: 2020-07-27T10:16:52
< _target: https://ezid.cdlib.org/id/doi:10.17610/T6W899
> _target: http://escholarship.org/uc/item/60q3d3fd
doi:10.17916/P6159W: in EZID (public, exported), metadata mismatch, target URL mismatch in Handle System
@rushirajnenuji
rushirajnenuji / crossref_queue.txt
Created November 20, 2020 17:48
Crossref Queue - Nov 20, 2020
MySQL [ezid]> select seq, identifier, owner, operation, status, message, batchId, submitTime from ezidapp_crossrefqueue;
+--------+--------------------------+----------------------+-----------+--------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
@rushirajnenuji
rushirajnenuji / example.xml
Created September 23, 2020 15:50
Crossref example.xml
<?xml version="1.0" encoding="UTF-8"?>
<doi_batch xmlns="http://www.crossref.org/schema/4.4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:jats="http://www.ncbi.nlm.nih.gov/JATS1" version="4.4.0" xsi:schemaLocation="http://www.crossref.org/schema/4.4.0 http://www.crossref.org/schemas/crossref4.4.0.xsd">
<head>
<doi_batch_id>oecd_2016_04_06_04_24_15</doi_batch_id>
<timestamp>201605171583</timestamp>
<depositor>
<depositor_name>Crossref</depositor_name>
<email_address>support@crossref.org</email_address>
</depositor>
<registrant>Crossref</registrant>
@rushirajnenuji
rushirajnenuji / eartharxiv.md
Created September 22, 2020 22:09
eartharxiv.md

| 233848 | doi:10.5070/BP328133885 | ark:/99166/p9vt1gs8k | C | W | Added with conflict conflict_id=5460856 in conflict with: 10.5070/BP328133884

@rushirajnenuji
rushirajnenuji / transaction_log_sep_10_2_22_PM.log
Created September 11, 2020 00:14
transaction_log_sep_10_2_22_PM.log
2020-09-10 14:22:32,554 bd1657a8f3ab11eab9a00a97c9d844ae BEGIN createIdentifier ark:/13030/ark%253a/13030/m5673kv1 merritt ark:/99166/p9td9n725 merritt ark:/99166/p9pn8xd8d erc where:%20ark:/13030/ark:/13030/m5673kv1 mrt.creator cdl_dryad _target http://merritt.cdlib.org/m/ark%253A%252F13030%252Fark%253A%252F13030%252Fm5673kv1
2020-09-10 14:22:32,571 bd15e44ef3ab11eab5230a97c9d844ae END SUCCESS
2020-09-10 14:22:33,292 bd870494f3ab11ea8ab90a97c9d844ae BEGIN setMetadata ark:/62930/d1028q510 unlvezid ark:/99166/p9ww7737h unlv ark:/99166/p91n7xr2q dc.isPartOf Culinary%20Workers%20Union%20Local%20226%20Las%20Vegas,%20Nevada%20Photographs%20(PH-00382) dc.description Arrangement%20note:%20Series%20II.%20Public%20Events _target http://d.library.unlv.edu/digital/collection/cwu/id/26638 _profile dc dc.identifier cwu0566-022 dc.date 1905-06-13 dc.title Los%20Angeles%20march,%20Frontier%20Strike%20press%20conference,%20Culinary%20Union,%201991%20(folder%201%20of%201),%20image%2022
2020-09-10 14:22:33,328 bd870494f3ab11ea
@rushirajnenuji
rushirajnenuji / transaction_log_sep_8_2_17_PM.log
Created September 9, 2020 21:28
transaction_log_sep_8_2_17_PM.log
2020-09-09 14:14:48,143 7ddd1998f2e111eaad6a0a97c9d844ae BEGIN search/count - admin ark:/99166/p9kw57h4w admin ark:/99166/p9g44hq02 publicSearchVisible True keywords ark:88122/record_key
2020-09-09 14:15:14,953 8dd822e8f2e111eab4f30a97c9d844ae BEGIN mintIdentifier ark:/13030/m5 merritt ark:/99166/p9td9n725 merritt ark:/99166/p9pn8xd8d
2020-09-09 14:15:14,954 8dd822e8f2e111eab4f30a97c9d844ae END SUCCESS ark:/13030/m5j72vhk
2020-09-09 14:15:14,954 8dd833bef2e111eab4f30a97c9d844ae BEGIN createIdentifier ark:/13030/m5j72vhk merritt ark:/99166/p9td9n725 merritt ark:/99166/p9pn8xd8d
2020-09-09 14:15:14,975 8ddb66f6f2e111ea97430a97c9d844ae BEGIN mintIdentifier ark:/13030/m5 merritt ark:/99166/p9td9n725 merritt ark:/99166/p9pn8xd8d
2020-09-09 14:15:14,975 8ddb66f6f2e111ea97430a97c9d844ae END SUCCESS ark:/13030/m5dg23tp
2020-09-09 14:15:14,975 8ddb7380f2e111ea97430a97c9d844ae BEGIN createIdentifier ark:/13030/m5dg23tp merritt ark:/99166/p9td9n725 merritt ark:/99166/p9pn8xd8d
2020-09-09 14:15:15,404 8dd833bef2e111eab4f
@rushirajnenuji
rushirajnenuji / daily.sh
Created September 2, 2020 18:35
MySQL back up scripts
#! /bin/bash
PR=/apps/ezid/apps/apache/ezid/SITE/PROJECT
SF=$PR/settings/ezid.conf.shadow
BD=/apps/ezid/backups
DATE=$(date +%Y-%m-%d)
SBF=$BD/$DATE.store.txt.gz
MBF=$BD/$DATE.mysql.sql.gz
DB=rds-ias-ezid-search-prd.cmcguhglinoa.us-west-2.rds.amazonaws.com
keep=14
@rushirajnenuji
rushirajnenuji / results.json
Created September 1, 2020 23:40
Arctic Data Federation Metric
{
"metricsRequest": {
"metricsPage": {
"total": 0,
"start": 0,
"count": 0
},
"metrics": [
"citations",
"downloads",