Skip to content

Instantly share code, notes, and snippets.

View cicirello's full-sized avatar

Vincent A. Cicirello cicirello

View GitHub Profile
@cicirello
cicirello / Add metadata to a pdf using pdflatex.md
Last active May 10, 2021 14:23
Add metadata to a pdf using pdflatex

Add metadata to a pdf using pdflatex

Usage

  1. Edit AddMetadataToPdf.tex with the name of the original pdf file.
  2. Edit AddMetadataToPdf.tex with the metadata you want to add to it.
  3. Run pdflatex AddMetadataToPdf.tex.
  4. Replace original pdf with AddMetadataToPdf.pdf.
@cicirello
cicirello / Combine multiple pdfs using pdflatex.md
Last active May 10, 2021 14:20
Combine multiple pdfs using pdflatex

Combine multiple pdfs using pdflatex

Purpose

To combine multiple pdf files into a single pdf file

Usage

  1. Edit CombinePDFs.tex with the name of the pdfs you wish to combine.
  2. Place in same directory with the pdfs you are combining.
@cicirello
cicirello / Automated Update of Major Release Tag for a GitHub Action.md
Last active May 10, 2021 14:15
Workflow to automate maintaining major release tag for GitHub Actions (e.g., from v3.1.2 to v3)

Automated Update of Major Release Tag

Purpose

GitHub's documentation for developers of GitHub Actions recommend that in addition to specific tagged releases with SemVer release numbers that a major release tag is maintained and moved to point to the most recent specific version. For example, let's say that you just release v3.1.2 (with corresponding tag). The recommendation is to then move a v3 tag to point to that new version. This gives users of the action the option to use specific release version, such as v3.1.2, or to just use the major release number, v3, which enables them to automatically gain the benefit of any bug fixes without updating their workflows.

What This Workflow Does

When you create a release, this workflow runs. It assumes that the release tag is of the form, vX.Y.Z (where X, Y, and Z are the major, minor, and patch numbers of a SemVer version). From this, it extracts the major version forming a string of the form vX. It then adds (if it doesn't exist) or moves (if it does e