#Notice
This gist is moved to git repository:
extern crate liquid; | |
use std::fs::File; | |
use std::io::Read; | |
use std::collections::HashMap; | |
use liquid::Context; | |
use liquid::Renderable; | |
use liquid::Value; | |
use liquid::LiquidOptions; |
/** | |
* This program is free software: you can redistribute it and/or modify | |
* it under the terms of the GNU General Public License as published by | |
* the Free Software Foundation, either version 3 of the License, or | |
* (at your option) any later version. | |
* | |
* This program is distributed in the hope that it will be useful, | |
* but WITHOUT ANY WARRANTY; without even the implied warranty of | |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
* GNU General Public License for more details. |
perillamint@ecthelion ~ $ curl -A "Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.2; Trident/6.0)" http://naver.com | |
<html> | |
<head><title>301 Moved Permanently</title></head> | |
<body bgcolor="white"> | |
<center><h1>301 Moved Permanently</h1></center> | |
<hr><center>nginx</center> | |
</body> | |
</html> | |
perillamint@ecthelion ~ $ curl -A "Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.2; Trident/6.0)" http://naver.com --verbose | |
* Rebuilt URL to: http://naver.com/ |
use std::io; | |
use std::str::Split; | |
struct URI { | |
raw_uri: String, | |
original_uri: String, | |
} | |
impl URI { | |
pub fn new(uri: String) -> URI { |
//Inject this into http://zermoth.net/mabinogi/ost/ | |
if (!String.prototype.format) { | |
String.prototype.format = function() { | |
var str = this.toString(); | |
if (!arguments.length) | |
return str; | |
var args = typeof arguments[0], | |
args = (("string" == args || "number" == args) ? arguments : arguments[0]); | |
for (arg in args) |
extern crate liquid; | |
use std::fs::File; | |
use std::io::Read; | |
use std::collections::HashMap; | |
use liquid::Context; | |
use liquid::Renderable; | |
use liquid::Value; | |
use liquid::LiquidOptions; |
#!/bin/sh | |
# This script downloads entry board (http://play-entry.com/) | |
# websocket connector and apply some hack to enable it to | |
# run it on linux platform | |
# | |
# This script depends on Node.JS system installation (for npm) | |
# | |
# Copyright (c) 2015 perillamint | |
# |
#Notice
This gist is moved to git repository:
//Released under GNU GPL v3. | |
#include <stdio.h> | |
static const char alphanum[] = | |
"0123456789" | |
"!@#$%^&*" | |
"ABCDEFGHIJKLMNOPQRSTUVWXYZ" | |
"abcdefghijklmnopqrstuvwxyz"; |