Skip to content

Instantly share code, notes, and snippets.

View CruzR's full-sized avatar

Thomas Glamsch CruzR

  • Augsburg, Germany
View GitHub Profile
<!-- Add this to #myselection -->
<p>Kanal suchen: <input type="search" oninput="searchForChannel();" id="channelSearch"/></p>
<p id="searchError" hidden></p>
<ol id="searchResults" hidden></ol>
<!-- Add this to an existing script section -->
<script type="application/javascript">
function searchForChannel() {
var searchPattern = getSearchPattern();
@CruzR
CruzR / cargo-depends
Created February 15, 2015 21:57
Display textual dependency graph for a cargo project.
#!/usr/bin/python
# coding: utf-8
from __future__ import print_function
import argparse
import os.path
import sys
import toml
@CruzR
CruzR / villages.patch
Created December 4, 2012 23:12
LPC: CMakeLists.txt Patch for Villages
--- CMakeLists.txt.old 2012-12-05 00:00:22.412836912 +0100
+++ CMakeLists.txt 2012-12-05 00:05:40.947832754 +0100
@@ -65,8 +65,7 @@
Find_Package(SDL_mixer REQUIRED)
include_directories(
- includes/sdl/
- includes/sdl-gfx/
+ ${SDL_INCLUDE_DIR}
includes/tinyxml2/
@CruzR
CruzR / buildjar_moon.sh
Created December 4, 2012 22:04
LPC: Build script for BloodMoon
#!/bin/sh
# Fix annoying UTF-8 warnings
sed -i 's/ \xa9 / \xc2\xa9 /' `find src -name '*.java'`
# Fix Windows paths
sed -i 's/\\\\/\//g' `find src -name '*.java'`
sed -i 's/\\/\//g' `find Resources -name '*.maze'`
# Build class files
@CruzR
CruzR / buildjar_blob.sh
Created December 4, 2012 12:50
LPC: Build script for BlobMobs
#!/bin/sh
javac -cp "$PWD/lib/*" `find $PWD/src -name '*.java'`
cd $PWD/src
jar cf ../BlobMobs.jar .
cd ..
@CruzR
CruzR / buildjar.sh
Created December 4, 2012 00:53
Build script for TheLongestRoad
#!/bin/sh
# Instructions:
# -------------
# - Copy both buildjar.sh and startgame.sh into the game directory.
# - Execute buildjar.sh
# - Execute startgame.sh
USAGE="Usage:\n$0 <java_include_path>\n"
@CruzR
CruzR / gist:4172911
Created November 30, 2012 00:32
xclip: Copy content of XA_PRIMARY (selection clipboard) to XA_CLIPBOARD (ctrl-c/ctrl-v clipboard)
#!/bin/sh
xclip -o | xclip -se c