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
| #!/usr/bin/env ruby -wKU | |
| puts "Begin Splitting - #{Time.now}" | |
| header_line = "medical_record_number;encounter_number;encounter_start_date;patient_name;patient_birth_date;ip_op_indicator;encounter_type;doc_id;document_date;documnet_create_date;document_modify_date;doc_type_name;doc_type_description;page_number;signed;signatures;annotation_files;text_notes;file_path" | |
| input = File.new('index.idx', 'r') | |
| line_number = 0 | |
| line_limit = 930 | |
| file_count = 1 | |
| threshold = line_limit |
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
| #!/usr/bin/env ruby | |
| # http://github.com/mojombo/jekyll/tree/master | |
| require 'rubygems' | |
| require 'sqlite3' | |
| db = SQLite3::Database.new( "blog.db3" ) | |
| db.results_as_hash = true | |
| db.execute( "select * from articles" ) do |row| | |
| file_name = row['created_at'].split(" ")[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
| h1. ${1:Meeting Title} - `date` | |
| "PSR $2":$3 | |
| ${4:Meeting Description} | |
| h2. Attendees: | |
| h3. Siemens | |
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
| #!/usr/bin/env ruby -wKU | |
| src_file = File.new 'soar_7-1-1.xml', 'r' | |
| cln_file = File.new 'soar-cleaned_7-1-1.xml', 'w' | |
| cleaned_data = '' | |
| src_file.each_line do |line| | |
| cleaned_data += line.gsub(/[^\20-\x7E\s]/, ' ') | |
| end | |
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
| #!/usr/bin/env ruby -wKU | |
| require 'date' | |
| spring_training = Date.new 2009, 2, 14 | |
| current_date = DateTime.now | |
| difference = spring_training - current_date | |
| puts "#{difference.to_i} days until pitchers and catchers report for the " << |
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
| #!/usr/bin/env ruby -wKU | |
| error_file = File.new '2003_errors.txt', 'w' | |
| Dir.foreach(".") do |x| | |
| error_file << File.new( x, 'r' ).read if x[x.length-3, 3] == 'txt' | |
| end | |
| error_file.close |
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
| *.log | |
| Manifest | |
| pkg/* |
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
| Shoes.app(:height=>100) do | |
| background "#EFC" | |
| border "#BE8", :strokewidth => 6 | |
| stack(:margin => 12) do | |
| para "Enter your name" | |
| flow do | |
| name = edit_line | |
| button "OK" do | |
| alert "Hi #{name.text}, this was a collosal waste of your time!" | |
| end |
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
| #!/usr/bin/env ruby | |
| # Creates a weekly gtd report from your backpack account | |
| # Based on the sample wrapper script from | |
| # David Heinemeier Hansson, 37signals and | |
| # Gmail sample script from shunsuk | |
| # Requires that XmlSimple, RedCloth, tlsmail, and time | |
| # are installed. | |
| # Assumptions: | |
| # ** All personal/home pages start with a space ' ' | |
| # ** All closed projects start with zzc |
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
| SELECT problems.id, problems.title, problems.start_date, | |
| problems.uid, problems.uemail, tblUsers.uid, customers.custname | |
| FROM ( | |
| customers INNER JOIN | |
| ( | |
| problems INNER JOIN status ON | |
| problems.status = status.status_id | |
| ) ON | |
| customers.customer_id = problems.customer | |
| ) |