Skip to content

Instantly share code, notes, and snippets.

View g4brielvs's full-sized avatar

Gabriel Stefanini Vicente g4brielvs

View GitHub Profile
@g4brielvs
g4brielvs / just_intonation.py
Created February 15, 2020 07:29 — forked from endolith/readme.md
Just intonation classes for music theory experiments in Python
# -*- coding: utf-8 -*-
"""
Created on Wed Jul 30 18:55:13 2014
Just intonation classes for music theory experiments in Python
"""
from __future__ import division, print_function
from fractions import gcd as _gcd
from fractions import Fraction
@g4brielvs
g4brielvs / cursed_starwars_data.R
Created December 10, 2019 01:28 — forked from brooke-watson/cursed_starwars_data.R
cursed_data_challenge
# ---------------------------------------
# untidy data
# ---------------------------------------
# this dataset is a sample of the kind of data that might appear in the wild,
# particularly when dealing with government data,
# particularly when trying to convert an output table or individual report
# back into a raw data format that can be analyzed.
# in these test datasets, discrete observations are spread out across multiple rows.
@g4brielvs
g4brielvs / gpg-import-and-export-instructions.md
Created December 7, 2017 19:54 — forked from chrisroos/gpg-import-and-export-instructions.md
Instructions for exporting/importing (backup/restore) GPG keys

Every so often I have to restore my gpg keys and I'm never sure how best to do it. So, I've spent some time playing around with the various ways to export/import (backup/restore) keys.

Method 1

Backup the public and secret keyrings and trust database

cp ~/.gnupg/pubring.gpg /path/to/backups/
cp ~/.gnupg/secring.gpg /path/to/backups/
cp ~/.gnupg/trustdb.gpg /path/to/backups/

or, instead of backing up trustdb...