Skip to content
This repository was archived by the owner on Sep 1, 2022. It is now read-only.

Commit 4a98e77

Browse files
committed
add validation to metadata
1 parent 2184aa3 commit 4a98e77

2 files changed

Lines changed: 11 additions & 0 deletions

File tree

config.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -417,6 +417,16 @@ steps:
417417
description: Add some descriptions to your course
418418
event: pull_request.synchronize
419419
actions:
420+
- type: getFileContents
421+
action_id: fileContents
422+
filename: 'config.yml'
423+
- type: gate
424+
left: '/^tagline:(?![ \t]*#).*$\ndescription:(?![ \t]*#).*$/gm'
425+
operator: test
426+
right: '%actions.fileContents%'
427+
else:
428+
- type: respond
429+
with: e-no-meta.md
420430
- type: respond
421431
with: add-readme.md
422432

responses/e-no-meta.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
I didn't find metadata. Add it.

0 commit comments

Comments
 (0)