Skip to content

Instantly share code, notes, and snippets.

@n0samu
n0samu / web-archival-guide.md
Last active July 3, 2024 23:13
Essential tips for web archiving.

In this brief guide, I will share what I've learned about archiving live webpages and recovering deleted webpages using various archive services.

Before you start

I highly recommend installing the Web Archives extension in your web browser (Chrome, Firefox). It provides quick access to archive services and search engine caches.

Overview of archive services & caches

  • Wayback Machine: Best and largest webpage archive. You probably already use it. Wayback Machine is the only archival service that also performs automated crawling, so its coverage is much better than other archives. See usage tips on Wikipedia.
  • Archive.today (also known as Archive.is): A mid-sized service that takes
@n0samu
n0samu / flash-player-in-2023.md
Last active May 25, 2024 23:13
How to use Flash Player on any device in 2023. Use at your own risk!

How to Use Adobe Flash Player in 2023

Local SWFs

The easiest way to play Flash files that you have locally on your computer is to use Adobe's official projector program, which is available for Windows, MacOS and Linux. You can also open direct links to SWF files on the Internet by clicking File => Open in the projector's menu.

For Windows PCs:

  • The easiest option is to use this browser that comes with Flash Player. Just download and extract the ZIP file, then run Basilisk-Portable.exe. A web browser will open - navigate to the Flash content you want to view, and it should play just fine!
  • To install Flash Player for another compatible browser such as Internet Explorer, Waterfox Classic, or Pale Moon, you can use the Clean Flash Installer. This also works for programs like gam
@n0samu
n0samu / trackingIssuesProgress.py
Created April 19, 2023 00:23
Script to calculate Ruffle's AVM1 implementation progress based on tracking issues
import sys
import requests
import re
from bs4 import BeautifulSoup
ISSUES_BASE = 'ruffle-rs/ruffle/issues/'
def get_issue_progress(issue_url):
htmlResponse = requests.get(issue_url)
soup = BeautifulSoup(htmlResponse.text, "html.parser")
@ECHO off
SETLOCAL EnableDelayedExpansion
SET RUST_LOG=warn,ruffle_core=debug,avm_trace=trace,symphonia_bundle_mp3=error
SET ARGS=%*
SET "ARG1=%~1"
IF "%ARG1:~0,3%"=="202" (
SET "BUILD_PATH=Old Desktop Builds\Nightly %ARG1%"
SET ARGS=!ARGS:%ARG1% =!
) ELSE (
@n0samu
n0samu / tangoandchaos-bookmarklet.js
Created October 17, 2022 09:47
JavaScript code to download FLV videos from pages on tangoandchaos.org. Written at the request of someone on Discord.
function saveFile(fileUrl, mimeType) {
var fileName = fileUrl.split('/').pop();
fetch(fileUrl)
.then(response => response.blob())
.then(blob => {
var link = window.document.createElement("a");
link.href = window.URL.createObjectURL(blob, { type: mimeType });
link.download = fileName;
document.body.appendChild(link);
link.click();
#!/usr/bin/env python3
from urllib.request import urlopen
from urllib.parse import quote
import xml.etree.ElementTree as ET
import sys
def read_xml(f):
it = ET.iterparse(f)
for _, el in it:
el.tag = el.tag.split('}', 1)[1] # strip all namespaces
# SWF scanner by nosamu
# Dumps a CSV file with the filename, width and height (in pixels),
# and AS3 flag of each SWF in the current folder.
# Requires Flasm: http://www.nowrap.de/flasm.html
import os
import shutil
import subprocess
import re
import csv