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
for region in `ec2-describe-regions | awk '{print $2}'` ; do for i in `ec2-describe-instances --region $region -F "root-device-type=ebs" | grep ^INSTANCE | awK '{print $2}'` ; do echo -n "$region " ; ec2-describe-instance-attribute --region $region --instance-initiated-shutdown-behavior $i ; done ; 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
Add-Type -Path "C:\Program Files\AWS SDK for .NET\bin\AWSSDK.dll" | |
$secretKeyID="secretkeyid" | |
$secretAccessKeyID="accesskeyid" | |
$client=[Amazon.AWSClientFactory]::CreateAmazonS3Client($secretAccessKeyID,$secretKeyID) | |
$backup_directory="C:\hoge\" | |
foreach($file in Get-ChildItem -Path $backup_directory){ |
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/python | |
# coding=utf-8 | |
# http://moimoitei.blogspot.com/2011/03/google-python-google-reader-api.html を参考にさせていただきました | |
import gdata.service | |
import json | |
import re | |
import boto |
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
Add-Type -Path "C:\Program Files\AWS SDK for .NET\bin\AWSSDK.dll" | |
$secretKeyID="secretkeyid" | |
$secretAccessKeyID="accesskeyid" | |
$client=[Amazon.AWSClientFactory]::CreateAmazonS3Client($secretAccessKeyID,$secretKeyID) | |
$backup_directory="C:\target\" | |
foreach($file in Get-ChildItem -Path $backup_directory){ |
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
using System; | |
using System.Collections.Generic; | |
using System.IO; | |
using System.Linq; | |
using System.Text; | |
using Amazon; | |
using Amazon.Route53; | |
using Amazon.Route53.Model; |
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/env perl | |
$|=1; | |
for(;;) | |
{ | |
print "."; | |
sleep 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/env ruby | |
ARGF.each do |line| | |
line = line.chomp | |
data = line.split(/ /) | |
# IP address is 5th column if split by space | |
ip = data[4] | |
key = ip | |
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/env ruby | |
require 'socket' | |
ARGF.each do |line| | |
line = line.chomp | |
data = line.split(/\t/) | |
ip = data[0] | |
# resolve IP to hostname and split by '.' | |
hostname=Socket.getnameinfo([nil, nil, nil, ip])[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
#!/usr/bin/env ruby | |
# Ruby code for reduce.rb | |
prev_key = nil | |
key_total = 0 | |
ARGF.each do |line| | |
# remove any newline | |
line = line.chomp |
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
// ==UserScript== | |
// @name NiconicoToggleNew | |
// @namespace j3tm0t0.gmail.com | |
// @description Toggle Showing All or New | |
// @include http://www.nicovideo.jp/ranking/* | |
// @require http://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js | |
// ==/UserScript== | |
(function(){ | |
var onKeyDown = function(event) |
OlderNewer