Skip to content

Instantly share code, notes, and snippets.

@unabridgedxcrpt
Created December 11, 2015 15:49
Show Gist options
  • Save unabridgedxcrpt/01467030fb673fd17631 to your computer and use it in GitHub Desktop.
Save unabridgedxcrpt/01467030fb673fd17631 to your computer and use it in GitHub Desktop.
remove leading zero. I used this for a bash script to remove the leading 0 from a month number
nozero=$(echo $number | sed 's/^0*//')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment