Publishing Code

Using GitHub releases and Zenodo DOIs
to create citable code snapshots

Stephen Formel

2026-01-29

Examples

Instrument: Low-Cost Water Sampler

Pipeline: eDNA analysis

Analysis: Biodiversity Indicators

Documentation: Workshop

Why publish code?


Better World

Better Future

make life easier!
reduce self-loathing!


Enable Science

drive reuse!
and extension!

Get Credit

credit is the currency of science!
mo’ money, less problems!

The long view: a haiku.


science lives when tools

fade. Links rot but snapshots save

your work from the void

Whale Fall Actively Devoured by Scavengers at Davidson Seamount, Nautilus Live (2019) https://www.youtube.com/watch?v=CZzQhiNQXxU

GitHub is not an archive

  • Excellent for collaboration
  • No preservation guarantee
  • Not designed for citation
  • owned by private corporation (Microsoft)

What is a code archive?


Persistent and referenced via PID

Findable and citable

Immutable once published

Backed by long-term infrastructure

(for code)

Generalist research repository

Free and widely used

Issues DOIs via DataCite

Integrates with GitHub releases

operated by CERN

+ model


GitHub: active development | where code lives

Zenodo: frozen snapshots | where code is cited

Where will you use this?

Instrument development

Pipeline development

Analysis iteration

Code-based documentation

Versioning and DOIs

Each GitHub release → new Zenodo version

Each version gets its own

One parent ‘concept’ always points to the latest version

Let’s Practice

Pre-work:

did you make a account?

If not, do it here

Step 1: Fork the Repository

  1. Go to the example repo on GitHub (https://github.com/the-data-patch/do-watcha-wanna)
  2. Click Fork (top right)
  3. You now have your own copy under your account

Step 2: Make a Change

  • Edit the rutgers.txt file
  • Commit your changes with a meaningful message

Step 3: Publish to Zenodo Sandbox

  1. Log in to Zenodo sandbox
  2. Activate the repository you forked
  3. Create a GitHub release (tag your commit)
  4. Zenodo generates a DOI for the release

Step 4: Make Additional Changes

  • Update code or documentation
  • Create a new release on GitHub
  • Observe new DOI generated by Zenodo

Step 5: Explore Examples

Look at successful uses of this mechanism:

Instrument: Low-Cost IoT Water Sampler

Pipeline: Tourmaline for eDNA analysis

Analysis: Using H3 Grids for Biodiversity Indicators

Documentation: Marine Data Mobilization Workshop

Step 6: Reflection

  • Could you explain this to a collaborator?