Skip to content

Instantly share code, notes, and snippets.

View Patryk27's full-sized avatar
🦀
git goes rerere

Patryk Wychowaniec Patryk27

🦀
git goes rerere
View GitHub Profile
@knedlsepp
knedlsepp / default.nix
Last active June 15, 2020 16:40
How to pin a nix version in a default.nix file. (Override the pinned version via: nix-shell --arg nixpkgs '<nixpkgs>')
{nixpkgs ? null}:
let
sysPkg = import <nixpkgs> { };
pinnedPkg = sysPkg.fetchFromGitHub {
owner = "NixOS";
repo = "nixpkgs";
rev = "cf62a27a326a9cdbb01d627b1faaea3a0d5e886c";
sha256 = "1q74ciqq5r17vidw2025x8idsncz9k7w60warrij4q7piaffgvd7";
};
pkgs = if nixpkgs==null then
@sloanlance
sloanlance / jq_jsonl_conversion.md
Last active July 17, 2024 15:43
jq: JSONL ↔︎ JSON conversion

jq: JSONL ↔︎ JSON conversion

Prerequisites

  • jqhttps://jqlang.github.io/jq/ — "like sed for JSON data"

    There are several options available for installing jq. I prefer to use Homebrew: brew install jq

  1. JSONL → JSON

@Informatic
Informatic / domain.xml
Last active July 3, 2024 18:08
How to use Windows 10 OEM license in libvirt VM (<smbios mode='host' /> does not work as Windows seems to verify UUID; apparmor/security configuration changes may be needed)
<domain type='kvm' xmlns:qemu='http://libvirt.org/schemas/domain/qemu/1.0'>
<!-- ... -->
<qemu:commandline>
<qemu:arg value='-acpitable'/>
<qemu:arg value='file=/some/path/slic.bin'/>
<qemu:arg value='-acpitable'/>
<qemu:arg value='file=/some/path/msdm.bin'/>
<qemu:arg value='-smbios'/>
<qemu:arg value='file=/some/path/smbios_type_0.bin'/>
<qemu:arg value='-smbios'/>
@bellinitte
bellinitte / image.png
Last active October 6, 2021 18:36
Displaying an image on a Nokia 5510 LCD controlled by an ATmega328P
image.png