夜桜
iPhone 5 Wallpaper - Stormtrooper Prism
Love is Overdrive
ラブ・イズ・オーバーっていう、超有名な曲があって、 ラブ・イズ・オーバーは、愛が終わったって意味やけど 愛が終わっただけでは寂しいんで ラブ・イズ・オーバーでドライブしたら ラブ・イズ・オーバー・ドライブ オーバードライブしてたら愛は全開に変わった
ヤバオカムーブメンツ・中村隆太
Sexisim on the Red Carpet
During an E! interview at a red carpet ceremony, the camera operator takes a sweeping toe-to-head shot of Cate Blanchett, when she crouches down to ask, “Do you do that to the guys?” The internet explodes with opinion, and more fuel is added to the increasing fight against the objectification of women in media.
The way I see it, the camera operator was just doing their job. Red carpet ceremonies are events focused on fashion, and Cate Blanchett was wearing a very nice gown that should be seen in its entirety. No, most male guests would not have received the same treatment, because most male guests would be wearing suits or tuxedos and everybody knows what black pants look like.
The real issue here is not the camera operator’s actions. The tragedy is that filming a gown at a fashion event can be taken as an attack, if the gown is being worn by a woman. That’s where sexism in our society has taken us. There is a lot of work to be done in changing attitudes and healing wounds before gender equality has a shot at realization.
Replace Text in File - OSX Service
A quick Mac OSX service that will search and replace all given strings in a text file, and save the modified content as a new file. It’s not that much faster than just opening it in a text editor, but it was a fun way to learn how sed works.
It just runs a simple AppleScript that prompts for the query strings and new filename, and then runs sed through the shell to do the string replacements.
on run {input, parameters}
set filepath to quoted form of POSIX path of (first item of input)
set folderpath to quoted form of POSIX path of (POSIX file (do shell script "dirname " & filepath)) & "/"
set findText to text returned of (display dialog "Enter search string" default answer "")
set replaceText to text returned of (display dialog "Enter replace string" default answer "")
set newfilepath to folderpath & text returned of (display dialog "Enter new file name" default answer "")
do shell script "export LC_CTYPE=C;export LANG=C;sed 's/" & findText & "/" & replaceText & "/g' " & filepath & " > " & newfilepath
end run
After downloading, unzip and place the file in ~/Library/Services (or create the folder first if it doesn’t exist already)
After doing so, you should be able to simply right-click a file in Finder to see the “Replace Text” option. (You might find it under a “Services” category)
If The Moon Were Only 1 Pixel
A tediously accurate scale model of the solar system
I can’t even begin to grasp how big things in space are, but this does a pretty good job explaining.
Terminal Theme
You can download the theme here
Colors were taken from the Base16 TextMate theme, and the font is Source Code Pro
These sites describe how to get your Terminal to start showing colors.
Chargekey Review
I recently received a review unit of the Chargekey.
It’s essentially a key-sized USB to Lightning cable that you will can have available on your keychain (They also make a Micro-USB version to fit your Android phone). I don’t do too much wandering around during the day, but I hadn’t bought a second cable for charging my phone while at work so I was more than happy to start making daily use of this.
Tokyo's Cityscape Recreated With Stickers
By artist Yukino Ohmura.
Rake task to backup MySQL to Amazon S3
A simple rake task to dump the contents of a MySQL database and save it to an Amazon S3 bucket. Use together with whenever to automate it.
namespace :backup do
task :nightly do
timestamp = Time.now.strftime("%Y-%m-%d_%H-%M-%S")
backup_file = "tmp/backups/#{timestamp}_dump.sql.gz"
`mkdir -p tmp/backups`
`mysqldump -u root {DATABASE_NAME} | gzip -c > #{backup_file}`
send_to_s3 backup_file
end
def send_to_s3(file_path)
bucket = "{BUCKET_NAME}"
file_name = File.basename(file_path)
AWS::S3::DEFAULT_HOST.replace "s3-us-west-2.amazonaws.com"
AWS::S3::Base.establish_connection!(
:access_key_id => '{KEY}',
:secret_access_key => '{SECRET}')
AWS::S3::S3Object.store(
"backups/#{file_name}",
File.open("#{file_path}"),
bucket)
end
end