manifoldco / torus-cli

A secure, shared workspace for secrets
https://www.torus.sh
BSD 3-Clause "New" or "Revised" License
613 stars 32 forks source link

Capital letters not allowed in project names #381

Open mattroseman opened 6 years ago

mattroseman commented 6 years ago

Replicate

  1. run ./torus link in a new folder and create a new project
  2. On the ✗ Create a new project: prompt type something with capital letters (like TorusTestProject)
  3. Get this error message
    Project names must be between 1 and 64 characters in length and only contain alphabetical letters, numbers, hyphens, and underscores.

    The error message says nothing of letters needing to be lowercase, but that seems to be the case.

In the validation code validate/validate.go:11 It only allows lowercase, but the error message doesn't specify as such.

The error message also doesn't specify that the project name must start with a letter.

If I can make a suggestion, I would reword it to something like

Project names must be between 1 and 64 characters in length; only contain lowercase
letters, numbers, hyphens, and underscores; and begin with a lowercase letter.