Skip to content

Instantly share code, notes, and snippets.

View gardejo's full-sized avatar

MORIYA Masaki gardejo

View GitHub Profile
@gardejo
gardejo / asahi.ps1
Last active October 20, 2018 08:38
An crafty command-line interface to open the page viewer of the Asahi Shimbun.
<#
.SYNOPSIS
`asahi.ps1` : Open the latest issue, morning edition.
`asahi.ps1 ev` : Open the latest issue, evening edition.
`asahi.ps1 -issue 20180101 -edition ev` : Open the specified issue/edition.
`asahi.ps1 -duration -5 -edition ev` : Open the specified issue/edition.
.DESCRIPTION
An crafty command-line interface to open the page viewer of the Asahi Shimbun.
/**
* @file KeySnail initialization sub-sucript: Hooks.
* @copyright Copyright (c) 2012-2015 MORIYA Masaki, alias "Gardejo".
* @author gardejo@ermitejo.com (MORIYA Masaki, alias "Gardejo")
* @license This file is available under The MIT License.
* See `.keysnail.d/doc/license.txt`.
* @see https://github.com/mooz/keysnail/wiki/Hook
*/
'use strict';
@gardejo
gardejo / hoge.js
Last active September 30, 2015 15:14 — forked from mooz/hoge.js
/**
* List session history of the current (selected) tab.
* CAVEAT: `nsIFaviconService#getFaviconForPage()` is obsoleted since
* Firefox 22.0. Use `mozIAsyncFavicons#getFaviconURLForPage()` instead.
* CAVEAT: Do not use strict mode.
* @see https://gist.github.com/mooz/284632
* @see http://malblue.tumblr.com/post/349001250/tips-japanese-keysnail-github
* @see https://gist.github.com/958/895703
* @todo How do we get timestamp on a page from session history?
* @todo nsISHistory#PurgeHistory()
@gardejo
gardejo / ooo.txt
Created November 24, 2011 00:10
Out of office in English, Esperanto and Japanese
(lang:en)
Thank you for your message.
I am on a business trip and shall be back on 28th November. Until then I have no access to my e-mail. I will reply to you as soon as possible.
Apologies for the delay in responding.
(lang:eo)
Dankon al vi pro via mesaĝo.
Mi faras negocan vojaĝon kaj reiros je la 28-a de Novembro. Ĝis tiam mi ne aliras mian retpoŝton. Mi respondos al vi kiel eble plej rapide.
Pardonpetoj por la malrapideco de respondo.
@gardejo
gardejo / fizz_buzz.dart
Created October 10, 2011 18:30
Fizz Buzz on Dart (1)
// fizz_buzz.dart
// http://try-dart-lang.appspot.com/s/nI4R
main() {
String fizz = 'Fizz';
String buzz = 'Buzz';
for (int number = 1; number <= 100; number ++) {
bool is_fizz = number % 3 == 0;
bool is_buzz = number % 5 == 0;

NAME

Test - foo bar baz

DESCRIPTION

test code

@gardejo
gardejo / Codes.pod
Created August 25, 2011 17:56
Reorganization of MooseX::Types::Locale::Language
package MooseX::Types::Locale::Codes; # ****************************************************************************** # Dependency(-ies) # ****************************************************************************** # ============================================================================== # Pragma(ta) # ==============================================================================
@gardejo
gardejo / class_table_inheritance.pl
Created December 9, 2010 15:45
Several implementation for the table inheritance patterns (with DBIx::ObjectMapper)
#!/usr/bin/perl
use 5.008_001;
use strict;
use warnings;
use utf8;
use FindBin;
use lib "$FindBin::Bin/../lib";
@gardejo
gardejo / class_table_inheritance.pl
Created December 7, 2010 16:58
Several implementation for the table inheritance patterns
#!/usr/bin/perl
use 5.010_000;
use strict;
use warnings;
use utf8;
use FindBin;
use lib "$FindBin::Bin/../lib";
@gardejo
gardejo / example.pl.bat
Created May 29, 2010 07:49
Force them to run your script with the intentional interpreter!
@rem= '
@echo off
setlocal EnableExtensions EnableDelayedExpansion
if "%strawberry%" equ "" (
set strawberry=\\{OUR_SHARED_DIRECTORY}\env\perl\5.12.0.1\
)
set path=%path%;%strawberry%\c\bin;%strawberry%\perl\bin;%strawberry%\perl\site\bin
set perl=%strawberry%\perl\bin\perl.exe