Skip to content

Instantly share code, notes, and snippets.

View mmisono's full-sized avatar
🌫️
I may be slow to respond.

Masanori Misono mmisono

🌫️
I may be slow to respond.
View GitHub Profile
#!/bin/sh
for i in $@
do
echo 'tell application "'${i}'" to activate' > ${i}_active.scpt
osacompile -o ${i}_active.scpt ${i}_active.scpt
done
--- changelog.vim.old 2010-02-17 17:10:26.000000000 +0900
+++ changelog.vim.new 2010-02-17 17:32:43.000000000 +0900
@@ -121,12 +121,12 @@
" Format used for new date entries.
if !exists('g:changelog_new_date_format')
- let g:changelog_new_date_format = "%d %u\n\n\t* %c\n\n"
+ let g:changelog_new_date_format = "%d %u\n\n\t*%p %c\n\n"
endif
snippet php
<?php
${1}
?>
snippet pecho
<?php echo ${1} ?>${0}
snippet if
if [ ${1:condition} ]; then
${0:#statements}
fi
snippet el
else
${0:#statements}
snippet sel
@selector(${1:method}:)
snippet imp
#import <${1:Cocoa/Cocoa.h}>
snippet Imp
#import "${1}}"
#!/bin/sh
tmpfile=~/.screen/termtter
if [ -e $tmpfile ] ; then
screen -X eval 'resize 10' 'focus up'
rm $tmpfile
else
screen -X eval 'focus bottom' 'resize max'
touch $tmpfile
# -*- coding: utf-8 -*-
# タイムライン取得後に線を入れる
Termtter::Client.register_hook(
:name => :add_line,
:points => [:output],
:exec_proc => lambda {
puts '-' * `echo $COLUMNS`.to_i
}
)
snippet :f
${1:method_name}: function(${2:attribute}){
${0}
}
snippet func
function ${1:function_name} (${2:argument}) {
${0:// body...}
}
snippet pu
public
snippet po
protected
snippet pr
private
snippet script
script ${1:new_object}
on run
${2:-- do something interesting}
end run
end script
snippet on
on ${1:functionName}(${2:arguments})