Skip to content

Instantly share code, notes, and snippets.

@protrolium
protrolium / custom-bash-commands.md
Last active September 11, 2022 15:56
bash scripts

$ cd /usr/local/bin
$ sudo nano [scriptname]

#!/bin/bash
command goes here

exit and save

sudo chmod +x [scriptname] to make executable

@protrolium
protrolium / monty-ffmpeg.md
Last active December 24, 2023 19:03
using ffmpeg to add sound to youtube videos

quick/dirty process to merge audio streams

create initial video offset
ffmpeg -ss 0:00 -t 0:00 -i input.mp4 output.mp4

exctract audio from new output.mp4
ffmpeg -i output.mp4 -f mp3 -ab 192000 -vn output.mp3

merge the two audio files
ffmpeg -i output.mp3 -i audio2.mp3 -filter_complex amerge -ac 2 -c:a libmp3lame -q:a 4 merged.mp3

@katchy3132
katchy3132 / idlemonitor.ahk
Last active August 3, 2023 13:59
Idle Monitor - Autohotkey- monitor and log idle time
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
LogFileLoc := A_Desktop . "\idlemonitor-log.txt"
LogFileIntervalSec := 10
LogFileIdleGreaterThan := 30
@reg2k
reg2k / Fallout 4 All Console Commands.txt
Created March 4, 2018 16:29
Dump of all Fallout 4 console commands (with description)
-----------------------------------------------------------------------------------------
ID Full Name Short Name Description
-----------------------------------------------------------------------------------------
256: Show TST Show global scripts and variables.
257: ShowVars SV Show variables on object. You can optionally specified a papyrus variable or script to filter with [player->sv]
258: ShowGlobalVars SGLV Show all global variables.
259: ShowQuestVars SQV Show quest variables. You can optionally specified a papyrus variable or script to filter with [svq QuestID]
260: ShowQuests SQ List quests.
261: ShowQuestAliases Show quest aliases. [ShowQuestAliases QuestID]
262:
@ayushmi
ayushmi / swarm.html
Created November 6, 2025 21:42
10,000 robots with collision avoidance in WebGPU in HTML
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8"/>
<title>swarmbots.wgpu — 10k robots</title>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<style>
:root { color-scheme: dark; }
body { margin:0; font:14px/1.3 system-ui, -apple-system, Segoe UI, Roboto, sans-serif; background:#0b0e14; color:#e6e9ef; }
#wrap { display:grid; grid-template-columns: 320px 1fr; min-height:100vh; }