Skip to content

Instantly share code, notes, and snippets.

View IanMulvany's full-sized avatar
💭
yak shaving.

Ian Mulvany IanMulvany

💭
yak shaving.
View GitHub Profile
@IanMulvany
IanMulvany / article.xsl
Created October 23, 2012 09:38
article.xsl
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" exclude-result-prefixes="xlink"
xmlns="http://www.w3.org/1999/xhtml"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:mml="http://www.w3.org/1998/Math/MathML"
xmlns:xlink="http://www.w3.org/1999/xlink">
<xsl:output method="xml" encoding="utf-8" omit-xml-declaration="yes" standalone="yes" indent="yes"/>
<xsl:variable name="article-meta" select="article/front/article-meta"/>
<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE article PUBLIC "-//NLM//DTD Journal Archiving and Interchange DTD v3.0 20080202//EN" "archivearticle3.dtd"><article xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:mml="http://www.w3.org/1998/Math/MathML" article-type="research-article"><front><journal-meta><journal-id journal-id-type="nlm-ta">eLife</journal-id><journal-id journal-id-type="hwp">elife</journal-id><journal-id journal-id-type="publisher-id">eLife</journal-id><journal-title-group><journal-title>eLife</journal-title></journal-title-group><issn pub-type="epub">2050-084X</issn><publisher><publisher-name>eLife Sciences Publications, Ltd</publisher-name></publisher></journal-meta><article-meta><article-id pub-id-type="publisher-id">00160</article-id><article-id pub-id-type="doi">10.7554/eLife.00160</article-id><article-categories><subj-group subj-group-type="display-channel"><subject>Research article</subject></subj-group><subj-group subj-group-type="heading"><subject>Biochemistry</subject></subj-group>
@IanMulvany
IanMulvany / cache_warm_diff.js
Created August 23, 2013 10:27
Just showing the quick changes I have been making in function buildDocs(cb) {
// From >
// This needs to be tweaked for every type of source
var id = /elife(\d+)\.xml/.exec(url)[1];
// TO :
// This needs to be tweaked for every type of source
// as an id we want anything between the last "/" and the last ".xml"
var urlParts = url.split("/");
// pick up the last elemet of the url
@IanMulvany
IanMulvany / elife-xrefs.xml
Last active December 22, 2015 16:09
elife xref reference
Within the author contrib node we link to other nodes using a key of the type
<xref ref-type="aff" rid="aff1" ...
where the rid gives the id of the node that we connect to. In that way this is how we tag the folloiwng information about an author.
# Affiliations
## key
{
"variables": {
"ssh_name": "vagrant",
"ssh_pass": "vagrant",
"hostname": "packer-test"
},
"builders": [{
"type": "virtualbox",
"guest_os_type": "Ubuntu_64",
2013/09/30 14:23:37 Packer Version: 0.3.7
2013/09/30 14:23:37 Packer Target OS/Arch: darwin amd64
2013/09/30 14:23:37 Detected home directory from env var: /Users/ian
2013/09/30 14:23:37 Attempting to open config file: /Users/ian/.packerconfig
2013/09/30 14:23:37 File doesn't exist, but doesn't need to. Ignoring.
2013/09/30 14:23:37 Packer config: &{PluginMinPort:0 PluginMaxPort:0 Builders:map[amazon-ebs:packer-builder-amazon-ebs amazon-chroot:packer-builder-amazon-chroot amazon-instance:packer-builder-amazon-instance digitalocean:packer-builder-digitalocean openstack:packer-builder-openstack virtualbox:packer-builder-virtualbox vmware:packer-builder-vmware] Commands:map[build:packer-command-build fix:packer-command-fix inspect:packer-command-inspect validate:packer-command-validate] PostProcessors:map[vagrant:packer-post-processor-vagrant] Provisioners:map[chef-solo:packer-provisioner-chef-solo file:packer-provisioner-file puppet-masterless:packer-provisioner-puppet-masterless shell:packer-provisioner-shel
{
"variables": {
"ssh_name": "vagrant",
"ssh_pass": "vagrant",
"hostname": "packer-test"
},
"builders": [{
"type": "virtualbox",
"guest_os_type": "Ubuntu_64",
2013/09/30 14:48:55 Packer Version: 0.3.7
2013/09/30 14:48:55 Packer Target OS/Arch: darwin amd64
2013/09/30 14:48:55 Detected home directory from env var: /Users/ian
2013/09/30 14:48:55 Attempting to open config file: /Users/ian/.packerconfig
2013/09/30 14:48:55 File doesn't exist, but doesn't need to. Ignoring.
2013/09/30 14:48:55 Packer config: &{PluginMinPort:0 PluginMaxPort:0 Builders:map[amazon-ebs:packer-builder-amazon-ebs amazon-chroot:packer-builder-amazon-chroot amazon-instance:packer-builder-amazon-instance digitalocean:packer-builder-digitalocean openstack:packer-builder-openstack virtualbox:packer-builder-virtualbox vmware:packer-builder-vmware] Commands:map[build:packer-command-build fix:packer-command-fix inspect:packer-command-inspect validate:packer-command-validate] PostProcessors:map[vagrant:packer-post-processor-vagrant] Provisioners:map[chef-solo:packer-provisioner-chef-solo file:packer-provisioner-file puppet-masterless:packer-provisioner-puppet-masterless shell:packer-provisioner-shel
@IanMulvany
IanMulvany / data-citation.xml
Created May 9, 2014 14:00
scientific data journal - data citation example
<ref-list content-type="data-citations">
<ref id="d1"><element-citation>
<named-content content-type="source">existing</named-content>
<source>Dryad Digital Repository</source>
<ext-link ext-link-type="dryad" specific-use="id" xlink:href="dryad.rv624">dryad.rv624</ext-link>
<year>2010</year>
<collab><contrib-group>
<contrib>
<name><surname>Brown</surname><given-names>Alison</given-names></name>
<custom-meta-group>
<custom-meta id="data-availability" xlink:type="simple">
<meta-name>Data Availability</meta-name>
<meta-value>
The authors confirm that all data underlying the findings are fully available without restriction. All data are included within the manuscript and in the Supplementary information.
</meta-value>
</custom-meta>
</custom-meta-group>