Skip to content

Instantly share code, notes, and snippets.

View henriklindgren's full-sized avatar

Henrik Lindgren henriklindgren

View GitHub Profile
@henriklindgren
henriklindgren / gist:bc733ac1e99cac7fe84fa58eb1628223
Created April 18, 2024 14:40
Fallout 4 "Stealth Sniper" build from u/Ubergut @ reddit
Taken from https://www.reddit.com/r/Fallout4Builds/comments/3usal7/stealth_sniper_quickest_path_to_max_damage/
All text below is copied as is without formatting as backup
############################################
Stealth Sniper (Quickest Path to max damage)
So this build is designed for players who like to clear entire camps without once being heard, let alone seen. This build pretends that V.A.T.S doesn't even exist. Therefore, it is highly effective w/o the system but makes no effort to include it until well into late game. Below I list the perks chosen for the first 25 levels, some are definitely optional (Lone Wanderer most notably). Try to find a hunting or combat rifle asap and mod it extensively.
S P E C I A L
@henriklindgren
henriklindgren / 50-mousetrapper.conf
Created May 8, 2023 19:02
Linux Mint, Mousetrapper Advance 2.0 libinput xorg config, legacy
# /usr/share/X11/xorg.conf.d/50-mousetrapper.conf
#
# using "libinput debug-events --verbose", seems the scroll wheel report in 15 degree increments.
# Vertical scroll under-reports, horizontal works as promised. Not sure if hardware/software issue/choice in mousetrapper or just libinput issue.
Section "InputClass"
Identifier "MouseTrapper"
MatchUSBID "0d24:0010"
# Seems to be no need to match pointer even though it registers on keyboard as well
# MatchIsPointer "true"
Driver "libinput"
begin
0000 1b 00 50 60 44 da 04 e1 ff ff 00 00 00 00 09 00 ..P`D...........
0010 00 01 00 07 00 03 01 40 00 00 00 04 01 00 01 00 .......@........
0020 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
0030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
0040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
0050 00 00 00 00 00 00 00 00 00 00 00 ...........
set iso key < to red
0000 1b 00 10 00 95 d9 04 e1 ff ff 00 00 00 00 09 00 ................
@henriklindgren
henriklindgren / simple-pagination.js
Last active August 12, 2022 14:01 — forked from kottenator/simple-pagination.js
Simple pagination algorithm
function pagination(c, m) {
var current = c,
last = m,
delta = 2,
range = [],
previous = 1;
range.push(1);
for (var i = 2; i < last; i++) {
if (i < current && current - i === delta){
@henriklindgren
henriklindgren / deserialize_pydantic.py
Last active March 24, 2023 10:09
Unpack dict based on pydantic BaseModel into model
#This is free and unencumbered software released into the public domain.
#
#Anyone is free to copy, modify, publish, use, compile, sell, or
#distribute this software, either in source code form or as a compiled
#binary, for any purpose, commercial or non-commercial, and by any
#means.
#
#In jurisdictions that recognize copyright laws, the author or authors
#of this software dedicate any and all copyright interest in the
#software to the public domain. We make this dedication for the benefit
@henriklindgren
henriklindgren / avanzaparse.py
Last active February 16, 2018 17:40
Avanza stock quotes snippet
#!/usr/bin/env python2
# coding:utf-8
from bs4 import BeautifulSoup
import requests
import sys
urls = [
'https://www.avanza.se/aktier/om-aktien.html/5466/mycronic',
]