mirror of
https://github.com/actions/runner.git
synced 2025-12-11 21:06:55 +00:00
Extend github context with host-workspace (#2517)
* hash files translation works with host context translated * Change file encoding to utf8 for PipelineTemplateConstants.cs * infer the feature flag on hash files based on the existence of the context * encoded utf8 with bom * rename host-workspace to host-work-directory and feature flag the new context var * Added comment to explain ignore host work directory resolution Co-authored-by: fhammerl <fhammerl@github.com> * trigger pipeline * Move to the github host-workspace context instead of the runner host-work-directory * remove unused imports --------- Co-authored-by: fhammerl <fhammerl@github.com>
This commit is contained in:
@@ -26,11 +26,18 @@ namespace GitHub.Runner.Worker.Expressions
|
||||
ArgUtil.NotNull(githubContextData, nameof(githubContextData));
|
||||
var githubContext = githubContextData as DictionaryContextData;
|
||||
ArgUtil.NotNull(githubContext, nameof(githubContext));
|
||||
githubContext.TryGetValue(PipelineTemplateConstants.Workspace, out var workspace);
|
||||
|
||||
if (!githubContext.TryGetValue(PipelineTemplateConstants.HostWorkspace, out var workspace))
|
||||
{
|
||||
githubContext.TryGetValue(PipelineTemplateConstants.Workspace, out workspace);
|
||||
}
|
||||
ArgUtil.NotNull(workspace, nameof(workspace));
|
||||
|
||||
var workspaceData = workspace as StringContextData;
|
||||
ArgUtil.NotNull(workspaceData, nameof(workspaceData));
|
||||
|
||||
string githubWorkspace = workspaceData.Value;
|
||||
|
||||
bool followSymlink = false;
|
||||
List<string> patterns = new();
|
||||
var firstParameter = true;
|
||||
|
||||
Reference in New Issue
Block a user