-
公式ドキュメント(日本語訳版) -- http://www.playframework-ja.org/documentation/2.1.5/Home --- 「はじめに」 --- 「Java 開発者のための Play」
-
リポジトリ -- https://github.com/playframework/playframework
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.File; | |
import java.io.IOException; | |
import java.io.InputStream; | |
import java.io.OutputStream; | |
import java.io.PrintStream; | |
import java.io.DataInputStream; | |
import java.io.FileInputStream; | |
import java.util.Scanner; | |
import java.net.ServerSocket; | |
import java.net.Socket; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<packages> | |
<package id="lhaplus" /> | |
<package id="windowslivemail" /> | |
<package id="adobereader" /> | |
<package id="googlejapaneseinput" /> | |
<package id="git" /> | |
<package id="google-chrome-x64 " /> | |
<package id="firefox" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/local/bin/python | |
import socket | |
import os | |
from subprocess import Popen, PIPE | |
PORT_NO = 8080 | |
HOSTNAME = '' | |
SCRIPT = "listen" | |
def main(): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <string.h> | |
#include <stdlib.h> | |
int main() { | |
char buf[15], *token1; | |
int i, count, n, sum; | |
sum = 0; | |
fgets(buf, sizeof(buf), stdin); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NEWHOSTNAME=$1 | |
ROOTPASSWD=$2 | |
# Keymap | |
loadkeys jp106 | |
# Setup HDD | |
parted /dev/sda mklabel gpt | |
parted /dev/sda mkpart primary btrfs 1049KB 8591MB | |
parted /dev/sda mkpart primary linux-swap 8591MB 10.7GB |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
readonly PREFIX=/usr/jails | |
resolvconf -u | |
ls $PREFIX/*/etc/resolv.conf | xargs -I@ cp -v /etc/resolv.conf @ | |
ls $PREFIX/flavors/*/etc/resolv.conf | xargs -I@ cp -v /etc/resolv.conf @ | |
resolvconf -l |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
USAGE(){ | |
cat <<++EOS >&2 | |
USAGE:`basename $0` jail_name ip_address user_flavor [ -y root_password default_user default_user_password ] | |
++EOS | |
} | |
# const | |
PREFIX=/usr/jails |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
USAGE(){ | |
cat <<++EOS >&2 | |
USAGE:`basename $0` jail_name ip_address flavor [ -y root_password default_user default_user_password ] | |
++EOS | |
} | |
# Const | |
NIC=em1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
WORKDIR=anubis | |
mkdir -p $WORKDIR | |
cat Data.csv | awk 'NR>1' | tr ',' '/' | xargs -I% echo mkdir -p $WORKDIR/% | sh | |
function spread() { | |
echo "<td rowspan=\"`find "$2" | wc -l`\">$1</td>" | |
ls "$2" | while read L |