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
<div id="FI_col2"> | |
<div id="rotatingFeaturedItems"> | |
<div id="fic1" class="fiBox"> | |
<div style="text-align: center; margin-top: 10px"> | |
<a href="stretchStudy/"><img src="images/layout/v2/featured/StretchStudyLogo-125.png" alt="USATF Stretch Study Logo" width="125" height="65" /></a> | |
<div style="margin-top: 0.1em"><a href="stretchStudy/">Participate in the study</a></div> | |
</div> | |
</div> | |
<div id="fic2" class="fiBox"> |
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
TZip::ClassMethods.find_by_zipcode('02760') | |
# => works | |
ActiveSupport::TimeZone.send(:extend, TZip::ClassMethods) | |
ActiveSupport::TimeZone.find_by_zipcode('02760') | |
# => doesn't work |
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/local/bin/macruby | |
framework 'calendarstore' | |
range = Time.local(Time.now.year, Time.now.mon, Time.now.day)..(Time.local(Time.now.year, Time.now.mon, Time.now.day) + (31 * 3600 * 24)) | |
events = CalCalendarStore.defaultCalendarStore.eventsWithPredicate(CalCalendarStore.eventPredicateWithStartDate(NSDate.dateWithString(range.begin.to_s), endDate:NSDate.dateWithString(range.end.to_s), calendars:CalCalendarStore.defaultCalendarStore.calendars))[0,7] | |
events.each_with_index do |event, i| | |
event.startDate, output = Time.at(event.startDate.timeIntervalSince1970), Array.new | |
if (!events[i-1] || (event.startDate.day != Time.at(events[i-1].startDate.timeIntervalSince1970).day)) |
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
def index | |
@programs = @camp.programs.order('name') | |
# some of these could be scoped out to make the controller cleaner if the queries are going to show up in other places | |
# eg | |
# scope :minage, lambda { |age| where(min_age >= ?, age) } | |
# @programs = @programs.minage(params[:min_age]) if params[:min_age] | |
@programs = @programs.where('min_age >= ?', params[:min_age]) if params[:min_age] | |
@programs = @programs.where('max_age <= ?', params[:max_age]) if params[:max_age] |
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
# command | |
ruby extension.rb {query} | |
# extension.rb | |
_osa1 = 'tell application \"Finder\" to set insertionLocation to insertion location as alias' | |
_osa2 = 'return POSIX path of insertionLocation' | |
activeFinderPath = (`osascript -e "#{_osa1}" -e "#{_osa2}"`).strip | |
filename = 'untitled' | |
extension = 'txt' |
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
{ | |
"color_scheme": "Packages/Theme - Aqua/Color Schemes/Espresso Aqua.tmTheme", | |
"bold_folder_labels": true, | |
"create_window_at_startup": false, | |
"open_files_in_new_window": false, | |
"draw_white_space": "all", | |
"fade_fold_buttons": true, | |
"font_face": "SourceCodePro-Regular", | |
"font_size": 12.0, | |
"ignored_packages": |
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
{ | |
"color_scheme": "Packages/Theme - Aqua/Color Schemes/Espresso Aqua.tmTheme", | |
"bold_folder_labels": true, | |
"create_window_at_startup": false, | |
"open_files_in_new_window": false, | |
"draw_white_space": "all", | |
"fade_fold_buttons": true, | |
"font_face": "SourceCodePro-Regular", | |
"font_size": 12.0, | |
"ignored_packages": |
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
{ | |
"color_scheme": "Packages/Theme - Aqua/Color Schemes/Espresso Aqua.tmTheme", | |
"bold_folder_labels": true, | |
"create_window_at_startup": false, | |
"open_files_in_new_window": false, | |
"draw_white_space": "all", | |
"fade_fold_buttons": true, | |
"font_face": "SourceCodePro-Regular", | |
"font_size": 12.0, | |
"ignored_packages": |
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
echo "|============================================================================================|" | |
echo "| |" | |
echo "| Loading autoexec.cfg |" | |
echo "| Settings config |" | |
sensitivity "1.1" | |
volume 0.50 |
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
<opml version="1.0"> | |
<head> | |
<title>Podcasts</title> | |
<dateCreated>Sat, 19 Jan 2013 16:17:01 GMT</dateCreated> | |
<dateModified>Tue, 4 Mar 2014 05:37:49 GMT</dateModified> | |
</head> | |
<body> | |
<outline text="60-Second Earth" type="rss" xmlUrl="http://www.scientificamerican.com/podcast/sciam_podcast_i_earth.xml" htmlUrl="" /> | |
<outline text="Security Now!" type="rss" xmlUrl="http://leoville.tv/podcasts/sn.xml" htmlUrl="" /> | |
<outline text="99% Invisible" type="rss" xmlUrl="http://feeds.99percentinvisible.org/99percentinvisible" htmlUrl="" /> |
OlderNewer