This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* | |
* Simplistic View_Model attempt for Kohana 3 | |
* @author Cambiata | |
*/ | |
class View_Model { | |
public function render($viewfile=FALSE) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class VerEx | |
{ | |
public static function main() | |
{ | |
var test = new VerEx() | |
.startOfLine() | |
.then("http") | |
.maybe("s") | |
.then("://") | |
.maybe("www.") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import haxe.macro.Expr; | |
class FTW | |
{ | |
public static function build() | |
{ | |
return haxe.macro.Context.getBuildFields().map(transformField); | |
} | |
static function transformField(field:Field) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
DirectoryIndex site/php/routes/index.php?path=index | |
<IfModule mod_rewrite.c> | |
Require all granted | |
RewriteEngine on | |
RewriteCond %{HTTP_HOST} ^mkv25.net$ | |
RewriteCond %{REQUEST_FILENAME} !-f | |
RewriteCond %{REQUEST_FILENAME} !-d | |
RewriteRule ^([^?]*)$ site/php/routes/index.php?path=$1 [NC,L,QSA] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import sys | |
import struct | |
if len(sys.argv) < 2: | |
print("Usage: aac_parer.py <target.aac>") | |
exit() | |
aacfile = open(sys.argv[1], 'rb') | |
frame_no = 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Main { | |
static function main() { | |
Sdl.init(Sdl.INIT_EVERYTHING); | |
var win = Sdl.createWindow("Hello", 100, 100, 800, 600, Sdl.WINDOW_OPENGL); | |
var ren = Sdl.createRenderer(win, -1, Sdl.RENDERER_ACCELERATED); | |
var bmp = Sdl.loadBMP("test.bmp"); | |
var tex = Sdl.createTextureFromSurface(ren, bmp); | |
Sdl.freeSurface(bmp); | |
for (i in 0...3) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@:structInit | |
class A { | |
var x:Int; | |
var y:Int; | |
} | |
@:structInit | |
class B { | |
var a:A; | |
var k:Int; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class KeyValueIterator<K,V> { | |
var map:Map<K,V>; | |
var keys:Iterator<K>; | |
static public inline function pairs<K,V>(map:Map<K,V>) return new KeyValueIterator(map); | |
public inline function new(map:Map<K,V>) { | |
this.map = map; | |
this.keys = map.keys(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import haxe.ds.Either; | |
class Main { | |
static function main() { | |
trace("HI"); | |
var t : WildMap = ["a" => 1, "b"=> 2]; | |
var f = function(x : Map<Int,String>){ | |
trace(x); | |
for (k in x.keys()){ | |
trace(k); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var crypto = require('crypto'); | |
var fs = require('fs'); | |
var exec = require('child_process').exec; | |
var uploadCommand = "firebase auth:import users.json --hash-algo=MD5 --rounds=0"; | |
var stringToBase64 = function(plaintext){ | |
return new Buffer(plaintext).toString('base64'); | |
} | |
var users = [ |
OlderNewer