This is a test.
Updated. Again.
class DevelopmentProfiler | |
def self.prof(file_name) | |
RubyProf.start | |
yield | |
results = RubyProf.stop | |
# Print a flat profile to text | |
File.open "#{Rails.root}/tmp/performance/#{file_name}-graph.html", 'w' do |file| |
#! /usr/bin/ruby | |
# cfile.rb | |
# Hilton Lipschitz | |
# Use and modify freely, attribution appreciated | |
# | |
# This script counts the number and kinds of files in a project. Any additional | |
# parameters are treated as exclude folder regexes | |
# | |
# Requirements: |
#! /usr/bin/ruby | |
# post.rb | |
# Hilton Lipschitz (http://www.hiltmon.com) @hiltmon | |
# Use and modify freely, attribution appreciated | |
# | |
# Create a new Octopress post, isolate it, generate the | |
# site and leave me with a preview thread running. | |
# | |
# MUST BE RUN in the Octopress root folder |
=begin | |
Plugin: GoogleAnalyticsLogger | |
Description: Daily Web Site Stats Logger | |
Author: [Hilton Lipschitz](http://www.hiltmon.com) | |
Configuration: | |
client_id: 'XXXXXXXXXXXXXX.apps.googleusercontent.com' | |
client_secret: 'XXXXXXXXXXXXXXXX' | |
auth_code: '4/XXXXXXXXXXXXXXXXXXXXXXXXXXX' | |
properties: [ 'UA-XXXXXXXX-1', 'UA-XXXXXXX-2' ] | |
show_sources: true |
# Line 172 : WAS | |
eval(plugin['class']).new.do_log | |
# CHANGE TO | |
if plugin['updates_config'] == true | |
# Pass a reference to config for mutation | |
eval(plugin['class']).new.do_log(@config) | |
else |
=begin | |
Plugin: YahooFinanceLogger | |
Description: Logs a portfolio of prices from Yahoo finance | |
Author: [Hilton Lipschitz](http://www.hiltmon.com) | |
Configuration: | |
- tickers: an array of valid Yahoo tickers to log | |
- show_details: If true, adds day and 52 week high and low, volume, P/E and Market Cap | |
Notes: | |
- Does not run on weekends as the markets are closed (but does run on holidays) | |
- Runs in real time, so if run during the day, will get as at the run time values |
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>author</key> | |
<string>Hilton Lipschitz</string> | |
<key>name</key> | |
<string>CombinedCasts</string> | |
<key>semanticClass</key> | |
<string>theme.combinedcasts</string> |
#!/usr/bin/env ruby -wKU | |
# gist | |
# Hilton Lipschitz (http://www.hiltmon.com) | |
# Use and modify freely, attribution appreciated | |
# | |
# This script allows you to get, list, create, and update Github gists | |
# from the command line. There are others like this but this one caches | |
# file names to gist mappings so you do not need to remember them. The | |
# cache is just a YAML file in ~/.gists. This script also leaves |