Skip to content

Instantly share code, notes, and snippets.

mewmew / gist:68a25a58fd70eab1384e6407357e05b3
Created July 9, 2022 11:14 — forked from alphazo/gist:3303282
Clone MiFare cards using chinesse UUID writable cards
View gist:68a25a58fd70eab1384e6407357e05b3

libnfc supports UUID writable cards and even has some dedicated tools for them.

However it doesn't work with some of the cards found on eBay that are even simpler to use. Sector 0 is unlocked and can be written without any additional commands. libnfc requires a small patch to get it working.

Following has been tested under ArchLinux with modified libnfc 1.5.1, mfoc 0.10.2 and a SCL3711 dongle.

Patch & recompile libnfc

The patch is fairly simple, open libnfc-1.5.1/utils/nfc-mfclassic.c and comment 2 lines (it was lines 384 and 385 for me):

// Try to write the trailer

mewmew / unmarshal_interface.go
Created August 31, 2021 14:55 — forked from tkrajina/unmarshal_interface.go
Unmarshal JSON to specific interface implementation
View unmarshal_interface.go
package main
import (
type Something interface{}
mewmew / gist:18188e49df6926cf001b381a7927032d
Created April 16, 2021 09:05 — forked from BastienClement/gist:b34f14dd93381498a7a1
The CASC (Content Addressable Storage Container) Filesystem
View gist:18188e49df6926cf001b381a7927032d
| The CASC (Content Addressable Storage Container) Filesystem |
| Warlords of Draenor Alpha, Build |
| Written April 14th, 2014 by Caali |
| Version 1.2 |
Distribution and reproduction of this specification are allowed without
limitation, as long as it is not altered. Quotation in other works is
freely allowed, as long as the source and author of the quote are stated.

Ten seconds to ponder if a thread is worth it


A userstyle that makes you wait ten seconds before entering a Hacker News thread. I use stylus to manage mine.

.subtext {
  display: inline-block;
 background: linear-gradient(to left, transparent 50%, #f60 50%) right;
mewmew /
Created January 5, 2021 17:50 — forked from prologic/
Learn Go in ~5mins
mewmew /
Created October 27, 2020 00:30 — forked from myusuf3/
How effectively delete a git submodule.

To remove a submodule you need to:

  • Delete the relevant section from the .gitmodules file.
  • Stage the .gitmodules changes git add .gitmodules
  • Delete the relevant section from .git/config.
  • Run git rm --cached path_to_submodule (no trailing slash).
  • Run rm -rf .git/modules/path_to_submodule (no trailing slash).
  • Commit git commit -m "Removed submodule "
  • Delete the now untracked submodule files rm -rf path_to_submodule
mewmew /
Created April 24, 2020 16:38 — forked from raysan5/
A small state-of-the-art study on custom engines



A couple of weeks ago I played (and finished) A Plague Tale, a game by Asobo Studio. I was really captivated by the game, not only by the beautiful graphics but also by the story and the locations in the game. I decided to investigate a bit about the game tech and I was surprised to see it was developed with a custom engine by a relatively small studio. I know there are some companies using custom engines but it's very difficult to find a detailed market study with that kind of information curated and updated. So this article.

Nowadays lots of companies choose engines like Unreal or Unity for their games (or that's what lot of people think) becaus

#!/usr/bin/env python3
import librosa
import numpy as np
from pathlib import Path
import pandas as pd
class WaveFile(object):
filename = None
mewmew / main.c
Created February 6, 2020 01:48
Proof of concept to render first cutscene of Diablo 1.
View main.c
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "diablo.h"
#include "dx.h"
#include "init.h"
#include "interfac.h"
void StoreScreenshot();
mewmew /
Created January 17, 2020 03:40 — forked from alexander-hanel/
old and new names in (in progress)
import re
import sys
import os
def load_apis():
new_old_apis = [
# start of changes for
("hasValue", "has_value"),
("byteValue", "byte_value"),
("isLoaded", "is_loaded"),