feat(projects): normalization name.

This commit is contained in:
Ivan Li
2021-05-04 21:05:20 +08:00
parent 246c0bd8f8
commit 86c8bce9ea
10 changed files with 15310 additions and 48 deletions

View File

@ -21,7 +21,10 @@ export class CreateProjectInput {
comment: string;
@Matches(
/^(?:ssh:\/\/)?(?:[\w\d-_]+@)(?:[\w\d-_]+\.)*\w{2,10}(?::\d{1,5})?(?:\/[\w\d-_.]+)*/,
/^(?:ssh:\/\/)?(?:[\w\d-_]+@)?(?:[\w\d-_]+\.)*\w{2,10}(?::\d{1,5})?(?:\/[\w\d-_.]+)*/,
{
message: 'wrong ssh url',
},
)
@MaxLength(256)
sshUrl: string;