Skip to content

Instantly share code, notes, and snippets.

View Leandros's full-sized avatar
🦀
Available for Rust contracting

Arvid Gerstmann Leandros

🦀
Available for Rust contracting
View GitHub Profile
@Leandros
Leandros / exportOptions.plist
Last active October 29, 2015 09:06
Default exportOptions.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>method</key>
<string>app-store</string>
<key>uploadSymbols</key>
<true/>
<key>uploadBitcode</key>
<true/>
@Leandros
Leandros / script.js
Last active November 26, 2015 14:50
Postly Victory
// ==UserScript==
// @name Postly Victory Sound
// @namespace Postly App, LLC
// @version 0.1
// @description try to take over the world!
// @author Arvid Gerstmann
// @match https://api.getpostly.com/*
// @match http://127.0.0.1:5000/*
// @grant none
// @require http://code.jquery.com/jquery-2.1.4.min.js
@Leandros
Leandros / main.lua
Last active April 24, 2024 20:38
Love2D Fixed Timestep
local TICKRATE = 1/60
function love.update(dt)
end
function love.draw(dt)
end
function love.run()
if love.math then
@Leandros
Leandros / DEBUG.INC
Created March 12, 2016 20:16
Debugging Messages in no$gmb and BGB
IF !DEF(DEBUG_INC)
DEBUG_INC SET 1
; Prints a message to the no$gmb / bgb debugger
; Accepts a string as input, see emulator doc for support
DBGMSG: MACRO
ld d, d
jr .end\@
DW $6464
DW $0000
@Leandros
Leandros / gen_host.sh
Created April 26, 2016 16:27
Generate Hostfile
#!/bin/sh
#
# This code is GPLv3
# Taken from: http://chr4.org/blog/2016/04/26/homebrew-betrayed-us-all-to-google/
HOSTSFILE=hosts
TMPFILE=/tmp/aosp-hosts-file
echo "Updating adblocking hosts file..."
@Leandros
Leandros / fix.js
Created May 8, 2016 19:31
Fix Googles Stylesheet
// ==UserScript==
// @name Fix Google
// @namespace https://arvid.io
// @version 1.0
// @description Fix Google's horrible style sheet.
// @author Arvid Gerstmann
// @match *://*.google.com/*
// @match *://*.google.de/*
// @match *://google.com/*
// @match *://google.de/*
@Leandros
Leandros / fix_github.js
Last active July 12, 2016 07:48
Fix Github
// ==UserScript==
// @name Fix Github
// @namespace https://arvid.io
// @version 0.1
// @description Fix Githubs stupid font change
// @author Arvid Gerstmann
// @match https://github.com/*
// @match https://gist.github.com/*
// @grant GM_addStyle
// ==/UserScript==
#!/usr/bin/perl -w
$ptr='(BYTE|WORD|DWORD|QWORD|XMMWORD) PTR ';
$reg='(?:[er]?(?:[abcd]x|[sd]i|[sb]p)|[abcd][hl]|r1?[0-589][dwb]?|mm[0-7]|xmm1?[0-9])';
open FH, '-|', '/usr/bin/objdump', '-w', '-M', 'intel', @ARGV or die;
$prev = "";
while(<FH>){
if(/$ptr/o) {
s/$ptr(\[[^\[\]]+\],$reg)/$2/o or
s/($reg,)$ptr(\[[^\[\]]+\])/$1$3/o or
s/$ptr/lc $1/oe;
@Leandros
Leandros / bff.vim
Created September 12, 2016 05:51
FastBuild Vim Syntax
" fastbuild syntax
" keywords
syn keyword bffKeyword Alias Compiler Copy CopyDir CSAssembly DLL Exec
syn keyword bffKeyword Executable ForEach Library ObjectList Print RemoveDir
syn keyword bffKeyword Settings Test Unity Using VCXProject VSSSolution XCodeProject
" preprocessor
syn region bffPreproc start="^\s*#\s*\(if\|endif\)\>" skip="\\$" end="$" keepend
syn region bffPreproc start="^\s*#\s*\(define\|undef\)\>" skip="\\$" end="$" keepend
@Leandros
Leandros / foo_linux.c
Last active October 14, 2016 13:40
Define function by objectcode
/*
* !!! Linux Version !!!
*
* Compile with: gcc -o foo foo_linux.c
*
* $ ./foo
* foo(5) = 10
*/
#include <stdio.h>