mirror of
https://github.com/actions/runner.git
synced 2025-12-13 10:05:23 +00:00
Fix conflicts
This commit is contained in:
@@ -165,8 +165,7 @@ namespace GitHub.Runner.Common
|
|||||||
|
|
||||||
var body = new StringContent(StringUtil.ConvertToJson(bodyObject), null, "application/json");
|
var body = new StringContent(StringUtil.ConvertToJson(bodyObject), null, "application/json");
|
||||||
|
|
||||||
var response = await RetryRequest(githubApiUrl, githubToken, RequestType.Post, 3, "Failed to add agent", body);
|
var runner = await RetryRequest<DistributedTask.WebApi.Runner>(githubApiUrl, githubToken, RequestType.Post, 3, "Failed to add agent", body);
|
||||||
var runner = StringUtil.ConvertFromJson<GitHub.DistributedTask.WebApi.Runner>(response);
|
|
||||||
agent.Id = runner.Id;
|
agent.Id = runner.Id;
|
||||||
agent.Authorization = new TaskAgentAuthorization()
|
agent.Authorization = new TaskAgentAuthorization()
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -34,13 +34,6 @@ namespace GitHub.DistributedTask.WebApi
|
|||||||
set;
|
set;
|
||||||
}
|
}
|
||||||
|
|
||||||
public List<TaskAgent> ToTaskAgents()
|
|
||||||
{
|
|
||||||
List<TaskAgent> taskAgents = new List<TaskAgent>();
|
|
||||||
|
|
||||||
return Runners.Select(runner => new TaskAgent() { Name = runner.Name }).ToList();
|
|
||||||
}
|
|
||||||
|
|
||||||
public ListRunnersResponse Clone()
|
public ListRunnersResponse Clone()
|
||||||
{
|
{
|
||||||
return new ListRunnersResponse(this);
|
return new ListRunnersResponse(this);
|
||||||
@@ -48,8 +41,6 @@ namespace GitHub.DistributedTask.WebApi
|
|||||||
|
|
||||||
public List<TaskAgent> ToTaskAgents()
|
public List<TaskAgent> ToTaskAgents()
|
||||||
{
|
{
|
||||||
List<TaskAgent> taskAgents = new List<TaskAgent>();
|
|
||||||
|
|
||||||
return Runners.Select(runner => new TaskAgent() { Name = runner.Name }).ToList();
|
return Runners.Select(runner => new TaskAgent() { Name = runner.Name }).ToList();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
|
using System;
|
||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
using System.Security.AccessControl;
|
|
||||||
|
|
||||||
namespace GitHub.DistributedTask.WebApi
|
namespace GitHub.DistributedTask.WebApi
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user