View how_to_convert_dos_2_unix
1 2 3 4 5 6 7 8 9
student=1
topic=DownloadBoundServiceAsync
gdsrc=~/projects/coursera/posa-002/POSA-14-20140706/grading-drivers/week-8-assignment-7/W8-A7-ThreadedDownloads-BoundServices/src/edu/vuum/mocca/$topic.java
peer_assesment=./peer-assessments/week8/s$student/$topic.java
tmp_peer_assesment=./tmp/$topic.java
 
awk '{ sub(/\r$/,""); print }' < $peer_assesment > $tmp_peer_assesment
 
opendiff $gdsrc $tmp_peer_assesment
View gist:9876953
1 2 3 4 5 6 7 8 9 10
> cat workfile.csv | ruby -rcsv -ne '
row = CSV.parse_line($_)
puts CSV.generate_line(row, {col_sep: ";" })
' > work1.csv
 
 
> cat workfile.csv | ruby -rcsv -ne '
row = CSV.parse_line($_)
row.each {|elem| elem.tr!(",.",".,") if elem.match(/^-?[0-9,.]+$/)}
puts CSV.generate_line(row, {col_sep: ";" })
View gist:9870604
1 2 3 4 5 6
> ls -t ~/Downloads | head -1
LISTA_MOVIMENTI_20140330101644484.csv
 
> cp `ls -t ~/Downloads | head -1` workfile.csv
 
 
View gist:9058989
1
adb forward tcp:9222 localabstract:chrome_devtools_remote
View gist:6628904
1 2 3 4 5 6 7 8 9 10
/*
* Test code for the issue exposed in:
* http://stackoverflow.com/questions/18780151/not-able-to-view-combobox-in-excel-using-jxl-api
* -jar jxl.jar
* [jxl 2.6.12 2009-10-26](http://jexcelapi.sourceforge.net/)
* javac 1.7.0_25
*/
package org.rondakit.jxl.tester;
 
import java.io.File;
View gist:5486638
View gist:5481142
1 2
rvm use --create jruby-1.6.7@jruby_sinatra
export JRUBY_OPTS=--1.9
View Gemfile
1 2 3 4 5
source :rubygems
 
 
gem 'sinatra'
gem 'warbler'
View config.ru
1 2 3
root = File.dirname(__FILE__) # => "."
require File.join( root, 'sample_app' ) # => true
run Sample # ..in sample_app.rb ..class Sample < Sinatra::Base
View sample_app.rb
1 2 3 4 5 6 7 8 9 10
 
# singleton-as-module loaded once, kept in memory
module App
module Global extend self
def calc
@calc ||= StatefulCalculator.new
end
end
end
Something went wrong with that request. Please try again.