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
print "Hello World!\n"; |
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 | |
## base config | |
MYSQL_BIN=mysql | |
MYSQL_USER=user | |
MYSQL_PASSWD=password | |
## dbname | |
if [ "$1" = "" ]; then | |
echo "no database name" | |
exit 1; |
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/bin/php | |
<?php | |
/** | |
* Hyper Pudding | |
* - yet another rapid and stupid search engine for PHP source code. - | |
* | |
* @author DQNEO (forked from sotarok) | |
* @see http://www.slideshare.net/sotarok/php-source-code-search-with-php | |
* @versoin 0.0.1 | |
* @license The MIT License |
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
<?php | |
class Mother | |
{ | |
public function __construct() | |
{ | |
echo "I am Mother. \n"; | |
} | |
} | |
class Child extends Mother |
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
use strict; | |
use warnings; | |
use List::Util; | |
my @photos = List::Util::shuffle glob('*.jpg'); | |
print "var photos = [\n"; | |
for my $photo (@photos) { | |
print "'$photo',\n"; | |
} |
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
QUERY PLAN | |
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | |
Sort (cost=1568.27..1568.51 rows=96 width=260) (actual time=822.175..822.259 rows=198 loops=1) | |
Sort Key: e.pgd, e.evtno, p.ptgno | |
Sort Method: quicksort Memory: 100kB | |
-> Nested Loop (cost=87.12..1565.11 rows=96 width=260) (actual time=15.763..821.403 rows=198 loops=1) | |
-> Nested Loop (cost=87.12..1309.65 rows=96 width=256) (actual time=15.729..792.478 rows=198 loops=1) | |
-> Hash Join (cost=87.12..1058.64 rows=96 width=256) (actual time=15.703..791.253 rows=198 loops=1) | |
Hash Cond: (e.grpsno = g.grpsno) | |
-> Nested Loop (cost=0.00..970.13 rows=112 width=226) (actual time=13.304..788.536 rows=198 loops=1) |
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
use strict; | |
use warnings; | |
use GD; | |
my @files= glob("*.JPG"); | |
my $n = @files; | |
print "handling $n files...\n"; | |
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 | |
# | |
# ※これはただの落書きみたいなものです。マネしないで!! | |
# | |
# 1. このファイルをローカルからリモートサーバに転送する。 | |
# scp init.sh -i key.pem [email protected] | |
# | |
# 2. リモートサーバにログインして、root権限で実行する | |
# $ ssh -i key.pem [email protected] | |
# # bash init.sh |
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 | |
# | |
# deploy.sh : subversion用のデプロイツール | |
# | |
# | |
# Usage: | |
# deploy.sh | |
# 引数はありません。 | |
# | |
# Output: |
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 | |
## | |
# 重複起動防止 | |
# /tmp/{スクリプト名}.pid というファイルが作成されます。 | |
# | |
# テスト方法 | |
# while true ; do script.sh ; done | |
function pid_start() { |
OlderNewer