1
這是我目前使用的代碼。它刪除文件的內容並用新內容替換它。如何使用octokit.net修改Github上的現有文件?
var readfile = client.Repository.Content.GetAllContentsByRef(owner, repo, targetFile, branch).Result;
var updatefile =client.Repository.Content.UpdateFile(owner,repo,targetFile,
new UpdateFileRequest("API File update", "Added this new line new ", readfile.First().Sha, branch));
我想將內容添加到文件中。不要取代它。我的代碼有錯嗎?