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

Prepare release, fix build typings#80

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
ShMcK merged 2 commits intomasterfromupdate-deps
Apr 3, 2021
Merged
Show file tree
Hide file tree
Changes from1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
NextNext commit
fix tsc updated typings
Signed-off-by: shmck <shawn.j.mckay@gmail.com>
  • Loading branch information
@ShMcK
ShMcK committedApr 3, 2021
commit2f4e5cd371a24fdcd30be4ed1656108e847de804
2 changes: 1 addition & 1 deletionsrc/build.ts
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -91,7 +91,7 @@ async function build (args: string[]) {
// parse yaml skeleton config
let skeleton
try {
skeleton = yamlParser.load(_yaml)
skeleton = yamlParser.load(_yaml) as T.TutorialSkeleton
if (!skeleton || !Object.keys(skeleton).length) {
throw new Error(`Skeleton at "${options.yaml}" is invalid`)
}
Expand Down
6 changes: 4 additions & 2 deletionssrc/validate.ts
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -9,6 +9,7 @@ import {
createTestRunner
} from './utils/exec'
import { getCommits, CommitLogObject } from './utils/commits'
import { TutorialSkeleton } from '../typings/tutorial'

interface Options {
yaml: string
Expand All@@ -34,14 +35,15 @@ async function validate (args: string[]) {
// parse yaml config
let skeleton
try {
skeleton = yamlParser.load(_yaml)
skeleton = yamlParser.load(_yaml) as TutorialSkeleton

if (!skeleton) {
throw new Error('Invalid yaml file contents')
}
} catch (e) {
console.error('Error parsing yaml')
console.error(e.message)
return
}

const codeBranch: string = skeleton.config.repo.branch
Expand DownExpand Up@@ -106,7 +108,7 @@ async function validate (args: string[]) {
await cherryPick(stepSetupCommits)
}
// run commands
if (step.setup.commands) {
if (step?.setup?.commands) {
console.info(`--- Running setup commands...`)
await runCommands(step.setup.commands)
}
Expand Down
5 changes: 5 additions & 0 deletionstypings/tutorial.d.ts
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -86,3 +86,8 @@ export interface TutorialDependency {
export interface TutorialAppVersions {
vscode: string
}

export interface TutorialSkeleton {
config: TutorialConfig
levels: Level[]
}

[8]ページ先頭

©2009-2025 Movatter.jp