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
CREATE OR REPLACE FUNCTION excel_time(in timestamp, out double precision) | |
AS $$ | |
SELECT (EXTRACT(epoch FROM $1)/86400) + 25569 | |
$$ | |
LANGUAGE SQL IMMUTABLE PARALLEL SAFE; | |
CREATE OR REPLACE FUNCTION excel_time(in timestamptz, out double precision) | |
AS $$ |
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
function rmb { | |
current_branch=$(git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/\1/') | |
if [ "$current_branch" != "master" ]; then | |
echo "WARNING: You are on branch $current_branch, NOT master." | |
fi | |
echo "Fetching merged branches..." | |
git remote prune origin | |
remote_branches=$(git branch -r --merged | grep -v '/master$' | grep -v "/$current_branch$") | |
local_branches=$(git branch --merged | grep -v 'master$' | grep -v "$current_branch$") | |
if [ -z "$remote_branches" ] && [ -z "$local_branches" ]; then |
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/bin/python | |
import sys | |
import argparse | |
import os | |
import re | |
''' | |
A simple script to create lower-resolution Android drawables from higher-resolution ones. |
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
require 'csv' | |
require 'json' | |
require "set" | |
json = JSON.parse(File.open(ARGV[0]).read)["results"] | |
# Pass 1: Collect headings | |
headings = SortedSet.new | |
json.each do |hash| | |
headings.merge(hash.keys) | |
end |
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
smartctl 5.40 2010-10-16 r3189 [i686-pc-linux-gnu] (local build) | |
Copyright (C) 2002-10 by Bruce Allen, http://smartmontools.sourceforge.net | |
=== START OF INFORMATION SECTION === | |
Model Family: Western Digital Caviar Green family | |
Device Model: WDC WD15EADS-00P8B0 | |
Serial Number: WD-WCAVU0228059 | |
Firmware Version: 01.00A01 | |
User Capacity: 1,500,301,910,016 bytes | |
Device is: In smartctl database [for details use: -P show] |
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
Dear all | |
I am writing to alert you to changes in the BE(Hons) to be implemented from 2012, which will see all current 4XX-level courses re-coded to become 7XX-level courses (with the exception of ENGGEN 403). | |
The reason for the change in number code is due to an anomaly which has seen these 400-level courses placed at Level 7 on the NZQA’s National Qualifications Framework. | |
The above conflicts with the NZVCC’s Committee on University Academic Programmes (CUAP) requirement for all Masters degree programmes to comprise Level 8 courses only and the requirement for Bachelors (Honours) degree programmes to include a minimum of 105 points at Level 8. | |
This has potential ramifications for those students needing to have their qualification officially benchmarked and verified for overseas study or work purposes. It also meant that, on paper, the BE(Hons) could be deemed to be of a lower intellectual standard than all of the University’s other Honours degrees – something which is clearly not the case. | |