diff --git a/BeefySysLib/platform/posix/PosixCommon.cpp b/BeefySysLib/platform/posix/PosixCommon.cpp index e108f0a9..9e54babe 100644 --- a/BeefySysLib/platform/posix/PosixCommon.cpp +++ b/BeefySysLib/platform/posix/PosixCommon.cpp @@ -1822,7 +1822,27 @@ BFP_EXPORT void BFP_CALLTYPE BfpDirectory_Create(const char* path, BfpFileResult BFP_EXPORT void BFP_CALLTYPE BfpDirectory_Rename(const char* oldName, const char* newName, BfpFileResult* outResult) { - NOT_IMPL; + if (rename(oldName, newName) != 0) + { + switch (errno) + { + case EEXIST: + OUTRESULT(BfpFileResult_AlreadyExists); + break; + case ENOTEMPTY: + OUTRESULT(BfpFileResult_NotEmpty); + break; + case EISDIR: + case ENOTDIR: + OUTRESULT(BfpFileResult_InvalidParameter); + break; + default: + OUTRESULT(BfpFileResult_UnknownError); + break; + } + } + else + OUTRESULT(BfpFileResult_Ok); } BFP_EXPORT void BFP_CALLTYPE BfpDirectory_Delete(const char* path, BfpFileResult* outResult) diff --git a/IDE/src/util/GitManager.bf b/IDE/src/util/GitManager.bf index dd845c02..daa33186 100644 --- a/IDE/src/util/GitManager.bf +++ b/IDE/src/util/GitManager.bf @@ -95,6 +95,8 @@ class GitManager if (!File.Exists(gitPath)) gitPath.Clear(); } + + psi.UseShellExecute = false; #endif if (gitPath.IsEmpty) gitPath.Set("git"); @@ -103,7 +105,6 @@ class GitManager psi.SetArguments(mArgs); if (mPath != null) psi.SetWorkingDirectory(mPath); - psi.UseShellExecute = false; psi.RedirectStandardError = true; psi.RedirectStandardOutput = true; psi.CreateNoWindow = true; diff --git a/IDE/src/util/PackMan.bf b/IDE/src/util/PackMan.bf index bb9fc14c..8e47aa78 100644 --- a/IDE/src/util/PackMan.bf +++ b/IDE/src/util/PackMan.bf @@ -179,7 +179,12 @@ namespace IDE.util if (!CheckInit()) return; - String beefBuildPath = scope $"{gApp.mInstallDir}BeefBuild.exe"; +#if BF_PLATFORM_WINDOWS + let ext = ".exe"; +#else + let ext = ""; +#endif + String beefBuildPath = scope $"{gApp.mInstallDir}BeefBuild{ext}"; String args = scope $"-run"; var execInst = gApp.DoRun(beefBuildPath, args, path, .None); execInst?.mAutoDelete = false;