Skip to content

Instantly share code, notes, and snippets.

View masahide's full-sized avatar

YAMASAKI Masahide masahide

View GitHub Profile
@hnakamur
hnakamur / ansible-directories.yml
Created August 19, 2013 05:21
First add localhost to your inventory file (ex. /etc/ansible/hosts or ~/.ansible/hosts) and then run ansible-playbook ansible-directories.yml
- hosts: localhost
connection: local
vars:
role: common
tasks:
- name: create directories for ansible files.
file: path={{ item }} state=directory
with_items:
- group_vars
- host_vars
@Gab-km
Gab-km / github-flow.ja.md
Last active July 1, 2025 15:44 — forked from juno/github-flow.ja.md
GitHub Flow (Japanese translation)
@kylelemons
kylelemons / piping.go
Last active May 31, 2024 09:07 — forked from dagoof/piping.go
piping exec.Cmd in golang (example sorts all regular files under a directory by their extension)
package main
import (
"bytes"
"exec"
"log"
"os"
)
// Pipeline strings together the given exec.Cmd commands in a similar fashion
@vmihailenco
vmihailenco / proxy.go
Created November 20, 2011 15:22
Simple TCP proxy in Golang
package main
import (
"bytes"
"encoding/hex"
"flag"
"fmt"
"io"
"log"
"net"
@dahnielson
dahnielson / UUID.php
Last active January 14, 2025 05:54
Pure PHP UUID generator
<?php
/**
* UUID class
*
* The following class generates VALID RFC 4122 COMPLIANT
* Universally Unique IDentifiers (UUID) version 3, 4 and 5.
*
* UUIDs generated validates using OSSP UUID Tool, and output
* for named-based UUIDs are exactly the same. This is a pure
* PHP implementation.
#!/usr/bin/perl
use strict;
use warnings;
use IO::Socket::INET;
use Getopt::Long;
my $port = 7003;
my $host = '127.0.0.1';
my $timeout = 10;