Skip to content

Instantly share code, notes, and snippets.

View Jakuje's full-sized avatar
🦌
oh deer!

Jakub Jelen Jakuje

🦌
oh deer!
View GitHub Profile
isOldGeocachingDomain = isGeocachingDomain
function isGeocachingDomain(url) {
if (isOldGeocachingDomain(url)
|| url == "project-gc.com"
|| url == "www.project-gc.com") {
return true;
}
@Jakuje
Jakuje / stylish.geocaching.css
Created June 23, 2016 06:46
geocaching.com/pocket move button
@namespace url(http://www.w3.org/1999/xhtml);
@-moz-document domain("www.geocaching.com") {
#ctl00_ContentBody_btnSubmit {
position:absolute;
top:10px;
left:10px
}
}
@Jakuje
Jakuje / update_gpx.sh
Created May 20, 2015 20:50
Using xsl transfrom gpx to txt file used by Navit on my webOS phone
#!/bin/bash
#FILENAME="9897043"
FILENAME=$1
#wget -O ${FILENAME}.gpx "http://www.geocaching.com/pocket/downloadpq.ashx?g=fba142aa-e661-4533-ad6d-3220b900241c&src=web"
[ -f "${FILENAME}.zip" ] && unzip "${FILENAME}.zip"
xsltproc ~/.local/bin/gpx2navit.xsl ${FILENAME}{,-wpts}.gpx > ${FILENAME}_nav.txt
cat ${FILENAME}_nav.txt | novaterm put file:///media/internal/appdata/org.webosinternals.navit/maps/cache.txt
@Jakuje
Jakuje / gpx2navit.xsl
Last active August 29, 2015 14:17
Simple transformation for GPX files into files readable by Navit mobile navigation (with specialization for Geocaching)
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:g="http://www.topografix.com/GPX/1/0">
<xsl:output method="text"/>
<xsl:template match="g:gpx">
<xsl:for-each select="g:wpt">
<xsl:choose>
<xsl:when test="g:type = 'Waypoint|Parking Area'">
<xsl:text>type=poi_car_parking label="</xsl:text>
</xsl:when>
<xsl:when test="starts-with(g:type, 'Geocache')">
<xsl:text>type=poi_attraction label="</xsl:text>