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
// Settings in here override those in "Default/Preferences.sublime-settings", and | |
// are overridden in turn by file type specific settings. | |
{ | |
// カーソルのスタイル | |
"caret_style": "blink", | |
// フォント | |
//"font_face": "DejaVuSans", | |
// フォントサイズ | |
"font_size": 12.0, | |
// タブによる補完 |
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
/var/log/mysqld.log /var/lib/mysqld/*log { | |
daily | |
rotate 31 | |
dateext | |
missingok | |
postrotate | |
# just if mysqld is really running | |
if test -x /usr/bin/mysqladmin && \ | |
/usr/bin/mysqladmin -u <user> -p<password> ping &>/dev/null | |
then |
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
public PutObjectResult put(String key, InputStream input, long length) { | |
ObjectMetadata objectMetadata = new ObjectMetadata(); | |
objectMetadata.setContentLength(length); | |
objectMetadata.setContentType("image/gif"); | |
PutObjectRequest request = new PutObjectRequest(this.bucket, key, input, objectMetadata); | |
request.withCannedAcl(CannedAccessControlList.PublicRead); | |
log.info("S3にファイルをアップロードします… bucket:" + this.bucket + "\tkey:" + key); | |
PutObjectResult result = this.s3Client.putObject(request); | |
log.info("S3にファイルをアップロードしました。 bucket:" + this.bucket + "\tkey:" + key); |
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
<!DOCTYPE HTML> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<title>Thumbnail Load Example</title> | |
</head> | |
<body> | |
<h2>Select an image file</h2> | |
<p><input id="file-input" type="file"></p> | |
<div id="result" class="well"> |
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
while : ;do date; vmstat 2 30; echo -e "------------------------------------------------------\n\n"; done | |
while : ;do date; mpstat -P ALL 2 30; echo -e "------------------------------------------------------\n\n"; done | |
while : ;do date; free; sleep 10; echo -e "------------------------------------------------------\n\n"; done | |
while : ;do date; top -b -n 1 | head -20; sleep 2; echo -e "------------------------------------------------------\n\n"; done | |
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 | |
#------------------------- | |
# define | |
#------------------------- | |
OUTPUT="/var/log/messages" | |
LANG="C" | |
#------------------------ |
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 | |
LOG_FILE="access_log-20130310" | |
for i in `seq 4 1 23`; do | |
hour=`printf "%02d" ${i}` | |
# sourceIp | |
grep "09/Mar/2013:${hour}" ${LOG_FILE} | awk '{print $1}' | sort | uniq -c | sort -r > ip-${hour}.log | |
# url | |
grep "09/Mar/2013:${hour}" ${LOG_FILE} | awk '{print $7}' | sort | uniq -c | sort -r > url-${hour}.log |
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.awt.Font; | |
import java.awt.GraphicsEnvironment; | |
public class FontsList { | |
Font [] fonts=GraphicsEnvironment.getLocalGraphicsEnvironment().getAllFonts(); | |
FontsList(String as[]){ | |
char dspchr=0; | |
int fnumber=fonts.length; | |
int sp,n=0; |
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 | |
MYSQL_USER="mysql" | |
MYSQL_PASS="password" | |
MYSQL_HOST_MASTER[0]="192.168.0.1" | |
MYSQL_HOST_MASTER[1]="192.168.0.2" | |
MYSQL_HOST_SLAVE[0]="192.168.0.2" | |
MYSQL_HOST_SLAVE[1]="192.168.0.3" | |
echo "------------------" |
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 | |
#-------------------------------------- | |
# | |
# Author(s): | |
# | |
# K.Kadoyama | |
# | |
# Usage: | |
# | |
# mon_put.bash |
OlderNewer