-
Notifications
You must be signed in to change notification settings - Fork 17
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 our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added tour response for Upgrade and Validate actions, Closes #188 #323
base: main
Are you sure you want to change the base?
Added tour response for Upgrade and Validate actions, Closes #188 #323
Conversation
Awesome. Thank you for another awesome contribution. I will review it ASAP |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nicodecleyre Awesome work so far ππππ
I tested it and works really good. During my tests and review I noticed some small details we could sort out before we merge π
Please do give them a double check π
savePath = join(savePath, 'src'); | ||
} | ||
|
||
const filePath = join(savePath || '', 'spfx.upgrade.md'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should pass the markdown file name as param. Currently, we will get the same file name for both upgrade and validate action and it will be spfx.upgrade.md
|
||
if (projectValidateOutputMode === 'markdown') { | ||
resultMd = await CliExecuter.execute('spfx project doctor', 'md'); | ||
CliActions.handleMarkdownResult(resultMd,wsFolder); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
CliActions.handleMarkdownResult(resultMd,wsFolder); | |
CliActions.handleMarkdownResult(resultMd, wsFolder); |
|
||
if (projectUpgradeOutputMode === 'markdown') { | ||
resultMd = await CliExecuter.execute('spfx project upgrade', 'md'); | ||
CliActions.handleMarkdownResult(resultMd,wsFolder); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
CliActions.handleMarkdownResult(resultMd,wsFolder); | |
CliActions.handleMarkdownResult(resultMd, wsFolder); |
@@ -15,6 +15,8 @@ import { PnPWebview } from '../../webview/PnPWebview'; | |||
import { parseYoRc } from '../../utils/parseYoRc'; | |||
import { CertificateActions } from './CertificateActions'; | |||
import path = require('path'); | |||
import * as fs from 'fs'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this import actually needed?
CliActions.handleMarkdownResult(resultMd,wsFolder); | ||
} else if (projectValidateOutputMode === 'code tour') { | ||
await CliExecuter.execute('spfx project doctor', 'tour'); | ||
commands.executeCommand('codetour.startTour'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the problem with this approach is that it will run code tour even if nothing was found. in this case we see a picker to run tour but there is non to run. this may be very confusing and I suggest we should run the code tour command only when something was created, so the CLI command did return something
The same applies to the Upgrade report
@nicodecleyre I also did some merging to the dev branch. May I kindly ask you to rebase against latest dev |
π― Aim
Adding the tour options and both md & tour options as settings for the upgrade and validate actions
π· Result
β What was done
Md
,Tour
,Both
as upgrade options in the settingsMd
,Tour
,Both
as validate options in the settingsπ Related issue
Closes: #188