This file contains hidden or 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 Foundation | |
extension CharacterSet { | |
static var fileNameAllowed: CharacterSet { | |
return CharacterSet(charactersIn: "/").inverted | |
} | |
} |
This file contains hidden or 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
## this script depends on 'mp4art', one part of 'mp4v2'. | |
# brew install mp4v2 | |
## if you need to remove artworks first, | |
# find . -type f -name '*.m4a' -print0 | xargs -0 mp4art --remove | |
## find local artwork image file and add to '*.m4a' files | |
artwork=`find . -type f \( -name '*.png' -o -name '*.jpg' -o -name '*.jpeg' \) -print | head -1`; | |
if [ -e "$artwork" ]; then find . -type f -name '*.m4a' -print0 | xargs -0 mp4art --add "$artwork" ; fi |
This file contains hidden or 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
<html> | |
<body> | |
<video controls autoplay name="media" style="max-width:100%; max-height:100%"> | |
<source src="Branching Paths Playism 1080p.mp4" type="video/mp4"> | |
<track label="Japanese" kind="captions" src="Branching paths_JP.vtt" srclang="ja" default></track> | |
</video> | |
</body> | |
</html> |
This file contains hidden or 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
javascript:window.location=window.location.href.replace(/(http|https):\/\/store.line.me\/stickershop\/product\/([0-9]*)(\/\w*)/g,'line:\/\/shop\/detail\/$2') |
This file contains hidden or 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 | |
exec ruby -S -x "$0" "$@" | |
#! ruby | |
require 'fssm' | |
specified_path = ARGV[0] | |
# 渡されたパラメータがあれば、それを監視対象のディレクトリにする。 | |
# なければ、ワーキングディレクトリを監視対象にする。 |
This file contains hidden or 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 <UIKit/UIKit.h> | |
@interface UIImage (BezierPath) | |
+ (UIImage *)imageWithBezierPathFill:(UIBezierPath *)bezierPath; | |
+ (UIImage *)imageWithBezierPathStroke:(UIBezierPath *)bezierPath; | |
@end |
This file contains hidden or 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 | |
current_directory=`pwd`; | |
echo "current directory: ""$current_directory"; | |
find . -name ".git" | while read local_git_folder; | |
do | |
cd "$local_git_folder"; | |
cd ..; | |
parent=`pwd`; | |
name=`basename "$parent"`; |
This file contains hidden or 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 | |
################################ | |
# set base word | |
################################ | |
DEFAULT_WORD="foo" | |
word=$DEFAULT_WORD | |
# if argument exists, update word with argument[1] | |
if [ $# -gt 0 ]; then | |
word=$1 | |
fi |
This file contains hidden or 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
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"x-apple-reminder://"]]; |
NewerOlder