Skip to content

Instantly share code, notes, and snippets.

View null-dev's full-sized avatar
💭
I may be slow to respond.

Andy Bao null-dev

💭
I may be slow to respond.
View GitHub Profile
@TheSunCat
TheSunCat / usb-sounds-udev.md
Last active August 14, 2022 14:24
USB Sounds on Linux using udev!

This is an overview of how I configured my system to play a sound when a USB device (such as a flash drive) is plugged in.

Requirements

  • Linux install with udev and systemd.
  • Root access.
  • A utility to play sounds (I used aplay).
  • Sounds to play.

Playing a sound

Using the tool aplay (found in the Arch package alsa-utils), it is easy to play an audio file: aplay insert.wav

@moyix
moyix / killbutmakeitlooklikeanaccident.sh
Created February 5, 2022 22:51
Script to inject an exit(0) syscall into a running process. NB: only x86_64 for now!
#!/bin/bash
gdb -p "$1" -batch -ex 'set {short}$rip = 0x050f' -ex 'set $rax=231' -ex 'set $rdi=0' -ex 'cont'
@Zyst
Zyst / KeyBR Colemak-DH ANSI.js
Last active November 21, 2023 07:18
Makes the KeyBR Colemak Layout be Colemak-DH on an ANSI Keyboard. Install with TamperMonkey
// ==UserScript==
// @name KeyBR Colemak-DH
// @namespace http://tampermonkey.net/
// @version v1.1
// @description Switch Colemak layout in keybr.com to Colemak DH
// @author https://github.com/Zyst
// @match https://www.keybr.com/
// @icon https://www.google.com/s2/favicons?domain=keybr.com
// @grant none
// @contributors https://github.com/hilarycheng
@ZipFile
ZipFile / README.md
Last active May 4, 2024 04:28
Pixiv OAuth Flow

Retrieving Auth Token

  1. Run the command:

    python pixiv_auth.py login

    This will open the browser with Pixiv login page.

@Chick3nman
Chick3nman / RTX_3080_v6.1.1.Benchmark
Created September 24, 2020 23:47
Hashcat v6.1.1 benchmark on the Nvidia RTX 3080
NVIDIA Driver Version: 455.23.05 CUDA Version: 11.1
Credit: r4d1x
For benchmarking the card and allowing me to release the benchmarks here
There are a handful of algorithms failing, mostly appears related to SCRYPT and
is liking a tuning issue or small driver issue that we will need to take a look at.
Otherwise, seems fairly stable.
@Raymo111
Raymo111 / UWaterloo Mail.md
Last active January 23, 2022 23:37
How to connect to UWaterloo's new email system via any mail client

How to connect to UWaterloo's new email system via any mail client

By Raymond Li (Raymo111), July 1st, 2020 (Happy Canada Day!)

Last updated 12 Sept 2021
Credits to PixlOne for O365Interactive mode and headless Davmail

Step 1: Get Davmail.

  • I'm on Arch Linux, so I installed it from the AUR.
@insdavm
insdavm / WireGuard-site-to-site.md
Last active May 3, 2024 21:19
Accessing a subnet that is behind a WireGuard client using a site-to-site setup

WireGuard Site-to-Site

Accessing a subnet that is behind a WireGuard client using a site-to-site setup

Problem Summary

We want to access a local subnet remotely, but it is behind a NAT firewall and we can't setup port forwarding. Outgoing connections work, but all incoming connections get DROPPED by the ISP's routing policy.

Solution Summary

@bweston92
bweston92 / indexes.go
Created September 4, 2018 14:17
MongoDB Golang Driver Ensure Index
package mgoutil
import (
"context"
"github.com/mongodb/mongo-go-driver/bson"
"github.com/mongodb/mongo-go-driver/mongo"
"github.com/pkg/errors"
)
@null-dev
null-dev / TachiTest.kt
Last active April 17, 2018 01:24
Automated Tachiyomi source tester
import android.content.Context
import android.graphics.Color
import android.preference.PreferenceManager
import android.support.design.widget.TabLayout
import android.support.test.InstrumentationRegistry
import android.support.test.espresso.Espresso
import android.support.test.espresso.Espresso.onIdle
import android.support.test.espresso.Espresso.onView
import android.support.test.espresso.UiController
import android.support.test.espresso.ViewAction
@bretton
bretton / lightning-maps.md
Last active December 29, 2023 02:59
Visualisers of the Lightning Network (and some other explorers)

A (mostly) visual collection of the Lightning Network

Disclaimer

Network views tend to be the view of the network from a single node, or small selection of nodes. They are not complete views of the network. This is impossible to achieve. Even if many node views were combined, it would still be incomplete.

These network views, or network maps, have been termed 'visualisers' by the LN community.

Screenshots may reflect older visual styles, and are dated accordingly.