Skip to content

Instantly share code, notes, and snippets.

View schrmh's full-sized avatar
💭
Little time; many projects

schrmh

💭
Little time; many projects
View GitHub Profile
@Joshix-1
Joshix-1 / packages-gist.hook
Last active February 16, 2021 19:45
If you want to use it for your self change the url to the gist. More info about how to use this hook: https://wiki.archlinux.org/index.php/Pacman#Hooks
[Trigger]
Operation = Install
Operation = Remove
Operation = Upgrade
Type = Package
Target = *
[Action]
Description = Update gist with all installed pacman packages.
When = PostTransaction
Depends = gist
#Much code taken from https://github.com/roxas75/rxTools/blob/012a9c2fe99f2d421e68ae91f738b4028995ad67/tools/scripts/ncchinfo_gen.py
#Uses some bits and pieces from https://github.com/Mtgxyz2/3ds-FUSE
#Comments are for people that care about being able to read their code tommorrow :P
from __future__ import print_function
import os, sys, glob, struct
from Crypto.Cipher import AES
from Crypto.Util import Counter
from hashlib import sha256
from ctypes import *
from binascii import hexlify, unhexlify
@IvanCl4udio
IvanCl4udio / gist:b606735bedcdcdea7cb7a9790d96ca74
Last active April 26, 2026 15:01
How configure P4Merge as merge and diff tool on Linux

How configure P4Merge as merge and diff tool on Linux

If you like me use a Linux station to do your development and don't want to use the standard Git diff tool this Gist is for you.

Installation

  1. Download installation from Perforce Web Site

https://www.perforce.com/downloads/visual-merge-tool

@larsenv
larsenv / Using pisg with Discord.md
Created April 2, 2019 23:29
Use pisg, a program that takes IRC logs and makes a webpage about statistics of the chat, with Discord.

Using pisg with Discord

This tutorial will briefly tell you how to use pisg, a program that takes IRC logs and makes a webpage about statistics of the chat, with Discord.

Instructions

  1. Use DiscordChatExporter to generate a log of the chat you want to use pisg with. You need to make it saved in the PlainText format. I prefer the command-line version of the tool. (If you're on Linux/Mac, run this tool with mono.)
  2. Run my Python script to convert the log into a format that pisg can read (the "mbot" format).
  3. Run pisg with the command that the script outputs.
@bgauduch
bgauduch / 0 - Multiple git identities on one machine.md
Last active November 11, 2026 03:40
Multiple git identities on one machine: config per folder and per provider (personal vs work). Every command verified.

Multiple git identities on one machine

One machine, several git identities (personal vs work, GitHub vs GitLab, two accounts on one provider). Each repository picks its own name, email and credentials. In a hurry: Appendix B, once per rule.

A wrong identity does not fail: git commits and pushes under the wrong author. Part 1 ends with the check that catches it.

Requirements

Feature Minimum git
@ernestkamara
ernestkamara / AdbCommands
Created June 26, 2018 08:42 — forked from Pulimet/AdbCommands
Adb useful commands list
== Adb Server
adb kill-server
adb start-server
== Adb Reboot
adb reboot
adb reboot recovery
adb reboot-bootloader
== Shell
ROM:0001A020 DCD 4, 0
ROM:0001A028 DCD 0x203, 9, 0
ROM:0001A034 DCD 0x484A0190, 0x65324741, 5, 0, 0, 0
ROM:0001A04C DCD 0x2A052, 0xAA00AA00, 0xAA00AA00, 0x44584493, 0x1000000
ROM:0001A04C DCD 0xF0048683, 0xA00631D1, 0xBF0D0401, 0x180AE3F, 0xD1643842
ROM:0001A04C DCD 0x8888, 0x88888888, 0, 0
ROM:0001A084 DCD 0x11000D20, 0x7800000, 0x4002600, 0x40000000, 0x40000000
ROM:0001A084 DCD 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:0001A0C8 DCD 0xC30001, 0x60002, 0x20003, 6, 0xFF000A, 0x3F, 0
ROM:0001A0E4 DCD 0x203, 9, 0
@saitoha
saitoha / .vimrc
Created December 3, 2013 22:56
Vimで画像を見る(DRCSのSIXEL拡張の話) ref: http://qiita.com/kefir_/items/78e64c545a70a0ebea8a
" Vimであいまいな幅の文字の論理幅を1にします
set ambiwidth=single
" RLoginであいまいな幅の文字の論理幅を1にします。
call writefile(["\e[?8428h"], '/dev/tty')
@pioz
pioz / autoclick.c
Last active July 10, 2023 15:24
Autoclick
// Written by Pioz.
// Compile with: gcc -o autoclick autoclick.c -lX11
#include <stdio.h> // printf, fprintf and fflush
#include <string.h> // memset
#include <unistd.h> // sleep and usleep
#include <X11/Xlib.h> // X11
#include <X11/Xutil.h> // XGetPixel and XDestroyImage
// Simulate mouse click