Skip to content

Instantly share code, notes, and snippets.

View waddlesplash's full-sized avatar

waddlesplash waddlesplash

View GitHub Profile
@tqh
tqh / haiku_efi.md
Last active March 6, 2022 18:23
My Haiku efi setup
  • In the haiku directory I have a directory efi/ and in it a link haiku_loader.efi -> ../generated/objects/haiku/x86_64/release/system/boot/efi/haiku_loader.efi

  • Haiku is configured with: ./configure --build-cross-tools x86_64 ../buildtools

  • Haiku EFI loader is build with: jam -q -sHAIKU_BOOT_PLATFORM=efi haiku_loader.efi

  • Haiku is built with: jam -q @nightly-anyboot

  • QEMU/kvm is started with (needs ovmf.fd):

    qemu-system-x86_64 -m 512M -cpu host -enable-kvm -nodefaults -smp 1,cores=2 \
        -vga std -net nic -net user -serial file:serial.log \
    

-chardev socket,path=/tmp/qga.sock,server,nowait,id=qga0 \

@hyl
hyl / zalgo.js
Created January 20, 2015 23:18
Zalgo your outdated customers.
/*
If you actually want to use this in a live project (please don't), add the following to your HTML:
<!--[if lt IE 9 ]>
<script src="https://code.jquery.com/jquery-1.11.2.min.js"></script>
<script src="zalgo.js"></script>
<![endif]-->
*/
@bradwilson
bradwilson / gist:c0e4994f976e757bc7d5
Last active February 1, 2024 15:37
Tweaks to make to VMware .vmx files
# Disables touchscreen emulation
touchscreen.vusb.present = "FALSE"
# Enables support for nested hypervisors
hypervisor.cpuid.v0 = "FALSE"
vhv.enable = "TRUE"
vpmc.enable = "TRUE"
mce.enable = "TRUE"
vhu.enable = "TRUE"
@xmlking
xmlking / Enum.es6.js
Last active June 25, 2019 18:09
JavaScript Enums with ES6, Type Checking and Immutability
export class EnumSymbol {
sym = Symbol.for(name);
value: number;
description: string;
constructor(name: string, {value, description}) {
if(!Object.is(value, undefined)) this.value = value;
if(description) this.description = description;
@Ravadre
Ravadre / gist:10427079
Created April 10, 2014 21:55
N++ quotes
const int nbQuote = 197;
Quote quotes[nbQuote] = {
{"Notepad++", "Good programmers use Notepad++ to code.\nExtreme programmers use MS Word to code, in Comic Sans, center aligned."},
{"Martin Golding", "Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live."},
{"L. Peter Deutsch", "To iterate is human, to recurse divine."},
{"Seymour Cray", "The trouble with programmers is that you can never tell what a programmer is doing until it's too late."},
{"Brian Kernighan", "Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it."},
{"Alan Kay", "Most software today is very much like an Egyptian pyramid with millions of bricks piled on top of each other, with no structural integrity, but just done by brute force and thousands of slaves."},
{"Bill Gates", "Measuring programming progress by lines of code is like measuring aircraft building
{"here":25,"wtf":16,"wat":12,"lolol":11,"derp":9,"poop":8,"foo":8,"wut":6,"hola":6,"yo":6,"fuck":5,"test":4,"shit":4,"huh":4,"hello":3,"got here":3,"butts":3,"herp":3,"bar":3,"asdf":3,"ohai":3,"hell":3,"you got here":2,"sup":2,"bleh":2,"here 1":2,"here 2":2,"lol":2,"poo":2,"i like cheese":2,"fuuu":2,"lala":2,"omg":2,"hello?":2,"holla":2,"holman":2,"dupa":2,"lalala":2,"balls":2,"woot":2,"blah":2,"welp":2,"moo":2,"boom":2,"cat":2,"horse":1,"chk1":1,"coucou":1,"poldo":1,"asasdasdasdasd":1,"meow":1,"twerk -->":1,"ebasa":1,"dick fingers":1,"aaaaaaaaa":1,"hotdogs":1,"heyo":1,"chicken dinner":1,"woo":1,"ffs":1,"blip tip":1,"gah":1,"AREYOUKIDDING":1,"cocknobs":1,"PORTC = 0xFF":1,"haha":1,"apa":1,"wtfbbq":1,"wtffu":1,"prout":1,"eh":1,"goddammit2":1,"fuckthis1":1,"debug2":1,"debug1":1,"dog":1,"stip":1,"blag":1,"3💨":1,"yay":1,"hey grl":1,"heyheyhey":1,"die mofo":1,"nay":1,"boom!":1,"programming is stupid I hate computers who invented this fucking proffession anyway":1,"fuck you":1,"hi":1,"caca":1,"what the fuck is going
@pulkomandy
pulkomandy / BNetAPI WebKit bugs.md
Last active November 8, 2016 09:51
A short list of known issues with bnetapi-based webkit haiku port.

This is a list of websites that have problems rendering or loading with the Haiku port of WebKit, as well as some general notes about what needs to be done.

Web+ and WebKit

Rendering

CSS Fonts

  • http://haikuports.org : use of CSS fonts. Why does this work on github and not here ? Different font rendering mode maybe ? (never works here)
@kbjorklu
kbjorklu / waveOut.cpp
Created August 23, 2013 09:27
Sample code for the waveOutWrite function.
#include <windows.h>
#include <mmsystem.h>
#pragma comment(lib, "winmm.lib")
int main()
{
HWAVEOUT hWaveOut = 0;
WAVEFORMATEX wfx = { WAVE_FORMAT_PCM, 1, 8000, 8000, 1, 8, 0 };
waveOutOpen(&hWaveOut, WAVE_MAPPER, &wfx, 0, 0, CALLBACK_NULL);
char buffer[8000 * 60] = {};
@jasonrudolph
jasonrudolph / 00-about-search-api-examples.md
Last active April 30, 2024 19:21
5 entertaining things you can find with the GitHub Search API
@skyrpex
skyrpex / qt5-fusion-dark.cpp
Last active October 5, 2022 10:57
Qt5 Fusion style (dark color palette)
qApp->setStyle(QStyleFactory::create("fusion"));
QPalette palette;
palette.setColor(QPalette::Window, QColor(53,53,53));
palette.setColor(QPalette::WindowText, Qt::white);
palette.setColor(QPalette::Base, QColor(15,15,15));
palette.setColor(QPalette::AlternateBase, QColor(53,53,53));
palette.setColor(QPalette::ToolTipBase, Qt::white);
palette.setColor(QPalette::ToolTipText, Qt::white);
palette.setColor(QPalette::Text, Qt::white);