I hereby claim:
- I am cypres on github.
- I am cyp (https://keybase.io/cyp) on keybase.
- I have a public key ASCyjHoIq03nYt0VUveLHEBUrR6cQWFWhghU5OmD5npNLQo
To claim this, I am signing this object:
<?php | |
/** | |
* PHP class to convert Latitude & Longitude coordinates into UTM & Lambert Conic Conformal Northing/Easting coordinates. | |
* | |
* This class encapsulates the methods for representing a geographic point on the earth in three different coordinate systema. Lat/Long, UTM and Lambert Conic Conformal. | |
* | |
* Code for datum and UTM conversion was converted from C++ code written by Chuck Gantz (chuck.gantz@globalstar.com) from http://www.gpsy.com/gpsinfo/geotoutm/ | |
* This code was converted into PHP by Brenor Brophy (brenor@sbcglobal.net) and later refactored for PHP 5.3 by Hans Duedal (hd@onlinecity.dk). | |
* |
I hereby claim:
To claim this, I am signing this object:
// | |
// Copyright (C) 2011-2012 Yaroslav Stavnichiy <yarosla@gmail.com> | |
// Copyright (C) 2014 OnlineCity Aps <hd@oc.dk> | |
// | |
// Inspired by: https://bitbucket.org/yarosla/nxweb/src/tip/src/lib/daemon.c | |
// | |
// Licensed under The MIT License: | |
// Permission is hereby granted, free of charge, to any person obtaining a copy | |
// of this software and associated documentation files (the "Software"), to deal | |
// in the Software without restriction, including without limitation the rights |
var redis = require("redis"), client = redis.createClient(6379,'127.0.0.1'); | |
// Benchmark params | |
var data = 'O:10:"SmsRequest":5:{s:2:"id";i:550845359;s:6:"sender";s:10:"OnlineCity";s:7:"message";s:140:"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus blandit faucibus magna, vitae accumsan orci iaculis sed. Morbi cras amet.";s:10:"recipients";a:1:{i:0;i:4526159917;}s:10:"dataCoding";i:0;}'; | |
var n = 20000; | |
var start; | |
var lastOp; | |
client.on("error", function (err) { | |
console.log("Error " + err); |
// Easter calculation in swift after Anonymous Gregorian algorithm | |
// Also known as Meeus/Jones/Butcher algorithm | |
import Foundation | |
func easter(Y : Int) -> NSDate { | |
let a = Y % 19 | |
let b = Int(floor(Double(Y) / 100)) | |
let c = Y % 100 | |
let d = Int(floor(Double(b) / 4)) |
// | |
// Two-legged OAuth 1.0a proof of concept | |
// Feel free to use, copy or modify to your own needs. | |
// | |
// Requires glog, gflags and crypto++ (cryptopp.com) | |
// Compile with: | |
// clang++ -std=c++11 -lcryptopp -lglog -lgflags oauth.cc -o oauth_test | |
// Run with: | |
// ./oauth_test -alsologtostderr | |
// |
#!/bin/bash | |
# baraction.sh script for spectrwm status bar | |
print_backlight() { | |
if [ -e /sys/class/backlight/intel_backlight/brightness ]; then | |
BL=$(oled-backlight current) | |
echo -n " BL:$BL%" | |
else | |
echo -n " BL:Unknown" | |
fi |
#!/bin/sh | |
echo "ZFS listing:" | |
/sbin/zfs list | |
echo | |
echo "ZFS compression ratio:" | |
/sbin/zfs get compressratio | /usr/bin/grep -v @ | |
echo |
--- a/tutorial/cpp/CppClient.cpp | |
+++ b/tutorial/cpp/CppClient.cpp | |
@@ -38,9 +38,9 @@ | |
using namespace boost; | |
int main(int argc, char** argv) { | |
- shared_ptr<TTransport> socket(new TSocket("localhost", 9090)); | |
- shared_ptr<TTransport> transport(new TBufferedTransport(socket)); | |
- shared_ptr<TProtocol> protocol(new TBinaryProtocol(transport)); | |
+ boost::shared_ptr<TTransport> socket(new TSocket("localhost", 9090)); |
#ifdef __FreeBSD__ | |
#include <sys/socket.h> | |
#endif | |
#include <arpa/inet.h> | |
#include <netinet/in.h> | |
#include <cstdlib> | |
#include <cstring> | |
#include <cerrno> | |
#include <cassert> | |
#include <iostream> |