Skip to content

Instantly share code, notes, and snippets.

@robatron
robatron / fallout-1-high-res-patch-mac-osx.md
Last active May 6, 2024 12:55
How to get the Fallout 1 (and Fallout 2) high-resolution patch working for Mac OS X

Fallout 1 (and Fallout 2) Hi-Res Patch for Mac OS X

Fallout 1 was originally designed to run at 640x480 resolution. I wanted to run the Mac OS X version of Fallout on my MacBook 11", which has a 1366x768 display. There is a [high resolution patch][hi-res], but it only supports the Windows version of Fallout.

Turns out that the OS X version of Fallout runs through Wine, so we can get this patch working with just a few configuration changes:

Note for Fallout 2 users: The process for Fallout 2 is essentially the same, with a different patch, and some minor pathing differences. Other than that, the process is exactly the same!

Install Wine

@sturadnidge
sturadnidge / isoboot.ipxe
Created May 13, 2012 17:30
iPXE Boot an ISO
#!ipxe
echo
initrd http://webserver.fqdn/iso/firmware.iso
chain http://webserver.fqdn/memdisk/memdisk iso ||
echo
echo netboot failed, attempting to boot from local disk
echo
sanboot --no-describe --drive 0x80 ||
echo
echo local boot failed, booting ipxe shell
@gtirloni
gtirloni / wsl-dropbox.md
Last active May 6, 2024 12:50
Windows WSL2 and Dropbox

This was only tested on Fedora 35 with systemd but should work on any WSL distribution that uses systemd.

Install the Dropbox headless client:

$ cd ~ && wget -O - "https://www.dropbox.com/download?plat=lnx.x86_64" | tar xzf -

Install the Dropbox manager script into your ~/bin folder:

@luizomf
luizomf / ambiente-dev-ubuntu-curso-python.sh
Created October 31, 2022 01:23
Instalação ambiente dev Ubuntu 22 do curso de Python
#!/bin/bash
# Executar comandos a seguir para atualizar os pacotes
sudo apt update -y
sudo apt upgrade -y
# Só o Python
sudo apt install python3.10-full python3.10-dev -y
# Instalar pacotes a seguir
@PhirePhly
PhirePhly / ISA.txt
Created March 26, 2012 20:42
Intro to the ISA bus by Mark Sokos
THE ISA AND PC/104 BUS
IBM, IBM/XT, IBM PC, and IBM PC AT are registered trademarks of
International Business Machines Corporation.
This file is designed to give a basic overview of the bus found in
most IBM clone computers, often referred to as the XT or AT bus. The
AT version of the bus is upwardly compatible, which means that cards
@wojteklu
wojteklu / clean_code.md
Last active May 6, 2024 12:44
Summary of 'Clean code' by Robert C. Martin

Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.


General rules

  1. Follow standard conventions.
  2. Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
  3. Boy scout rule. Leave the campground cleaner than you found it.
  4. Always find root cause. Always look for the root cause of a problem.

Design rules

@mrkline
mrkline / c_sharp_for_python.md
Last active May 6, 2024 12:43
An intro to C# for a Python developer. Made for one of my coworkers.

C# For Python Programmers

Syntax and core concepts

Basic Syntax

  • Single-line comments are started with //. Multi-line comments are started with /* and ended with */.

  • C# uses braces ({ and }) instead of indentation to organize code into blocks. If a block is a single line, the braces can be omitted. For example,

@YeapGuy
YeapGuy / airtag-decryptor.swift
Last active May 6, 2024 12:42
Decrypt macOS Find My .record file
//
// airtag-decryptor.swift
//
//
// Created by Matus on 28/01/2024.
//
import Foundation
import CryptoKit
// Function to decrypt using AES-GCM
@FikretHassan
FikretHassan / report-heavy-ad-intervention.js
Last active May 6, 2024 12:42
Add this to your creative / creative wrapper to log chrome heavy ad interventions to the console
const observer = new ReportingObserver(
(reports, observer) => {
console.log('ADTECH: reporting observer results:', JSON.stringify(reports));
}, {
buffered: true
}
);
// start watching for interventions
observer.observe();
@johnpierson
johnpierson / PrompForSaveApp.cs
Last active May 6, 2024 12:42
This is an example of an application level add-in that would prompt a user to save if they need to when launching dynamo.
#This code is proudly provided under the BSD-3-Clause, https://opensource.org/licenses/BSD-3-Clause
using System;
using Autodesk.Internal.Windows;
using Autodesk.Revit.DB;
using Autodesk.Revit.DB.Events;
using Autodesk.Revit.UI;
namespace PromptForSaveOnDynamoLaunch
{