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 | |
# Do clean rebuilds of both platforms after reinstalling fresh dependencies | |
# Useful during (eg) periodic upgrades of dependencies, to make sure everything | |
# still works at each step. Run one iOS and one Android simulator first. | |
# Keep this script outside your source tree (eg, /usr/local/bin/rn_rebuild) | |
set -x # echo each command | |
set -e # die on error (except when we "|| set exit 0") | |
# Extract our app's bundle ID. |
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
# Additional configuration for erlinit | |
# Customized (see BJS) from the nerves default | |
# from deps/nerves_system_rpi2/rootfs-additions/etc/erlinit.config | |
# Turn on the debug prints | |
#-v | |
# Specify the UART port that the shell should use. | |
# BJS: was -c tty1 | |
-c ttyS0 |
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
# Make sure ntpd doesn't give up if the time is way off | |
cp /etc/ntp.conf /etc/ntp.conf.old | |
(echo tinker panic 0; cat /etc/ntp.conf.old) >/etc/ntp.conf | |
/etc/init.d/ntp restart |
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
bash -c ' | |
<%= "export http_proxy=\"#{knife_config[:bootstrap_proxy]}\"" if knife_config[:bootstrap_proxy] -%> | |
<% private_ip = (@config[:first_boot_attributes]["ip_addresses"] || []).select{|x| x =~ /^192.168/ }.first | |
if private_ip -%> | |
function add_private_network_and_proxy() { | |
cat <<'EOP' >>/etc/network/interfaces | |
auto eth0:0 | |
iface eth0:0 inet static |
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
Downloading http://rubyenterpriseedition.googlecode.com/files/ruby-enterprise-1.8.7-2012.02.tar.gz... | |
Installing ruby-enterprise-1.8.7-2012.02... | |
--2012-06-03 11:59:59-- https://github.com/wayneeseguin/rvm/raw/master/patches/ree/1.8.7/tcmalloc.patch | |
Resolving github.com (github.com)... 207.97.227.239 | |
Connecting to github.com (github.com)|207.97.227.239|:443... connected. | |
HTTP request sent, awaiting response... 302 Found | |
Location: https://raw.github.com/wayneeseguin/rvm/master/patches/ree/1.8.7/tcmalloc.patch [following] | |
--2012-06-03 12:00:00-- https://raw.github.com/wayneeseguin/rvm/master/patches/ree/1.8.7/tcmalloc.patch | |
Resolving raw.github.com (raw.github.com)... 207.97.227.243 | |
Connecting to raw.github.com (raw.github.com)|207.97.227.243|:443... connected. |
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
# See http://selfamusementpark.com/blog/2011/12/13/rubymine-firefox-and-exception-backtraces/ | |
# | |
# In Rubymine, do File -> Create Command-line Launcher | |
# -- name it "mine", put in /usr/local/bin | |
# | |
# Also, create executable /usr/local/bin/firefox_to_mine with: | |
# #!/usr/bin/ruby | |
# url = ARGV.first | |
# if url =~ /^mine\:([^\?]+)\?(.*)$/ | |
# `mine --line #{$2} #{$1}` |
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
# NewRelic really wants me to know when it's not running. I don't care. | |
module NewRelic | |
class Control | |
module Frameworks | |
class Rails | |
def log_with_quieting!(msg, level=:info) | |
log_without_quieting!(msg, level) \ | |
unless msg == "New Relic Agent not running." | |
end | |
alias_method_chain :log!, :quieting |
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
# Monkeypatch the activerecord logger to colorize database-changing statements different | |
# from non-changing statements (instead of the blue-baring it does by default) | |
class ActiveRecord::ConnectionAdapters::AbstractAdapter | |
protected | |
def format_log_entry(message, dump = nil) | |
if ActiveRecord::Base.colorize_logging | |
if message =~ / (Update|Create) / | |
message_color, dump_color = "4;35;1", "0" | |
else |
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
+ [[ -z '' ]] | |
+ export 'PS4=+[${BASH_SOURCE}] : ${LINENO} : ${FUNCNAME[0]:+${FUNCNAME[0]}() $ }' | |
+ PS4='+[${BASH_SOURCE}] : ${LINENO} : ${FUNCNAME[0]:+${FUNCNAME[0]}() $ }' | |
+[/usr/local/rvm/scripts/cli] : 709 : __rvm_parse_args() $ [[ -z '' ]] | |
+[/usr/local/rvm/scripts/cli] : 709 : __rvm_parse_args() $ [[ -n '' ]] | |
+[/usr/local/rvm/scripts/cli] : 711 : __rvm_parse_args() $ [[ 0 -eq 1 ]] | |
+[/usr/local/rvm/scripts/cli] : 711 : __rvm_parse_args() $ [[ -n '' ]] | |
+[/usr/local/rvm/scripts/cli] : 31 : __rvm_parse_args() $ [[ -n rubygems ]] | |
+[/usr/local/rvm/scripts/cli] : 33 : __rvm_parse_args() $ rvm_token=rubygems | |
+[/usr/local/rvm/scripts/cli] : 35 : __rvm_parse_args() $ [[ 1 -gt 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
root@vbox3:/usr/local/rvm/src/rubygems-1.4.1# ls -R | |
.: | |
bin cruise_config.rb hide_lib_for_update lib Manifest.txt Rakefile README.rdoc test | |
ChangeLog GPL.txt History.txt LICENSE.txt pkgs README setup.rb util | |
./bin: | |
gem update_rubygems | |
./hide_lib_for_update: | |
note.txt |
NewerOlder