Unity Cloud Build calling binary file from repository during PostExportMethod invoke
I'm trying to deploy a game to Itch.io during PostExportMethod.
I'm trying to debug this for over a day, as I can only try building the project once an hour. I've managed to do most of what I've tried to achive. Moved credentials and buttler app out of streaming assets. Zip archived the rest. And call the buttler. However it gives me Win32Exception with error code 2 - file not found. What am I doing wrong? I have no idea now.
Full log: http://pastebin.com/shYtYWQg
public static void OnProjectBuilt(string pathToPlayer)
{
try
{
var i = pathToPlayer.LastIndexOf('/');
pathToPlayer = pathToPlayer.Substring(0, i+ 1);
var pathToEditor = pathToPlayer.Substring(0, pathToPlayer.LastIndexOf('/') +1);
File.Delete(pathToEditor + "butler_creds");
File.Delete(pathToEditor + "butler");
File.Move(pathToPlayer + "ExperimentalProject_Data/StreamingAssets/butler_creds", pathToEditor + "butler_creds");
File.Move(pathToPlayer + "ExperimentalProject_Data/StreamingAssets/butler", pathToEditor + "butler");
string args = String.Format(" -i {0} push {1} {2}:{3}",
pathToEditor + "butler_creds",
pathToEditor + "ExperimentalProject.zip",
AccountName,
ChannelName
);
ZipFile file = new ZipFile();
file.AddDirectory(pathToPlayer);
file.Save(pathToEditor + "ExperimentalProject.zip");
System.Diagnostics.Process uploadProc = new System.Diagnostics.Process();
uploadProc.StartInfo.FileName = pathToEditor + "butler";
uploadProc.StartInfo.Arguments = args;
uploadProc.StartInfo.UseShellExecute = false;
uploadProc.Start();
uploadProc.WaitForExit();
}
catch (Exception e)
{
UnityEngine.Debug.Log(e);
}
}
Answer by $$anonymous$$ · Nov 10, 2019 at 06:20 PM
Hey Kreol, did you ever get this to work?
Can you share how you got butler installed on UCB?
Your answer
Follow this Question
Related Questions
Basic Unity Cloud Build Questions 0 Answers
Andriod build due to the error on unity cloud build but works fine on local build . 0 Answers
Getting error about incorrect bundle id, Android Cloud Build 0 Answers
Android Build Failed on unity cloud build but work fine on local build ,log is below here 0 Answers