Skip to content

Instantly share code, notes, and snippets.

View ActuallyFro's full-sized avatar
💭
Paper

ActuallyFro

💭
Paper
View GitHub Profile
javascript:(()=>{fetch(location.href+'.json').then(r=>r.json()).then(d=>{try{let v=d[0].data.children[0].data.secure_media?.reddit_video?.fallback_url;if(v)window.open(v,'_blank');else alert('No video found.')}catch(e){alert('Error retrieving video.')}})})();
@ActuallyFro
ActuallyFro / minecraft-server.service
Last active May 20, 2025 01:11
ChatGPT AND Minecraft Wiki -- FTW +Tmux (#BooScreen)
[Unit]
Description=Minecraft Server (Spigot) using tmux
After=network.target
# FILE Location: `sudo nano /etc/systemd/system/minecraft-server.service`
# INSTALL WITH:
# =============
# `sudo systemctl daemon-reexec`
# `sudo systemctl daemon-reload`
@ActuallyFro
ActuallyFro / install.sh
Last active May 22, 2025 13:02
SysML v2 Provisioning -- Getting Jupyter + 2025-02 running!
#!/bin/bash
#
# SysML 2 Pilot Implementation
# Copyright (C) 2020 California Institute of Technology ("Caltech")
# Copyright (C) 2021 Twingineer LLC
# Copyright (C) 2021 Model Driven Solutions, Inc.
# Copyright (C) 2025 ActuallyFro (+Step 0, some deltas from pilot implementation script)
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as published by
@ActuallyFro
ActuallyFro / Ubuntu_SetupMERNEnv.sh
Last active March 16, 2025 02:23
Using Ubuntu 24.04 -- setting up MERN stack with an example application/hello-world.
#!/bin/bash
# MERN-Stack Provisioning Script for Ubuntu
set -e
# Colors for output
green='\e[32m'
red='\e[31m'
yellow='\e[33m'
reset='\e[0m'
@ActuallyFro
ActuallyFro / GetAFDoctrinePDFs.sh
Created December 22, 2024 17:14
Crawling the Doctrine Web FFNP
#!/bin/bash
# Set the base URL and domain to only crawl within this domain
BASE_URL="https://www.doctrine.af.mil"
DOMAIN="doctrine.af.mil"
#OUTPUT_DIR="downloaded_pdfs"
OUTPUT_DIR="./"
# Create an output directory if it doesn't exist
mkdir -p "$OUTPUT_DIR"
@ActuallyFro
ActuallyFro / Markdown_Notes_Counter.sh
Created September 24, 2024 02:24
I take notes, I want where/when and how much to be reported.
#!/bin/bash
# Main script logic
directory="$1" # Directory passed as an argument, or use the current directory if none is provided
if [[ -z "$directory" ]]; then
directory="."
fi
# Check if the directory exists
if [[ ! -d "$directory" ]]; then
@ActuallyFro
ActuallyFro / weblite_MOBI.c
Created September 23, 2024 02:20
Dr. Christensen's weblite -- but to serve kindle Mobis...
//Base code: https://cse.usf.edu/~kchriste/tools/weblite.c
//ALL modifications by ChatGPT -- I make zero claims, have no license to give -- contact him: http://www.csee.usf.edu/~christen || christen @ csee . usf . edu
//https://cse.usf.edu/~kchriste/tools/toolpage.html
// Compile: ` x86_64-w64-mingw32-gcc weblite.c -lws2_32 -o weblite`
//
//ALSO -- to convert .epub to .mobi:
//`sudo apt-get install calibre`
@ActuallyFro
ActuallyFro / LPG.py
Created September 8, 2024 18:41
I LOVE PlantUML.org and Planttext.com ... but no so much the ads...
#!/bin/python3
# Local PlantUML Generator
# ========================
import os
import time
import http.server
import socketserver
import threading
import subprocess
import sys
@ActuallyFro
ActuallyFro / Makefile
Created September 8, 2024 17:28
PlantUML on WSL FIX (if it TAKES FOREVER to RUN)
all: build
build:
java -Djava.awt.headless=true -jar ~/.local/plantuml/plantuml-1.2024.5.jar -nometadata -Tpng test.puml
#See: https://plantuml.com/faq
@ActuallyFro
ActuallyFro / NextDateOccurrence.cpp
Created January 6, 2024 20:15
A wise man once wisecracked "Yeah... I'll do that the next time it's the Third Tuesday in the month again...". I was curious how to calculate that...
#include <cstdlib>
#include <string>
#include <iostream>
enum Weekday { Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday };
enum Month { Jan, Feb, Mar, Apr, May, Jun, Jul, Aug, Sep, Oct, Nov, Dec };
class ComboDate {
public:
int Day;