Skip to content

Instantly share code, notes, and snippets.

View diffficult's full-sized avatar
💽
the big switcharoo

reese diffficult

💽
the big switcharoo
View GitHub Profile
@diffficult
diffficult / managing-the-gpg-agent.md
Created November 5, 2024 14:41 — forked from CMCDragonkai/managing-the-gpg-agent.md
Managing the gpg-agent #nix #gpg

Managing the gpg-agent

These are the standard commands:

gpgconf --list-dirs
gpgconf --kill gpg-agent
gpgconf --reload gpg-agent
@diffficult
diffficult / AuthyToOtherAuthenticator.md
Created February 15, 2020 05:41 — forked from gboudreau/AuthyToOtherAuthenticator.md
Export TOTP tokens from Authy

Generating Authy passwords on other authenticators


There is an increasing count of applications which use Authy for two-factor authentication. However many users who aren't using Authy, have their own authenticator setup up already and do not wish to use two applications for generating passwords.

Since I use 1Password for all of my password storing/generating needs, I was looking for a solution to use Authy passwords on that. I couldn't find any completely working solutions, however I stumbled upon a gist by Brian Hartvigsen. His post had a neat code with it to generate QR codes (beware, through Google) for you to use on your favorite authenticator.

His method is to extract the secret keys using Authy's Google Chrome app via Developer Tools. If this was not possible, I guess people would be reverse engineering the Android app or something like that. But when I tried that code, nothing appeared on the screen. My gues

@diffficult
diffficult / pi_mount_usb.md
Last active August 1, 2021 22:38 — forked from etes/pi_mount_usb.md
How to setup mount / auto-mount USB Hard Drive on Raspberry Pi

How to setup mount / auto-mount USB Hard Drive on Raspberry Pi

Follow the simple steps in the order mentioned below to have your USB drive mounted on your Raspberry Pi every time you boot it.

These steps are required especially if your are setting up a Samba share, or a 24x7 torrent downloader, or alike where your Raspberry Pi must have your external storage already mounted and ready for access by the services / daemons.

Step 0. Plug in your USB HDD / Drive to Raspberry Pi If you are using a NTFS formatted drive, install the following

@diffficult
diffficult / docker-cleanup-resources.md
Created February 18, 2019 15:34 — forked from bastman/docker-cleanup-resources.md
docker cleanup guide: containers, images, volumes, networks

Docker - How to cleanup (unused) resources

Once in a while, you may need to cleanup resources (containers, volumes, images, networks) ...

delete volumes

// see: https://github.com/chadoe/docker-cleanup-volumes

$ docker volume rm $(docker volume ls -qf dangling=true)

$ docker volume ls -qf dangling=true | xargs -r docker volume rm

@diffficult
diffficult / try_to_fix_[drm_kms_helper]_in_english.md
Created October 30, 2018 15:55 — forked from i0z0m/[drm_kms_helper]-flip_done-timed-out.md
[drm:drm_atomic_helper_wait_for_dependencies [drm_kms_helper]] *ERROR* [CRTC:37:pipe A] flip_done timed out.

a symptom

I am the Japanese and not good at writng English. I'm sorry to my language ability for you.
I sometimes get the following error when logging out of Xorg. It's a little different to [xf86-video-intel] flip_done timed out, but it's similar.
[drm:drm_atomic_helper_wait_for_dependencies [drm_kms_helper]] ERROR [CRTC:37:pipe A] flip_done timed out.

Using the video=SVIDEO-1:d kernel parameter doesn't work for me.
I'm running Arch Linux (4.17.2-1) on my laptop ThinkPad X220 with xf86-video-intel (my CPU is an i5-2540M).

$ dmesg
$ hwinfo

@diffficult
diffficult / statusgit
Created May 16, 2018 02:19 — forked from armeenm/statusgit
Update all git repositories recursively.
#!/bin/bash
declare -a COLORS
j=0
# Default colors are light for dark terminals.
# Use '-l' option for normal (darker) text.
# Red, green, yellow, blue, magenta, cyan.
for i in {91..96}; do COLORS[$j]=$i; let "j++"; done
usage() {
@diffficult
diffficult / gist:ac00c706dda17f114a1f243af4667700
Created April 4, 2018 23:21 — forked from fabiofl/gist:5873100
Clear Mac OS X's icon cache.
sudo find /private/var/folders/ -name com.apple.dock.iconcache -exec rm {} \;
@diffficult
diffficult / pixel-arch.md
Last active November 14, 2016 01:55 — forked from thirteen37/pixel-arch.md
Installing Arch on the Chromebook Pixel 2015

This describes a basic Arch Linux installation on a Chromebook Pixel 2015.

Note: I'm a coward, so I installed Arch to an SD card instead of wiping out the existing SSD.

Requirements

  • SD card. A very minimal Arch installation with XFCE will need about 2GB, so I think 4GB is the minimum you can get by with.
  • Arch installer on a USB drive. The 2013.05.01 is broken with the recent netctl change. So either get an older or newer one.
  • Some Arch Linux familiarity.
  • Time, patience, and good eyesight.
@diffficult
diffficult / chromeos-crosh-custom-setup.md
Last active October 4, 2024 08:41 — forked from bramford/chromeos-crosh-custom-setup.md
Customize your ChromeOS fonts - working April 2017

Customize Chromebook Chrosh Shell Environment

Requirement: Chromebook, Common Sense, Commandline Ablity, 1 hour of time

Dear developers with a spare Chromebook lets inject a little personalization into your Crosh shell with custom fonts, the solarized theme, and extra secure shell options.

Also, keep in mind that the terms Chrosh, Chrosh Window, and Secure Shell all refer to various versions and extentions built around the ChromeOS terminal. Settings that affect the ChromeOS terminal are global.

Custom Fonts

@diffficult
diffficult / edgerouter-qos
Last active July 9, 2023 16:32 — forked from beardicus/edgerouter-qos
EdgeRouter Lite QOS Settings
#
# fair-queue based settings for EdgeRouter Lite traffic shaping
#
# download is typically 6 and change. everything can burst to 100%
# of bandwidth, priority rules keep the garbage in check
set traffic-policy shaper download
set traffic-policy shaper download bandwidth 30Mbit