Skip to content

Instantly share code, notes, and snippets.

@chaosprinz
chaosprinz / specspec_helper.rb
Created August 28, 2011 09:49 — forked from gavinheavyside/trivial_file_upload_service.rb
Trivial file upload service with simple filename-check using Sinatra and test it with rspec
require './trivial_file_upload_service.rb'
require 'rack/test'
require 'rspec'
set :enviroment, :test
end
@chaosprinz
chaosprinz / hello_world.rb
Created August 28, 2011 15:35
Using webrat for acceptancetest on sinatra
require 'sinatra'
get '/hello/world' do
"<h1>hello world</h1>"
end
@chaosprinz
chaosprinz / node_controlled_mplayer.js
Created October 22, 2015 18:53
Here is a solution for controlling the mplayer using nodejs. Much cleaner and more efficient than my fifo-solution. Instead of process.stdin i could use a socket or an webservice or whatever, very simple.
var cp = require("child_process");
var fs = require("fs");
player = cp.spawn("mplayer",
["-slave","-idle","-quiet"]
);
player.stdout.on("data",function(data){
console.log("" + data);
});
player.stderr.on("data", function(data){
@chaosprinz
chaosprinz / jade_compile.js
Last active April 19, 2016 08:34 — forked from gperetin/jade_compile.js
Node.js script to compile Jade templates
/*
* This script takes 2 arguments, first is path to templates dir,
* and second is path to folder where to put compiled templates.js
*
* It scans templates dir, takes all .jade files and compiles them
* as Jade templates. Then it writes all template functions to
* single output file templates.js
*/
var fs = require('fs');
@chaosprinz
chaosprinz / build_watcher.js
Last active April 19, 2016 19:10
Watching for changes on source-files and rebuild them. Say no to grunt and co.
'use strict';
/*
# Build-environment filewatcher-script
*/
const chokidar = require('chokidar');
const child_process = require('child_process');
const Path = require('path')
const config = require('./watch.conf');
@chaosprinz
chaosprinz / .tmux.conf
Created April 22, 2016 16:34
This is my actual tmux-configuration running on windows w. babun
# Use C-a as prefix and free C-b
set -g prefix C-a
unbind C-b
# Send C-a to application by pressing it twice
bind C-a send-prefix
# Reload configuration file
unbind r
bind r source-file ~/.tmux.conf \; display ".tmux.conf reloaded!"
# Your init script
#
# Atom will evaluate this file each time a new window is opened. It is run
# after packages are loaded/activated and after the previous editor state
# has been restored.
#
# An example hack to log to the console when each text editor is saved.
#
# atom.workspace.observeTextEditors (editor) ->
# editor.onDidSave ->
This file has been truncated, but you can view the full file.
[22:51:10] [main/INFO]: Loading tweak class name net.minecraftforge.fml.common.launcher.FMLTweaker
[22:51:10] [main/INFO]: Using primary tweak class name net.minecraftforge.fml.common.launcher.FMLTweaker
[22:51:10] [main/INFO]: Calling tweak class net.minecraftforge.fml.common.launcher.FMLTweaker
[22:51:10] [main/INFO]: Forge Mod Loader version 12.18.3.2316 for Minecraft 1.10.2 loading
[22:51:10] [main/INFO]: Java is Java HotSpot(TM) 64-Bit Server VM, version 1.8.0_25, running on Windows 10:amd64:10.0, installed at C:\Users\Siggi\Documents\Curse\Minecraft\Install\runtime\jre-x64\1.8.0_25
[22:51:10] [main/WARN]: The coremod org.minimallycorrect.libloader.LibLoader does not have a MCVersion annotation, it may cause issues with this version of Minecraft
[22:51:10] [main/INFO]: Current LaunchClassLoader URLs:
[file:/C:/Users/Siggi/Documents/Curse/Minecraft/Install/libraries/net/minecraftforge/forge/1.10.2-12.18.3.2316/forge-1.10.2-12.18.3.2316.jar
file:/C:/Users/Siggi/Documents/Curse/Minecraft/Install/libraries/n
@chaosprinz
chaosprinz / crash-2017-11-22_16.54.13-server.txt
Created November 22, 2017 16:51
ATM3 - ExtraCell2 FluidAssembler crash
---- Minecraft Crash Report ----
WARNING: coremods are present:
ForgelinPlugin (Forgelin-1.5.1.jar)
IELoadingPlugin (ImmersiveEngineering-0.12-74-core.jar)
ShetiPhian-ASM (shetiphiancore-1.12.0-3.5.4.jar)
AppleCore (AppleCore-mc1.12.2-2.2.2.jar)
AstralCore (astralsorcery-1.12.2-1.8.2.jar)
CTMCorePlugin (CTM-MC1.12-0.2.3.9.jar)
Plugin (NotEnoughIDs-1.5.4.2.jar)
@chaosprinz
chaosprinz / Enigmatica2-expert crash-log 04-11-18 11:38
Created April 10, 2018 09:49
Ticking block entity-crash from cyclics forester on enigmatica2-expert
---- Minecraft Crash Report ----
WARNING: coremods are present:
IELoadingPlugin (ImmersiveEngineering-0.12-76-core.jar)
llibrary (llibrary-1.7.9-1.12.2.jar)
AstralCore (astralsorcery-1.12.2-1.8.5.jar)
LoadingPlugin (Quark-r1.4-123.jar)
SHLoadingPlugin (ScalingHealth-1.12-1.3.13-94.jar)
IELoadingPlugin (ImmersiveEngineering-0.12-78-core.jar)
Do not report to Forge! Remove FoamFixAPI (or replace with FoamFixAPI-Lawful) and try again. (foamfix-0.9.6-1.12.2-anarchy.jar)