Skip to content

Instantly share code, notes, and snippets.

View lukassup's full-sized avatar
🍕

Lukas Šupienis lukassup

🍕
View GitHub Profile
@lukassup
lukassup / ethtool-reset.md
Created March 13, 2025 14:08
Reset link speed to defaults

Reset interface speed to defaults

sudo ethtool -s ens10f1 autoneg on advertise 0xffffffffff
tap "esolitos/ipa"
tap "hashicorp/tap"
tap "homebrew/bundle"
tap "homebrew/services"
brew "automake"
brew "awscli"
brew "bash-completion@2"
brew "node"
brew "bitwarden-cli"
brew "pkg-config"
@lukassup
lukassup / setup-pw.sh
Last active October 3, 2025 19:52
Low latency for Reaper on PipeWire
#!/bin/sh
# Reaper reports latency of 4ms with this config.
#
# It may also be a good idea to use "Pro Audio" audio profile
#
# $ pactl list short cards
# $ pactl set-card-profile YOUR_CARD_NAME pro-audio
#
@lukassup
lukassup / retropie-network-boot-pi4.md
Last active May 18, 2022 19:44
Network booting RetroPie on Raspberry Pi 4

Diskless RetroPie on Raspberry Pi 4

This should work fine when booting to in ARMv7 mode (32bit) - currently only version of RetroPie.

AArch64 mode (64bit) uses U-Boot and I couldn't set it up yet...

  1. Install Raspbian to an SD Card and boot your Raspberry Pi 4

TODO

@lukassup
lukassup / synology-dsm7-fix.diff
Created January 28, 2022 18:38
Fix for Synology DSM v7 nginx config
diff --git a/usr/syno/share/nginx/DSM.mustache.orig b/usr/syno/share/nginx/DSM.mustache
index f4aa1cc..c648799 100644
--- a/usr/syno/share/nginx/DSM.mustache.orig
+++ b/usr/syno/share/nginx/DSM.mustache
@@ -1,9 +1,9 @@
{{#DSM}}
server {
- listen {{port}} default_server;
- listen [::]:{{port}} default_server;
+ listen {{port}};

Open source game engine ports

  • SDLPoP: Prince of Persia (SDL port)
  • ecwolf: Wolfenstein3D, Spear of Destiny (SDL port)
  • GZDoom: idTech1 engine port. Doom I & II, Heretic, Hexen & more (Vulkan, OpenGL renderers)
  • Raze: Build engine port. Supports: Duke Nukem 3D, Redneck Rampage, Blood, Shadow Warrior (Vulkan, OpenGL renderers)
  • eduke32: Duke Nukem 3D source port
  • vkQuake: Quake I (Vulkan renderer)
  • vkQuake2: Quake II (Vulkan renderer)
  • ioQuake3: Quake III (SDL port)
@lukassup
lukassup / steamdl.md
Last active November 9, 2021 11:29
Steam download

Download a Steam game

  • You need to know the APP_ID, e.g. find it in the Steam store URL.

  • You need to own the game on your account.

  • This downloads Windows version of the game, which is handy to play games with no MacOS/Linux native support on source ports (e.g. vkquake, gzdoom, raze). You can change +@sSteamCmdForcePlatformType to linux or macos if you like

  • Install steamcmd (MacOS):

brew install --cask steamcmd

#!/usr/bin/env ruby
# vim: set ft=ruby:
# frozen_string_literal: true
require "bundler/setup"
require "dry/cli"
module ZX
module CLI
class SudoCommand < Dry::CLI::Command
@lukassup
lukassup / demo.rb
Created April 20, 2021 14:10
Shooting oneself in the foot using Ruby, pt1
#!/usr/bin/env ruby
current = 'Silver'
if current = 'Gold'
# ^ oh no, a mistake! should've been ==
puts 'Yay! Found gold'
else
puts "#{current} is not gold"
end