Skip to content

Instantly share code, notes, and snippets.

@satnami
satnami / AuthyToOtherAuthenticator.md
Created February 24, 2025 10:52 — forked from gboudreau/AuthyToOtherAuthenticator.md
Export TOTP tokens from Authy

Exporting your 2FA tokens from Authy to transfer them into another 2FA application

IMPORTANT - Update regarding deprecation of Authy desktop apps

Past August 2024, Authy stopped supported the desktop version of their apps:
See Authy is shutting down its desktop app | The 2FA app Authy will only be available on Android and iOS starting in August for details.

And indeed, after a while, Authy changed something in their backend which now prevents the old desktop app from logging in. If you are already logged in, then you are in luck, and you can follow the instructions below to export your tokens.

If you are not logged in anymore, but can find a backup of the necessary files, then restore those files, and re-install Authy 2.2.3 following the instructions below, and it should work as expected.

Estimation

This document is an attempt to pin down all the things you don't think about when quoting for a project, and hopefully provide a starting point for some kind of framework to make quoting, working and delivering small-medium jobs more predictable and less stressful.

Contents

@satnami
satnami / README.md
Created July 25, 2024 08:50 — forked from DewaldDeJager/README.md
Easy GitHub workflow for keeping a fork in sync with upstream

Sync Fork

This workflow uses the GitHub CLI to keep a forked repo in sync with the upstream repo. Add it to your repo as .github/workflows/sync-fork.yaml.

It runs daily to sync the default branch and can be triggered manually for any branch.

@satnami
satnami / bijective.rb
Created May 21, 2023 19:59 — forked from zumbojo/bijective.rb
Simple bijective function (base(n) encode/decode)
# Simple bijective function
# Basically encodes any integer into a base(n) string,
# where n is ALPHABET.length.
# Based on pseudocode from http://stackoverflow.com/questions/742013/how-to-code-a-url-shortener/742047#742047
ALPHABET =
"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789".split(//)
# make your own alphabet using:
# (('a'..'z').to_a + ('A'..'Z').to_a + (0..9).to_a).shuffle.join
@satnami
satnami / android-backup-apk-and-datas.md
Created April 27, 2023 10:22 — forked from AnatomicJC/android-backup-apk-and-datas.md
Backup android app, data included, no root needed, with adb

Backup android app, data included, no root needed, with adb

adb is the Android CLI tool with which you can interact with your android device, from your PC

You must enable developer mode (tap 7 times on the build version in parameters) and install adb on your PC.

Don't hesitate to read comments, there is useful tips, thanks guys for this !

Fetch application APK

@satnami
satnami / update-expired-apt-keys.sh
Last active September 14, 2021 10:27
Update expired apt keys
# https://serverfault.com/questions/7145/what-should-i-do-when-i-got-the-keyexpired-error-message-after-an-apt-get-update
# hkp://keyserver.ubuntu.com:80
# keys.gnupg.net
# for key in $(sudo apt-key list | awk -v FS='[ /:]+' '/expire[sd]/ {print $3}'); do sudo apt-key adv --recv-keys --keyserver keys.gnupg.net $key; done
for key in $(apt-key list | awk -v FS='[ /:]+' '/expire[sd]/ {print $3}'); do apt-key adv --recv-keys --keyserver hkp://keyserver.ubuntu.com:80 $key; done
@satnami
satnami / takeout_gmail_senders_cleanup.sh
Last active September 1, 2021 05:17
Finding the Most Frequent Senders in Your Gmail Account
# From https://ryanfb.github.io/etc/2019/08/26/finding_the_most_frequent_senders_in_your_gmail_account.html
# Go to https://takeout.google.com/
# Select only Mail as mbox file
grep '^From:' ~/Downloads/Takeout/Mail/All\ mail\ Including\ Spam\ and\ Trash.mbox | cut -d'<' -f2 | tr -d '>' | sort | uniq -c | sort -rn > senders.txt
@satnami
satnami / dump-db-to-yml-fixture.rake
Created June 1, 2021 09:24
Dump DB to YML Fixtures
# https://stackoverflow.com/a/12188782
namespace :db do
namespace :fixtures do
desc 'Create YAML test fixtures from data in an existing database. Defaults to development database. Specify RAILS_ENV=production on command line to override.'
task :dump => :environment do
sql = 'SELECT * FROM %s ORDER BY ID'
skip_tables = ['schema_migrations']
# ActiveRecord::Base.establish_connection(Rails.env)
(ActiveRecord::Base.connection.tables - skip_tables).each do |table_name|
i = '000'
@satnami
satnami / system-design-template.md
Last active August 30, 2021 09:57
System Design Template

(1) FEATURE EXPECTATIONS [5 min]

    (1) Use cases
    (2) Scenarios that will not be covered
    (3) Who will use
    (4) How many will use
    (5) Usage patterns

(2) ESTIMATIONS [5 min]

    (1) Throughput (QPS for read and write queries)
    (2) Latency expected from the system (for read and write queries)

(3) Read/Write ratio

@satnami
satnami / 0000_feature_template.md
Created May 2, 2021 23:03
RFC Feature Template
  • Feature Name: (fill me in with a unique ident, my_awesome_feature)
  • Start Date: (fill me in with today's date, YYYY-MM-DD)
  • RFC PR: project/rfcs#0000
  • Proect Issue: project/rust#0000

Summary