おことわり:これはコミュニティから来た任意の人によって作られた非公式なコメントです。私はio.jsの公式な代表ではありません。何か質問がある人はnode-forward
discussionsリポジトリのissueを開いて下さい
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
#!/bin/bash | |
# BSD sed | |
for keg in /usr/local/Library/LinkedKegs/*; do kegname="$(basename $keg)"; dir="$(find $keg/ -maxdepth 1 -type d | grep '\/\(sbin\|bin\|etc\|var\|lib\|include\|libexec\|share\)$' | head -n1)"; [ -z "${dir}" ] && continue; testee="$(find $dir -type f | head -n1 | sed -e "s|${keg}||")"; test -f /usr/local/$testee || (echo $keg && brew unlink $kegname; brew link --force $kegname); 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
if [ ! -f $HOME/local/bin/diff-highlight ] | |
then | |
wget https://raw.githubusercontent.com/git/git/34d9819e0a387be6d49cffe67458036450d6d0d5/contrib/diff-highlight/diff-highlight | |
wget https://gist.githubusercontent.com/a2ikm/2dbfb89114dfa5c543ed/raw/e2d8d550ef601c9310712f4187b803658427dd42/diff-highlight.utf8.patch | |
patch -u diff-highlight < diff-highlight.utf8.patch | |
chmod +x diff-highlight | |
rm diff-hilight.orig diff-hilight.utf8.patch | |
mkdir -p $HOME/local/bin | |
mv diff-highlight $HOME/local/bin | |
fi |
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
- (NSString *)text6Compatible | |
{ | |
return self.text; | |
} | |
- (void)setText6Compatible:(NSString *)text6Compatible | |
{ | |
self.text = text6Compatible; | |
if (SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(7)) { |
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
#compdef cap | |
# ------------------------------------------------------------------------------ | |
# Description | |
# ----------- | |
# | |
# Completion script for Capistrano (http://capistranorb.com/). | |
# | |
# ------------------------------------------------------------------------------ | |
# Authors | |
# ------- |
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/perl -l | |
use strict; | |
use warnings; | |
$ENV{LANG} = "C"; | |
$ENV{PATH} ||= "/usr/local/bin:/usr/bin/:/bin"; | |
my $eth = shift || "eth0"; | |
`ip addr list dev $eth|grep 'inet '` =~ m{\.(\d+?)\.(\d+?)\/}; |
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
// semicolonless Java | |
public class A | |
{ | |
public static void main(String[] args) { | |
return\u003b | |
} | |
} |
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
# | |
#= dump database to yaml for fixtures | |
# | |
# originated by elm200 <http://d.hatena.ne.jp/elm200/20070928/1190947947> | |
# | |
#== install | |
# | |
# move this file to RAILS_ROOT/lib/tasks/extract_fixtures.rake | |
# | |
namespace :db do |
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
ja: | |
# extract from activesupport | |
date: | |
formats: | |
default: "%Y/%m/%d" | |
short: "%m/%d" | |
long: "%Y年%m月%d日(%a)" | |
day_names: [日曜日, 月曜日, 火曜日, 水曜日, 木曜日, 金曜日, 土曜日] | |
abbr_day_names: [日, 月, 火, 水, 木, 金, 土] |
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 background, see http://m.onkey.org/use-index-with-active-record-finders | |
# and http://twitter.com/#!/dougalcorn/status/4963159878139904 | |
from = "#{quoted_table_name} USE INDEX(index_activities_on_created_at_and_country_id)" | |
Activity.from(from).where('created_at >= ? AND country_id = ?', 10.days.ago, 79).all |
OlderNewer