Skip to content

Instantly share code, notes, and snippets.

# Give it a gpx filename as the argument.
# This assumes the track name is in the <name> element. This is how it came from Strava. YMMV.
# Some of theses headers certainly aren't needed. Experiment carefully. Read the comments inline.
# Most important will be your API key which is in the binary form data. Search for 'name="key"'
# below. You may have to inspect an API call to get your key.
filename="$1"
filecontents=`cat $1`
name=`cat $1 | grep '<name>' | sed -e 's/.*<name>//g' | sed -e 's/<\/name>//g'`
#!/bin/bash
OIFS=$IFS
IFS=$(echo -en "\n\b")
for f in *
do
echo "$f"
done
IFS=$OIFS
@devguydavid
devguydavid / philips-db.zsh-theme
Last active December 12, 2023 16:04
Modified philips zsh theme I like
if [ $UID -eq 0 ]; then NCOLOR="red"; else NCOLOR="green"; fi
if [ "$AWSUME_PROFILE" = "canary-production-admin" ]; then PCOLOR="red"; else PCOLOR="green"; fi
## Prompt stuff
# Autoload zsh's `add-zsh-hook` and `vcs_info` functions
# (-U autoload w/o substition, -z use zsh style)
autoload -Uz add-zsh-hook vcs_info
# Set prompt substitution so we can use the vcs_info_message variable