Skip to content

Instantly share code, notes, and snippets.

@jkutner
jkutner / atik-indi-phd2-raspbian-instructions.md
Last active December 28, 2024 02:13
Turn a Raspberry Pi into an Astrophotography Autoguider
@ryan-williams
ryan-williams / path-qr.md
Last active December 28, 2024 02:09
QR codes for the Hudson County Complete Streets campaign for increased PATH train service
@blasferna
blasferna / py_calcular_dv.py
Created October 22, 2020 10:27
Calculador de dígito verificador del Registro Único del Contribuyente de Paraguay
#!/usr/bin/env python
# -*- coding: utf-8 -*-
def calcular_dv(ruc):
"""
Función que calcula el dígito verificador en Python
"""
#Convierte el argumento en string
#luego invierte los valores
<svg width="300" height="300" viewBox="0 0 300 300">
<defs>
<filter id="paperEffect">
<feTurbulence
type="fractalNoise"
baseFrequency="0.04"
numOctaves="5"
result="noise"
/>
<feDiffuseLighting
@gmolveau
gmolveau / firefox_dark_background.md
Last active December 28, 2024 01:52
Firefox dark background / theme for new tab and loading screen

Firefox Dark Background

  • How to change the background on Firefox to a dark one on new tab / loading screen ?

Procedure

  • Type about:config in the URL bar
  • Search toolkit.legacyUserProfileCustomizations.stylesheets and double-click the field to set it to true
  • Type about:support in the URL bar
  • Look for Profile folder field and click on the open button next to it.
@jbaranski
jbaranski / ffmpeg_mac_m1_record_cmd_line.md
Last active December 28, 2024 01:51
ffmpeg record screen on Mac M1 chip via command line

ffmpeg record screen on Mac M1 chip via command line

  1. Install ffmpeg.

brew install ffmpeg

  1. Figure out which device to use.

ffmpeg -f avfoundation -list_devices true -i ""

Ouput will look like:

@roadrunner2
roadrunner2 / 0 Linux-On-MBP-Late-2016.md
Last active December 28, 2024 01:50
Linux on MacBook Pro Late 2016 and Mid 2017 (with Touchbar)

Introduction

This is about documenting getting Linux running on the late 2016 and mid 2017 MPB's; the focus is mostly on the MacBookPro13,3 and MacBookPro14,3 (15inch models), but I try to make it relevant and provide information for MacBookPro13,1, MacBookPro13,2, MacBookPro14,1, and MacBookPro14,2 (13inch models) too. I'm currently using Fedora 27, but most the things should be valid for other recent distros even if the details differ. The kernel version is 4.14.x (after latest update).

The state of linux on the MBP (with particular focus on MacBookPro13,2) is also being tracked on https://github.com/Dunedan/mbp-2016-linux . And for Ubuntu users there are a couple tutorials (here and here) focused on that distro and the MacBook.

Note: For those who have followed these instructions ealier, and in particular for those who have had problems with the custom DSDT, modifying the DSDT is not necessary anymore - se

@rrafal
rrafal / sqlx_json.go
Created March 31, 2016 00:02
Use JSON field with golang sqlx driver
package main
import (
"encoding/json"
"errors"
"database/sql/driver"
"fmt"
"github.com/jmoiron/sqlx"
_ "github.com/lib/pq"
"log"
@endofunky
endofunky / service.macchanger.nix
Created July 5, 2021 19:56
macchanger/systemd for NixOS
{ config, lib, pkgs, ...}:
with lib;
let
cfg = config.sec.macchanger;
in {
options = {
sec.macchanger = {
enable = mkOption {