Skip to content

Instantly share code, notes, and snippets.

View fmartingr's full-sized avatar

Felipe Martin fmartingr

View GitHub Profile
@legowerewolf
legowerewolf / readme.md
Last active April 7, 2024 02:13
Tailscale on Steam Deck
@VITIMan
VITIMan / electronic_resources.md
Last active September 18, 2017 06:54
Electronics
@asukakenji
asukakenji / 0-go-os-arch.md
Last active April 23, 2025 07:37
Go (Golang) GOOS and GOARCH

Go (Golang) GOOS and GOARCH

All of the following information is based on go version go1.17.1 darwin/amd64.

GOOS Values

GOOS Out of the Box
aix
android
@troyfontaine
troyfontaine / 1-setup.md
Last active April 28, 2025 20:43
Signing your Git Commits on MacOS

Methods of Signing Git Commits on MacOS

Last updated March 13, 2024

This Gist explains how to sign commits using gpg in a step-by-step fashion. Previously, krypt.co was heavily mentioned, but I've only recently learned they were acquired by Akamai and no longer update their previous free products. Those mentions have been removed.

Additionally, 1Password now supports signing Git commits with SSH keys and makes it pretty easy-plus you can easily configure Git Tower to use it for both signing and ssh.

For using a GUI-based GIT tool such as Tower or Github Desktop, follow the steps here for signing your commits with GPG.

@mariocj89
mariocj89 / python-logging.md
Last active March 26, 2025 04:35
Understanding logging in Python

Logging trees

Introduction

When applications are running in production, they become black boxes that need to be traced and monitored. One of the simplest, yet main, ways to do so is logging. Logging allows us - at the time we develop our software - to instruct the program to emit information while the system is running that will be useful for us and our sysadmins.

@jorgesancha
jorgesancha / python_code_test_carto.md
Last active March 21, 2024 00:06
Python code test - CARTO
@logc
logc / pypkg.sh
Last active March 8, 2017 09:48
Python packages with Sphinx & Github pages
#!/usr/bin/env bash
pkg_name=$1
pkg_root=$PWD/${pkg_name}
doc_root=${pkg_root}/docs/_build/html
hostname=`hostname`
year=`date '+%Y'`
version='0.1.0'
@ergoithz
ergoithz / tzsnippet.js
Last active April 7, 2016 14:38
Javascript current TZ string (for ISO_8601)
/**
* This snipped generates the offset part of ISO_8601 datetime strings.
* Useful for composed datetime strings as required for APIs complying RFC3339.
*/
var
tz = (new Date()).getTimezoneOffset(),
pad = function (v){
var sv = Math.abs(parseInt(v, 10)).toString();
return '00'.substr(sv.length) + sv;
},
@angstwad
angstwad / dict_merge.py
Last active December 22, 2024 16:02
Recursive dictionary merge in Python
import collections
def dict_merge(dct, merge_dct):
""" Recursive dict merge. Inspired by :meth:``dict.update()``, instead of
updating only top-level keys, dict_merge recurses down into dicts nested
to an arbitrary depth, updating keys. The ``merge_dct`` is merged into
``dct``.
:param dct: dict onto which the merge is executed
:param merge_dct: dct merged into dct
@paulirish
paulirish / bling.js
Last active February 18, 2025 14:08
bling dot js
/* bling.js */
window.$ = document.querySelector.bind(document);
window.$$ = document.querySelectorAll.bind(document);
Node.prototype.on = window.on = function(name, fn) { this.addEventListener(name, fn); };
NodeList.prototype.__proto__ = Array.prototype;
NodeList.prototype.on = function(name, fn) { this.forEach((elem) => elem.on(name, fn)); };