@react-native-windows/cli
Advanced tools
Comparing version 0.0.0-canary.61 to 0.0.0-canary.62
@@ -5,3 +5,18 @@ { | ||
{ | ||
"date": "Thu, 18 Feb 2021 05:06:26 GMT", | ||
"date": "Sat, 20 Feb 2021 05:05:37 GMT", | ||
"tag": "@react-native-windows/cli_v0.0.0-canary.62", | ||
"version": "0.0.0-canary.62", | ||
"comments": { | ||
"prerelease": [ | ||
{ | ||
"comment": "Fix projectName issue with C# projects and deploy tool version check", | ||
"author": "asklar@microsoft.com", | ||
"commit": "27f894c831735c6a41497b7dbd28527672599e6c", | ||
"package": "@react-native-windows/cli" | ||
} | ||
] | ||
} | ||
}, | ||
{ | ||
"date": "Thu, 18 Feb 2021 05:07:11 GMT", | ||
"tag": "@react-native-windows/cli_v0.0.0-canary.61", | ||
@@ -8,0 +23,0 @@ "version": "0.0.0-canary.61", |
# Change Log - @react-native-windows/cli | ||
This log was last generated on Thu, 18 Feb 2021 05:06:26 GMT and should not be manually modified. | ||
This log was last generated on Sat, 20 Feb 2021 05:05:37 GMT and should not be manually modified. | ||
<!-- Start content --> | ||
## 0.0.0-canary.62 | ||
Sat, 20 Feb 2021 05:05:37 GMT | ||
### Changes | ||
- Fix projectName issue with C# projects and deploy tool version check (asklar@microsoft.com) | ||
## 0.0.0-canary.61 | ||
Thu, 18 Feb 2021 05:06:26 GMT | ||
Thu, 18 Feb 2021 05:07:11 GMT | ||
@@ -11,0 +19,0 @@ ### Changes |
@@ -82,3 +82,3 @@ /** | ||
*/ | ||
export declare function getProjectName(projectContents: Node): string; | ||
export declare function getProjectName(projectPath: string, projectContents: Node): string; | ||
/** | ||
@@ -85,0 +85,0 @@ * Gets the namespace of the project from the project contents. |
@@ -31,3 +31,2 @@ "use strict"; | ||
'**/Release/**', | ||
'**/WinUI3/**', | ||
'**/Generated Files/**', | ||
@@ -238,5 +237,5 @@ '**/packages/**', | ||
*/ | ||
function getProjectName(projectContents) { | ||
function getProjectName(projectPath, projectContents) { | ||
const name = tryFindPropertyValue(projectContents, 'ProjectName') || | ||
tryFindPropertyValue(projectContents, 'AssemblyName') || | ||
path.parse(projectPath).name || | ||
''; | ||
@@ -243,0 +242,0 @@ return name; |
@@ -118,3 +118,3 @@ "use strict"; | ||
// Calculating (auto) items | ||
project.projectName = configUtils.getProjectName(projectContents); | ||
project.projectName = configUtils.getProjectName(projectFile, projectContents); | ||
project.projectLang = configUtils.getProjectLanguage(projectFile); | ||
@@ -147,3 +147,3 @@ project.projectGuid = configUtils.getProjectGuid(projectContents); | ||
const projectContents = configUtils.readProjectFile(projectFile); | ||
const projectName = configUtils.getProjectName(projectContents); | ||
const projectName = configUtils.getProjectName(projectFile, projectContents); | ||
const projectGuid = configUtils.getProjectGuid(projectContents); | ||
@@ -150,0 +150,0 @@ const projectNamespace = configUtils.getProjectNamespace(projectContents); |
@@ -121,3 +121,3 @@ "use strict"; | ||
// Add missing (auto) items | ||
result.project.projectName = configUtils.getProjectName(projectContents); | ||
result.project.projectName = configUtils.getProjectName(projectFile, projectContents); | ||
result.project.projectLang = configUtils.getProjectLanguage(projectFile); | ||
@@ -124,0 +124,0 @@ result.project.projectGuid = configUtils.getProjectGuid(projectContents); |
@@ -175,17 +175,30 @@ "use strict"; | ||
// Get the solution file | ||
const slnFile = build.getAppSolutionFile(options, config); | ||
if (options.autolink) { | ||
const autolinkArgs = []; | ||
const autolinkConfig = config; | ||
const autoLinkOptions = { | ||
logging: options.logging, | ||
proj: options.proj, | ||
sln: options.sln, | ||
}; | ||
runWindowsPhase = 'AutoLink'; | ||
await autolink_1.autoLinkCommand.func(autolinkArgs, autolinkConfig, autoLinkOptions); | ||
let slnFile; | ||
try { | ||
slnFile = build.getAppSolutionFile(options, config); | ||
} | ||
else { | ||
commandWithProgress_1.newInfo('Autolink step is skipped'); | ||
catch (e) { | ||
commandWithProgress_1.newError(`Couldn't get app solution information. ${e.message}`); | ||
throw e; | ||
} | ||
try { | ||
if (options.autolink) { | ||
const autolinkArgs = []; | ||
const autolinkConfig = config; | ||
const autoLinkOptions = { | ||
logging: options.logging, | ||
proj: options.proj, | ||
sln: options.sln, | ||
}; | ||
runWindowsPhase = 'AutoLink'; | ||
await autolink_1.autoLinkCommand.func(autolinkArgs, autolinkConfig, autoLinkOptions); | ||
} | ||
else { | ||
commandWithProgress_1.newInfo('Autolink step is skipped'); | ||
} | ||
} | ||
catch (e) { | ||
commandWithProgress_1.newError(`Autolinking failed. ${e.message}`); | ||
throw e; | ||
} | ||
let buildTools; | ||
@@ -192,0 +205,0 @@ runWindowsPhase = 'FindBuildTools'; |
@@ -107,3 +107,3 @@ "use strict"; | ||
projectFile: path.relative(path.join(this.windowsAppConfig.folder, this.windowsAppConfig.sourceDir), projFile), | ||
projectName: configUtils.getProjectName(projectContents), | ||
projectName: configUtils.getProjectName(projFile, projectContents), | ||
projectLang: configUtils.getProjectLanguage(projFile), | ||
@@ -110,0 +110,0 @@ projectGuid: configUtils.getProjectGuid(projectContents), |
@@ -162,3 +162,3 @@ "use strict"; | ||
? windowsConfig.project.projectName | ||
: options.proj; | ||
: path.parse(options.proj).name; | ||
const windowsStoreAppUtils = getWindowsStoreAppUtils(options); | ||
@@ -187,7 +187,7 @@ const appxManifestPath = getAppxManifestPath(options, projectName); | ||
else { | ||
// If we have DeployAppRecipe.exe, use it (start in 16.9 Preview 2, don't use 16.8 even if it's there as that version has bugs) | ||
// If we have DeployAppRecipe.exe, use it (start in 16.8.4, earlier 16.8 versions have bugs) | ||
const appxRecipe = path.join(path.dirname(appxManifestPath), `${projectName}.build.appxrecipe`); | ||
const ideFolder = `${buildTools.installationPath}\\Common7\\IDE`; | ||
const deployAppxRecipeExePath = `${ideFolder}\\DeployAppRecipe.exe`; | ||
if (vsVersion.gte(version_1.default.fromString('16.9.30801.93')) && | ||
if (vsVersion.gte(version_1.default.fromString('16.8.30906.45')) && | ||
fs.existsSync(deployAppxRecipeExePath)) { | ||
@@ -194,0 +194,0 @@ await commandWithProgress_1.commandWithProgress(commandWithProgress_1.newSpinner('Deploying'), `Deploying ${appxRecipe}`, deployAppxRecipeExePath, [appxRecipe], verbose, 'DeployRecipeFailure'); |
{ | ||
"name": "@react-native-windows/cli", | ||
"version": "0.0.0-canary.61", | ||
"version": "0.0.0-canary.62", | ||
"license": "MIT", | ||
@@ -5,0 +5,0 @@ "main": "lib-commonjs/index.js", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
417511
5778