Skip to content

Instantly share code, notes, and snippets.

View mackee's full-sized avatar

mackee mackee

  • KAYAC Inc.
  • Japan
View GitHub Profile
@mackee
mackee / go.mod
Created March 4, 2022 13:54
The `perl` fall block game
module github.com/mackee/sandbox/goperlfallblock
go 1.16
require (
github.com/JoelOtter/termloop v0.0.0-20210806173944-5f7c38744afb // indirect
github.com/Songmu/strrand v0.0.0-20181014100012-5195340ba52c // indirect
github.com/nsf/termbox-go v1.1.1 // indirect
)
@mackee
mackee / buildguide.md
Last active March 31, 2020 14:04
左手キーボード Pulsarの組み立て方(build guide)

Pulsar build guide

この文章は技術書典7などで頒布した左手キーボード Pulsarの組み立て方の説明です。

同梱しているもの

もし欠品や不具合等がありましたら、@mackee_wまで連絡をお願いします。

Pulsar 基板本体

@mackee
mackee / main_test.go
Created October 18, 2019 10:38
Map performance degradation of key length
package main
import (
"bytes"
"math/rand"
"testing"
)
func genKey(n int) string {
ss := &bytes.Buffer{}
@mackee
mackee / gomx
Last active October 9, 2019 03:38
too simple tool dependencies installer and executor in Golang
#!/usr/bin/perl
use strict;
use warnings;
use utf8;
=head1 SYNOPSIS
gomx - too simple tool dependencies installer and executor in Golang
$ gomx install github.com/golang/mock/mockgen
@mackee
mackee / pprtree.pl
Created January 21, 2019 04:29
A visualization of PPR.pm for help us understand
#!/usr/bin/env perl
use 5.28.0;
use warnings;
use utf8;
use Path::Tiny;
use PPR;
use PPIx::Regexp::Dumper;
my $file = path("PPR/lib/PPR.pm");
@mackee
mackee / engineio.go
Created December 18, 2018 01:43
Poor Socket.IO Proxy for debug
package main
import (
"encoding/json"
"fmt"
"log"
)
type Parser interface {
Parse(string) error
@mackee
mackee / index.tmpl
Created December 2, 2018 14:55
Go de CGI
<html lang="ja">
<head>
<meta charset="UTF-8">
<title>ようこそ! GoでCGIのホームページへ!</title>
</head>
<body style="text-align: center; margin: 0 auto; width: 800px; background-color: lightseagreen;">
<h1>ようこそ!GoでCGIのホームページへ!<h1>
<hr>
#!/usr/bin/env perl
use strict;
use warnings;
use utf8;
use constant {
GITHUB_ENDPOINT => 'https://github.com/%s.keys',
VULTR_ENDPOINT => 'https://api.vultr.com/v1/server/list'
};
@mackee
mackee / tailer.py
Created August 1, 2012 07:16 — forked from narusemotoki/tailer.py
日付などでファイルが切り替わるログをtailで表示します.新しいファイルができると,そちらに切り替わります.引数でログファイルが置かれるディレクトリを指定してください.
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import sys
import os
import time
import subprocess
from threading import Thread
import signal
use strict;
use warnings;
use Test::MockTime ':all';
use Time::Piece::Plus;
use Test::More;
use YAPC;
subtest 'is_yet()' => sub {