feat(all): 多数据源场景,默认拆分api-lock.json到每个数据源目录下#263
Merged
wilsoncook merged 1 commit intomasterfrom Jan 13, 2022
Merged
Conversation
|
|
wilsoncook
requested changes
Jan 4, 2022
| lockFile = path.join(this.currConfig.outDir, 'api.lock'); | ||
| } | ||
|
|
||
| async readLockFile(): Promise<Array<StandardDataSource>> { |
Collaborator
There was a problem hiding this comment.
readLockFile既返回Promise,又返回原始非Promise,类型要明确下
Collaborator
Author
There was a problem hiding this comment.
这里返回值就是Promise,会resolve一个StandardDataSource类型的数组
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What kind of change does this PR introduce(这个 PR 引入了什么样的变化)?
Does this PR introduce a breaking change(这次 PR 引入了一个重大变化吗)?
If yes, please describe the impact and migration path for existing applications(如果是,请描述现有应用程序的影响和迁移路径):
多数据源的场景,打开vscode检测api-lock.json之后会将其备份为api-lock.json.bak,然后在数据源子目录下重新生成独立的api-lock.json
The PR fulfills these requirements(PR 符合以下要求)
Other information(其他信息)
1、有一个破坏性变更,用户如果覆盖了
pontTemplate.ts文件中的以下函数,需要适应性调整:getOriginFileStructures、getMultipleOriginsFileStructures、getLockContent
2、不再兼容api.lock(实际上部分代码也没有做兼容),全部以api-lock.json这个文件为准