Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit8a2ca9c

Browse files
authored
Merge pull requestcoderoad#58 from coderoad/feature/reset-command
support reset command
2 parents97aabcd +43bd233 commit8a2ca9c

File tree

4 files changed

+36
-3
lines changed

4 files changed

+36
-3
lines changed

‎src/schema/skeleton.ts

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,18 @@ export default {
8080
additionalProperties:false,
8181
required:["uri","branch"],
8282
},
83-
83+
reset:{
84+
type:"object",
85+
description:"Configuration options for resetting a tutorial",
86+
properties:{
87+
command:{
88+
type:"string",
89+
description:"An optional command to run on reset",
90+
examples:["npm install"],
91+
},
92+
},
93+
additionalProperties:false,
94+
},
8495
dependencies:{
8596
type:"array",
8697
description:"A list of tutorial dependencies",

‎src/schema/tutorial.ts

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,18 @@ export default {
9999
additionalProperties:false,
100100
required:["uri","branch"],
101101
},
102-
102+
reset:{
103+
type:"object",
104+
description:"Configuration options for resetting a tutorial",
105+
properties:{
106+
command:{
107+
type:"string",
108+
description:"An optional command to run on reset",
109+
examples:["npm install"],
110+
},
111+
},
112+
additionalProperties:false,
113+
},
103114
dependencies:{
104115
type:"array",
105116
description:"A list of tutorial dependencies",

‎tests/parse.test.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -998,6 +998,9 @@ Description.
998998
uri:"https://path.to/repo",
999999
branch:"aBranch",
10001000
},
1001+
reset:{
1002+
command:"some command",
1003+
},
10011004
dependencies:[
10021005
{
10031006
name:"node",
@@ -1031,6 +1034,9 @@ Description.
10311034
uri:"https://path.to/repo",
10321035
branch:"aBranch",
10331036
},
1037+
reset:{
1038+
command:"some command",
1039+
},
10341040
dependencies:[
10351041
{
10361042
name:"node",

‎typings/tutorial.d.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,15 @@
11
exporttypeMaybe<T>=T|null;
22

3+
exporttypeConfigReset={
4+
command?:string;
5+
};
6+
37
exporttypeTutorialConfig={
4-
appVersions:TutorialAppVersions;
8+
appVersions?:TutorialAppVersions;
59
testRunner:TestRunnerConfig;
610
repo:TutorialRepo;
711
dependencies?:TutorialDependency[];
12+
reset?:ConfigReset;
813
};
914

1015
/** Logical groupings of tasks */

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp