The following debugging information was generated by Atom Beautify
on Tue Jan 10 2017 14:01:52 GMT+1300 (NZDT)
.
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
module.exports = { | |
config: { | |
// default font size in pixels for all tabs | |
fontSize: 12, | |
// font family with optional fallbacks | |
fontFamily: 'Menlo, "DejaVu Sans Mono", "Lucida Console", monospace', | |
// terminal cursor background color and opacity (hex, rgb, hsl, hsv, hwb or cmyk) | |
cursorColor: 'rgba(248,28,229,0.8)', |
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
/** | |
* Looks for an existing transcript and reads it into an array if found. | |
* If the file doesn't exist it creates a new transcript. | |
* | |
* @param file File to read from | |
* @throws IOException | |
*/ | |
public void readFile(File file) throws IOException { | |
Charset charset = Charset.forName("utf-8"); | |
Arraylist<String> someList = new Arraylist<String>(); |
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
{ | |
"id": "2", | |
"name": "Dogs", | |
"prompt": "Which type of dog is the best?", | |
"answers": [ | |
{ | |
"id": "1", | |
"answer_text": "Golden Retriever", | |
"num_votes": 1 | |
}, |
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
if @member.years[0] | |
year_numbers = @member.years.map { |year| | |
year.description.to_i | |
}.sort | |
first_year = year_numbers.shift | |
year_numbers.reduce([[first_year]]) do |year_collection, year| | |
if year_collection[-1][1] == year-1 || !year_collection[-1][1] | |
(year_collection[-1][1] = year; year_collection) | |
else | |
(year_collection)+[[year]] |
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
void ((*volatile p)()); p = (void ((*)())) |
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
# Obviously change the namelist to whoever is in the secret santa draw. | |
santalist = "Helena, Jason, Jess, Kah, Matai, James, Kavi, Caitlin, Ben, Shan, Launa, Nic".split(", ").shuffle | |
santalist.each_cons(2) do |pairing| | |
puts "#{pairing[0]} -> #{pairing[1]}" | |
end | |
puts "#{santalist[-1]} -> #{santalist[0]}" |
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 needs_washup?(mech, invoice_rel) | |
# Gets some info from the page at billing.flickelectric.co.nz/#{invoice_rel}, | |
# checks if the accuracy_status of the invoice is actual, and if the total due | |
# equals 0. If accuracy_status is actual and total due != 0, return true, else false | |
page = mech.get("https://uat-billing.flickelectric.co.nz/" + invoice_rel) | |
accuracy_status = page.search('dl[id="invoice_details"]').to_s.include?("actual") | |
invoice_lines = page.search('tfoot[class~="invoice-totals"]').children | |
# Strip out all of the whitespace | |
totals = invoice_lines.text.gsub(/\s+/, "") | |
# Iterate backwards through until we get a $ character - this index will be |
NewerOlder