Skip to content

Instantly share code, notes, and snippets.

@milnak
milnak / youtubedl.cmd
Last active November 30, 2022 06:02
[youtube-dl helper script] CMD script that wraps yt-dlp to simply downloading #youtube
@echo off
REM
REM Script to assist in downloading using yt-dlp
REM
REM Usage:
REM youtubedl.cmd {f,m,v,list-extractors} {video_url}
REM youtubedl.cmd update
REM
REM f = flac
REM m = mkv
@milnak
milnak / subreddit-scraper.sh
Last active July 12, 2023 21:34
subreddit scraper script
# {
# "kind": "Listing",
# "data": {
# "after": "t3_ro8uu5",
# "children": [
# {
# "kind": "t3",
# "data": {
# "url_overridden_by_dest": "https://i.redd.it/gteuq5io5ff81.jpg",
@milnak
milnak / chordpro2pdf.cmd
Created March 15, 2022 16:06
Convert chord pro file to PDF
@ECHO OFF
SETLOCAL
for /f "tokens=1,2,*" %%a in ('reg.exe query "HKEY_LOCAL_MACHINE\SOFTWARE\Artifex\GPL Ghostscript\9.55.0" /ve') do set "UAC=%%c"
SET GSWIN64C=%UAC%\bin\gswin64c.exe
IF NOT EXIST "%GSWIN64C%" (
ECHO Can't find %GSWIN64C%
ECHO Download Windows 64 bit from https://ghostscript.com/releases/gsdnld.html
@milnak
milnak / code.cmd
Last active November 30, 2022 06:01
[VSCode launcher] Better than just using "code" as it supports wildcards #vscode
@ECHO OFF
SETLOCAL
SET CodePath=
REM Visual Studio Code 64-bit user
CALL :GetUninstallPath "HKEY_CURRENT_USER" "{771FD6B0-FA20-440A-A002-3B3BAC16DC50}_is1" "InstallLocation"
IF "%CodePath%" EQU "" (
REM Visual Studio Code 64-bit
CALL :GetUninstallPath "HKEY_LOCAL_MACHINE" "{EA457B21-F73E-494C-ACAB-524FDE069978}_is1" "InstallLocation"
IF "%CodePath%" EQU "" (
@milnak
milnak / windows_ee.md
Last active November 24, 2022 02:04
[Windows v1 - v3 Easter Eggs] How to access the easter eggs in early versions of Windows. #eastereggs #windows

Windows 1 - 3 Easter Egg Information

Encryption/Obfuscation

Windows 1.x - 2.x

Chained XOR. To decrypt, XOR the nth byte with the key, XOR the key with that decrypted byte and repeat until the EOF mark is hit. Initial key is the integer 77.

@milnak
milnak / Transcribe Default Keyboard Shortcuts.md
Last active January 17, 2024 17:42
Transcribe Default Keyboard Shortcuts

Transcribe Default Keyboard Shortcuts

These are the default keyboard shortcuts for Transcribe, organized by category.

Playback

Space Z ; . ,
Play Play from marker (while held) Play from current (while held) Stop Play/Pause
@milnak
milnak / verify_dns.cmd
Created May 23, 2022 15:37
CMD script to verify that DNS server is up and running. Useful for pihole.
@echo off
setlocal
if "%~1"=="" ( ECHO Specify DNS server to verify, e.g. %~nx0 192.168.1.17 & GOTO :EOF)
set DNSSERVER=%~1
REM To have this script run on user login:
REM
REM taskschd.msc
REM Action, Create Basic Task
REM Name: verify_htpc_pihole
@milnak
milnak / .bashrc
Last active June 13, 2023 20:12
My bash prompt #linux
export PS1='\033[0;37m\342\224\214\342\224\200\e[0;36m$(code=${?##0};echo ${code:+\033[0;37m[\033[0;31m\342\234\227\033[0;37m]\342\224\200})\033[0;37m[\e[0;33m\u\e[0;37m@\e[0;33m\h\e[0;37m]\342\224\200[\e[0;36m\A\e[0;37m]\342\224\200[\033[0;32m\w\033[0;37m]\n\033[0;37m\342\224\224\342\224\200[\033[0;34m\!\033[0;37m]\342\224\200\342\225\274 \033[0m'
@milnak
milnak / download_youtube.cmd
Created August 26, 2022 16:15
Download playlists or channels from youtube using yt-dlp
@echo off
setlocal
REM Set codepage to UTF-8
chcp 65001 > NUL
echo.
REM Hidden ESC character on next line.
set ESC=
GOTO :MAIN
@milnak
milnak / pdf_burst.cmd
Last active September 30, 2022 01:06
Burst a PDF Document into Single Pages using qpdf - https://github.com/qpdf/qpdf
@ECHO OFF
REM Burst a PDF Document into Single Pages using qpdf - https://github.com/qpdf/qpdf
SETLOCAL
IF "%~1"=="" (
ECHO PDF_filename
ECHO Example: %~nx0 document.pdf
GOTO :EOF
)