I want to validate usernames according to this schema:
- Allowable characters: letters, numbers, hyphen, underscore
- First character must be a letter or a number
- The username cannot be all numbers
This regular expression satisfies 1 and 2 above, but I can't figure out how to satisfy 3:
/^[a-zA-Z\d][\w\-]+$/
(I'm using Ruby, if that's relevant)