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
<meta http-equiv="refresh" content="0;url=/next/" /> |
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
rsync -ahvu --delete --exclude=".*" public/ dev:/var/www/html/ | |
echo "\npublished: https://usagizmo.com/\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
var fs = require('fs'); | |
var glob = require('glob'); | |
var path = require('path'); | |
var Exif = require('exif').ExifImage; | |
var imageDir = 'photos/'; | |
glob('Masters/**/*', function(err, files) { | |
if (err) throw err; | |
files.forEach(function(file) { |
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
# coding: utf-8 | |
require 'find' | |
require 'time' | |
Find.find 'files' do |f| | |
if File.basename(f).match /\d{4}-\d{2}-\d{2} \d{2}\.\d{2}\.\d{2}/ | |
originaltime = Time.parse File.basename(f, File.extname(f)).gsub '.', ':' | |
File.utime File.atime(f), originaltime, f unless originaltime.nil? | |
end |
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
# coding: utf-8 | |
require 'find' | |
require 'fileutils' | |
Find.find('files') do |f| | |
next unless File.file? f | |
size = File.size?(f) | |
if size.nil? || size < 10000 # 10KB | |
puts f |
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
# coding: utf-8 | |
require 'mini_exiftool' | |
require 'find' | |
Find.find('files') do |f| | |
next unless File.file? f | |
begin | |
exif = MiniExiftool.new f | |
rescue |
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
function saveForWebPNG(doc, folder, filename) { | |
var sfwOptions = new ExportOptionsSaveForWeb(); | |
sfwOptions.format = SaveDocumentType.PNG; | |
sfwOptions.PNG8 = false; | |
doc.exportDocument(new File(folder + '/' + filename), ExportType.SAVEFORWEB, sfwOptions); | |
} | |
function main() { | |
var inputFolder = Folder.selectDialog('トリミングしたい画像の入ったフォルダを選択してください'); |
NewerOlder