Skip to content

Instantly share code, notes, and snippets.

View riaf's full-sized avatar
🏠
Working from home

Keisuke SATO riaf

🏠
Working from home
View GitHub Profile
@riaf
riaf / simple-chaser-server-cli.ts
Last active December 12, 2022 12:07
サンプル(動作未確認)
import {
CellTypes,
findPlayersByPosition,
Game,
parseLegacyMap,
State,
} from "https://deno.land/x/chaser_engine@0.0.1/mod.ts";
import { LegacyServer } from "https://deno.land/x/chaser_engine@0.0.1/examples/legacy_server.ts";
const CELLCHARS = {
@riaf
riaf / convert-less.php
Created June 26, 2012 04:56
すごく手抜きな css sprite generator
<?php
$filename = isset($argv[1]) ? realpath($argv[1]) : null;
$mixin = isset($argv[2]) ? $argv[2] : 'sprite-mixin';
$retina = isset($argv[3]) ? true : false;
if (!$filename) {
echo "fail", PHP_EOL;
exit(1);
}
[
"about",
"ac",
"access",
"account",
"accounts",
"activate",
"ad",
"add",
"address",
@riaf
riaf / userChrome.css
Created August 13, 2020 05:23
Take the anger out of Firefox's UI for use on macOS. (Move the close tab button to the left and only show it on mouseover.)
@namespace url(http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul);
toolbarbutton#alltabs-button {
-moz-binding: url("userChrome.xml#js");
}
.tabbrowser-tab .tab-close-button {
-moz-box-ordinal-group: 0 !important;
opacity: 0;
}
<?php
/**
* Geohash
*
* @author Keisuke SATO
* @license MIT License
*
* # Based
* http://github.com/davetroy/geohash-js/blob/master/geohash.js
* Geohash library for Javascript

Keybase proof

I hereby claim:

  • I am riaf on github.
  • I am keisuke (https://keybase.io/keisuke) on keybase.
  • I have a public key ASAI_ZVfS8C3nacZu8hpLsonfszLRnG1-FjloeKXgXnRTgo

To claim this, I am signing this object:

@riaf
riaf / riaf.min.svg
Last active November 21, 2017 07:12
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@riaf
riaf / csssh.sh
Created July 26, 2016 07:47
Coreserver に SSH 接続する
curl -XPOST \
-d "id=$USERID" \
-d "pass=$FTPPASS" \
-d "remote_host=$(curl http://dyn.value-domain.com/cgi-bin/dyn.fcg?ip)" \
-d "ssh2=on" \
https://ss1.coressl.jp/www.$CS_SERVER.coreserver.jp/jp/admin.cgi \
| iconv -f SJIS -t UTF8
<?php
if(!class_exists('Rhaco')) require_once 'rhaco/Rhaco.php';
Rhaco::import('network.http.Browser');
class AmazonReport
{
var $base_url = 'https://affiliate.amazon.co.jp';
var $browser;
function AmazonReport($email, $password){
@riaf
riaf / config.hdf
Created November 8, 2013 03:39
HHVM on Heroku for Symfony (or Silex) Application
Server {
SourceRoot = /app/web
DefaultDocument = index_dev.php
}
VirtualHost {
* {
Pattern = .*
RewriteRules {
* {