Skip to content
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

Fixing workingDirectory not honored for .NET Core task build #13010

Merged
merged 19 commits into from
Jun 18, 2020
Merged
Show file tree
Hide file tree
Changes from 14 commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"loc.group.displayName.generalAdvanced": "Advanced",
"loc.input.label.command": "Command",
"loc.input.help.command": "The dotnet command to run. Select 'Custom' to add arguments or use a command not listed here.",
"loc.input.label.publishWebProjects": "Publish Web Projects",
"loc.input.label.publishWebProjects": "Publish web projects",
"loc.input.help.publishWebProjects": "If true, the task will try to find the web projects in the repository and run the publish command on them. Web projects are identified by presence of either a web.config file or wwwroot folder in the directory.",
"loc.input.label.projects": "Path to project(s)",
"loc.input.help.projects": "The path to the csproj file(s) to use. You can use wildcards (e.g. **/*.csproj for all .csproj files in all subfolders).",
Expand All @@ -26,7 +26,7 @@
"loc.input.help.publishTestResults": "Enabling this option will generate a test results TRX file in `$(Agent.TempDirectory)` and results will be published to the server. <br>This option appends `--logger trx --results-directory $(Agent.TempDirectory)` to the command line arguments. <br><br>Code coverage can be collected by adding `--collect \"Code coverage\"` option to the command line arguments. This is currently only available on the Windows platform.",
"loc.input.label.testRunTitle": "Test run title",
"loc.input.help.testRunTitle": "Provide a name for the test run.",
"loc.input.label.zipAfterPublish": "Zip Published Projects",
"loc.input.label.zipAfterPublish": "Zip published projects",
"loc.input.help.zipAfterPublish": "If true, folder created by the publish command will be zipped.",
"loc.input.label.modifyOutputPath": "Add project's folder name to publish path",
"loc.input.help.modifyOutputPath": "If true, folders created by the publish command will have project's folder name prefixed to their folder names when output path is specified explicitly in arguments. This is useful if you want to publish multiple projects to the same folder.",
Expand Down Expand Up @@ -81,8 +81,8 @@
"loc.input.help.buildProperties": "Specifies a list of token = value pairs, separated by semicolons, where each occurrence of $token$ in the .nuspec file will be replaced with the given value. Values can be strings in quotation marks.",
"loc.input.label.verbosityPack": "Verbosity",
"loc.input.help.verbosityPack": "Specifies the amount of detail displayed in the output.",
"loc.input.label.workingDirectory": "Working Directory",
"loc.input.help.workingDirectory": "Current working directory where the script is run. Empty is the root of the repo (build) or artifacts (release), which is $(System.DefaultWorkingDirectory)",
"loc.input.label.workingDirectory": "Working directory",
"loc.input.help.workingDirectory": "Current working directory where the script is run. Empty is the root of the repo (build) or artifacts (release), which is $(System.DefaultWorkingDirectory). Supported only for 'custom' command.",
"loc.messages.BuildIdentityPermissionsHint": "For internal feeds, make sure the build service identity '%s' [%s] has access to the feed.",
"loc.messages.CouldNotSetCodePaging": "Could not set the code paging of due to following error: %s",
"loc.messages.Error_AutomaticallyVersionReleases": "Autoversion: Getting version number from build option is not supported in releases",
Expand All @@ -105,7 +105,7 @@
"loc.messages.dotnetCommandFailed": "Dotnet command failed with non-zero exit code on the following projects : %s",
"loc.messages.noProjectFilesFound": "Project file(s) matching the specified pattern were not found.",
"loc.messages.noPublishFolderFoundToZip": "A publish folder could not be found to zip for project file: %s.",
"loc.messages.noWebProjectFound": "No web project was found in the repository. Web projects are identified by presence of either a web.config file, wwwroot folder in the directory, or by the usage of Microsoft.Net.Web.Sdk in your project file. You can set Publish Web Projects property to false (publishWebProjects: false in yml) if your project doesn't follow this convention or if you want to publish projects other than web projects.",
"loc.messages.noWebProjectFound": "No web project was found in the repository. Web projects are identified by presence of either a web.config file, wwwroot folder in the directory, or by the usage of Microsoft.Net.Web.Sdk in your project file. You can set Publish web projects property to false (publishWebProjects: false in yml) if your project doesn't follow this convention or if you want to publish projects other than web projects.",
"loc.messages.zipFailed": "Zip failed with error: %s",
"loc.messages.Error_ApiKeyNotSupported": "DotNetCore currently does not support using an encrypted Api Key.",
"loc.messages.Error_ExpectedConfigurationElement": "Invalid xml. Expected element named 'configuration'.",
Expand Down
9 changes: 5 additions & 4 deletions Tasks/DotNetCoreCLIV2/task.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"version": {
"Major": 2,
"Minor": 169,
"Patch": 2
"Patch": 5
},
"minimumAgentVersion": "2.115.0",
"instanceNameFormat": "dotnet $(command)",
Expand Down Expand Up @@ -104,7 +104,7 @@
"defaultValue": "",
"visibleRule": "command = build || command = restore || command = run || command = test || command = custom || publishWebProjects = false",
"required": false,
"helpMarkDown": "The path to the csproj file(s) to use. You can use wildcards (e.g. **/*.csproj for all .csproj files in all subfolders)."
"helpMarkDown": "The path to the csproj file(s) to use. You can use wildcards (e.g. **/*.csproj for all .csproj files in all subfolders). **This field follows glob pattern, and is run against root of the repository at all times irrespective of Working Directory.**"
},
{
"name": "custom",
Expand Down Expand Up @@ -488,9 +488,10 @@
"name": "workingDirectory",
"type": "filePath",
"label": "Working directory",
"helpMarkDown": "Current working directory where the script is run. Empty is the root of the repo (build) or artifacts (release), which is $(System.DefaultWorkingDirectory)",
"helpMarkDown": "Current working directory where the script is run. Empty is the root of the repo (build) or artifacts (release), which is $(System.DefaultWorkingDirectory). Supported only for 'build' and 'custom' command. In case of 'build', project search pattern is **NOT** relative to working directory.",
issacnitin marked this conversation as resolved.
Show resolved Hide resolved
"required": "false",
"groupName": "generalAdvanced"
"groupName": "generalAdvanced",
"visibleRule": "command = custom || command = build"
}
],
"dataSourceBindings": [
Expand Down
5 changes: 3 additions & 2 deletions Tasks/DotNetCoreCLIV2/task.loc.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"version": {
"Major": 2,
"Minor": 169,
"Patch": 2
"Patch": 5
},
"minimumAgentVersion": "2.115.0",
"instanceNameFormat": "ms-resource:loc.instanceNameFormat",
Expand Down Expand Up @@ -490,7 +490,8 @@
"label": "ms-resource:loc.input.label.workingDirectory",
"helpMarkDown": "ms-resource:loc.input.help.workingDirectory",
"required": "false",
"groupName": "generalAdvanced"
"groupName": "generalAdvanced",
"visibleRule": "command = custom || command = build"
issacnitin marked this conversation as resolved.
Show resolved Hide resolved
}
],
"dataSourceBindings": [
Expand Down