Skip to content

Instantly share code, notes, and snippets.

View sbibauw's full-sized avatar

Serge Bibauw sbibauw

View GitHub Profile
@charset "UTF-8";
/*!
* Marp / Marpit Terra theme, adapted from Gaia.
*
* @theme terra
* @author Yuki Hattori + Serge Bibauw
*
* @auto-scaling true
* @size 16:10 1280px 800px
*/
@sbibauw
sbibauw / 1-paypalcsv
Last active June 22, 2021 22:29
Paypal transactions API retrieval → JSON → CSV → hledger-flow import → hledger import rules
#!/usr/bin/env bash
# Download last 30 days of transaction history from Paypal as CSV.
# Adapted from Simon Michael: gist.github.com/simonmichael/62cc9661569cdea990dc2020ac36582a
# REQUIREMENTS:
# brew install jsonpp jq
# npm install -g json2csv
# USAGE:
@sbibauw
sbibauw / rename_pdf_doi.sh
Last active May 27, 2021 23:53
Rename PDF as AuthorYear.pdf from Crossref DOI data
# Used as an embedded shell script in Hazel for files where a DOI is available
#
# Depedencies:
# - pdfgrep
# - curl
# - jq
newname=$(pdfgrep -oPm 1 --page-range=1-2 '\b10.\d{4,9}/[-._;()/:A-Za-z0-9]+\b' $1 |
xargs -I{} curl -sLH "Accept: application/json" http://dx.doi.org/{} |
jq '.author[0].family, .issued."date-parts"[0][0]' |
@charset "UTF-8";
/*!
* Marp / Marpit Gaia theme.
*
* @theme terra2
* @author Yuki Hattori + Serge Bibauw
*
* @auto-scaling true
* @size 4:3 960px 720px
@sbibauw
sbibauw / terra.css
Last active June 9, 2023 05:32
Theme for Marp, adapted from Gaia
@charset "UTF-8";
/*!
* Marp / Marpit Terra theme, adapted from Gaia.
*
* @theme terra
* @author Yuki Hattori + Serge Bibauw
*
* @auto-scaling true
* @size 16:9 1280px 720px
*/
@sbibauw
sbibauw / zoom_archiving.sh
Last active January 7, 2021 06:51
Archiving and optimization of local Zoom recordings and chat logs
#!bin/sh
# What it does:
# - Chat logs archived in a zoom_archive subfolder with the date and name of the meeting in the filename
# - Video recordings resized down (to a maximum width of 980 px) and renamed (date and name of meeting + number)
# - All other files (playlists, audio recordings) moved to the trash
cd ~/Zoom
# For each subfolder

Keybase proof

I hereby claim:

  • I am sbibauw on github.
  • I am sbibauw (https://keybase.io/sbibauw) on keybase.
  • I have a public key ASA7oHsZphnHL28ePWmXMrAGWNHHtKXq-KVGQvpF6M2oQAo

To claim this, I am signing this object: