Skip to content

Instantly share code, notes, and snippets.

View x86-39's full-sized avatar

Jasmijn Emilia Rosalina Knoope 🌸 x86-39

View GitHub Profile
@x86-39
x86-39 / i hate linux users. that includes myself.md
Last active November 20, 2024 12:17
pissing off linux users

i ranted about linux to someone after i got pinged in bullshit someone thinking "oh this person knows linux theyll wanna help with my custom whatevershit nix install" NO I DONT
im gonna paste it here:

So
Hot takes incoming.
i have some very strong opinions about desktop linux despite not actually really being in the sphere anymore
i mean i guess if anything that makes more sense
bcs im like

@x86-39
x86-39 / day5.yml
Last active December 29, 2023 23:51
Ansible Advent of Code 2023, Day 5 Part 1
---
# Set the input
- name: Set example input
ansible.builtin.set_fact:
day5_input: |-
seeds: 79 14 55 13
seed-to-soil map:
50 98 2
52 50 48
@x86-39
x86-39 / day7.yml
Created December 29, 2023 23:45
Ansible Advent of Code 2023, Day 7
---
# Set the input
- name: Set example input
ansible.builtin.set_fact:
day7_input: |-
32T3K 765
T55J5 684
KK677 28
KTJJT 220
QQQJA 483
@x86-39
x86-39 / day6.yml
Created December 29, 2023 23:43
Ansible Advent of Code 2023, Day 6
---
# Set the input
- name: Set example input
ansible.builtin.set_fact:
day6_input: |-
Time: 7 15 30
Distance: 9 40 200
when: day6_input is not defined
# Just split the input into a list of lists and remove unnecessary whitespace
@x86-39
x86-39 / day4.yml
Last active December 29, 2023 23:43
Ansible Advent of Code 2023 Day 4
---
# Set the input
- name: Set example input
ansible.builtin.set_fact:
day4_input: |-
Card 1: 41 48 83 86 17 | 83 86 6 31 17 9 48 53
Card 2: 13 32 20 16 61 | 61 30 68 82 17 32 24 19
Card 3: 1 21 53 59 44 | 69 82 63 72 16 21 14 1
Card 4: 41 92 73 84 69 | 59 84 76 51 58 5 54 83
Card 5: 87 83 26 28 32 | 88 30 70 12 93 22 82 36
@x86-39
x86-39 / day3.yml
Last active December 29, 2023 23:43
Ansible Advent of Code 2023, Day 3
---
# WARNING: THIS TAKES A LONG TIME TO RUN ON REAL INPUT (6 hours!)
# This entire shitfuckery is exponential as all hell, Ansible was not made to do 190k tasks!
# Could be optimised I think by doing more logic within the Jinja2 loops, which would be calculated in the main Ansible process
# Set the input
- name: Set example input
ansible.builtin.set_fact:
day3_input: |-
467..114..
@x86-39
x86-39 / day2.yml
Created December 29, 2023 23:03
Ansible Advent of Code 2023, Day 2
---
# Set the input
- name: Set example input
ansible.builtin.set_fact:
day2_input: |-
Game 1: 3 blue, 4 red; 1 red, 2 green, 6 blue; 2 green
Game 2: 1 blue, 2 green; 3 green, 4 blue, 1 red; 1 green, 1 blue
Game 3: 8 green, 6 blue, 20 red; 5 blue, 4 red, 13 green; 5 green, 1 red
Game 4: 1 green, 3 red, 6 blue; 3 green, 6 red; 3 green, 15 blue, 14 red
Game 5: 6 red, 1 blue, 3 green; 2 blue, 1 red, 2 green
@x86-39
x86-39 / day1.yml
Last active December 29, 2023 23:03
Ansible Advent of Code 2023, Day 1
---
# Set the input
- name: Set example input
ansible.builtin.set_fact:
day1_input: |-
1abc2
pqr3stu8vwx
a1b2c3d4e5f
treb7uchet
when: day1_input is not defined
@x86-39
x86-39 / build-vyos-image.yml
Last active September 26, 2023 09:35
Build VyOS image with modern Ansible.
---
###
# This play builds a VyOS qcow2 image
###
- name: Set up vyos-vm-images repo
hosts: localhost
tags: vyos, prepare-build, build
gather_facts: false
tasks:
- name: Clone vyos-vm-images repo
@x86-39
x86-39 / configuration.yaml
Last active May 18, 2024 16:56
Home Assistant Klipper (Moonraker) integrations
# Replace 192.168.1.1 with your Moonraker IP
# I suffix "_ender3" in these, feel free to replace that too
sensor:
- platform: rest
name: klipper_ender3
resource: "http://192.168.1.1:7125/printer/objects/query?heater_bed&extruder&print_stats&toolhead&display_status&virtual_sdcard&gcode_move&webhooks&temperature_sensor mcu_temp&temperature_sensor pi_temp&filament_switch_sensor Filament"
json_attributes_path: "$.result.status"
json_attributes:
- heater_bed