Skip to content

Instantly share code, notes, and snippets.

View scottoffen's full-sized avatar
💭
Live in SLC

Scott Offen scottoffen

💭
Live in SLC
View GitHub Profile

My pi runs a raspbian distro (2013-09-25-wheezy-raspbian.zip)

Java

What the raspberry page officially recommends is the jdk. (Source: http://www.raspberrypi.org/archives/4920).

sudo apt-get update && sudo apt-get install oracle-java7-jdk

However, this doesn't include a server on the pi. The jre needs to be installed instead.

@scottoffen
scottoffen / timezones-snippet.html
Last active August 29, 2015 13:57
HTML Select Timezone or MySQL
<!--
mysql query to generate option list
SELECT CONCAT('<option value="', `Name`, '">', `Name`, '</option>') FROM mysql.time_zone_name;
if mysql.time_zone_name has no records go here: http://dev.mysql.com/downloads/timezones.html
to convert date/time between timezones do something like this:
SELECT startdate, CONVERT_TZ(startdate, 'utc', (SELECT timezone FROM accounts WHERE id=1)) FROM auctions;
This query takes two values, one on daylight savings and one off daylight savings, and converts them to a daylight savings impacted time zone: