Skip to content

Commit 6bd6f98

Browse files
committed
update repo name validator for snake cased dashes
1 parent 400708d commit 6bd6f98

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

‎lib/components/Config/validate.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ var validate = function (values) {
1111
errors.name = 'Invalid "coderoad-*" name';
1212
}
1313
if (values.repo) {
14-
if (!values.repo.match(/^https?:\/\/[a-zA-Z\.\/]+$/)) {
14+
if (!values.repo.match(/^https?:\/\/[a-zA-Z\-\.\/]+$/)) {
1515
errors.repo = 'Invalid http(s)://github.com/user/repo';
1616
}
1717
}

‎src/components/Config/validate.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ const validate = values => {
2121
errors.name = 'Invalid "coderoad-*" name';
2222
}
2323
if (values.repo) {
24-
if (!values.repo.match(/^https?:\/\/[a-zA-Z\.\/]+$/)) {
24+
if (!values.repo.match(/^https?:\/\/[a-zA-Z\-\.\/]+$/)) {
2525
errors.repo = 'Invalid http(s)://github.com/user/repo';
2626
}
2727
}

0 commit comments

Comments
 (0)