Challenge slug can start with a digit

This commit is contained in:
Filip Gralinski 2021-05-12 07:03:38 +02:00
parent cc5594d84a
commit dababb05ed
3 changed files with 4 additions and 4 deletions

View File

@ -73,7 +73,7 @@ postCreateChallengeR = do
then
runViewProgress $ doCreateChallenge challengeData
else
runViewProgress $ (flip err) "unexpected challenge ID (use only lower-case letters, digits and hyphens, start with a letter)"
runViewProgress $ (flip err) "unexpected challenge ID (use only lower-case letters, digits and hyphens, start with a letter or a digit)"
else
runViewProgress $ (flip err) "MUST BE AN ADMIN TO CREATE A CHALLENGE"

View File

@ -642,7 +642,7 @@ findFilePossiblyCompressed baseFilePath = do
(h:_) -> Just h
localIdRegexp :: Regex
localIdRegexp = makeRegexOpts defaultCompOpt{newSyntax=True} defaultExecOpt ("\\`[a-z][-a-z0-9]{0,63}\\'" ::String)
localIdRegexp = makeRegexOpts defaultCompOpt{newSyntax=True} defaultExecOpt ("\\`[a-z0-9][-a-z0-9]{0,63}\\'" ::String)
unwantedLocalIds :: [Text]
unwantedLocalIds = ["git",

View File

@ -19,7 +19,7 @@ AboutMe: about me
AccountName: name
AccountNameTooltip: your human-readable name (to be shown on the leaderboard)
Id: ID
IdTooltip: to be used in the URLs for your repos (only lower-case letters, digits or hyphens, must start with a lower-case letter), once set cannot be changed!
IdTooltip: to be used in the URLs for your repos (only lower-case letters, digits or hyphens, must start with a lower-case letter or a digit), once set cannot be changed!
SshPubKey: your SSH public key
SshPubKeyTooltip: needed if you want to access repos hosted on Gonito.net (usually ".ssh/id_rsa.pub" in your home directory after you generated private/public key pair)
Home: home
@ -65,7 +65,7 @@ RestoreSubmission: restore submission
ParameterName: parameter name
ParameterValue: parameter value
ChallengeName: computer-friendly name ("slug")
ChallengeNameTooltip: to be used in the URLs (only lower-case letters, digits or hyphens, must start with a lower-case letter), once set cannot be changed!
ChallengeNameTooltip: to be used in the URLs (only lower-case letters, digits or hyphens, must start with a lower-case letter or a digit), once set cannot be changed!
FilterCondition: filter condition
FilterConditionTooltip: the condition used to pre-select all submission — an extra graph will be drawed for all submissions matching this condition (not necessarily the target condition)
TargetCondition: target condition