mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-18 16:10:26 +02:00
Fixed some path error handling, fixed Debug Sessions
This commit is contained in:
parent
169e351a63
commit
595f35b42e
2 changed files with 17 additions and 9 deletions
|
@ -1042,7 +1042,7 @@ namespace IDE
|
||||||
project.mNeedsTargetRebuild = true;
|
project.mNeedsTargetRebuild = true;
|
||||||
|
|
||||||
String targetDir = scope String();
|
String targetDir = scope String();
|
||||||
Path.GetDirectoryPath(targetPath, targetDir);
|
Path.GetDirectoryPath(targetPath, targetDir).IgnoreError();
|
||||||
if (!targetDir.IsEmpty)
|
if (!targetDir.IsEmpty)
|
||||||
Directory.CreateDirectory(targetDir).IgnoreError();
|
Directory.CreateDirectory(targetDir).IgnoreError();
|
||||||
}
|
}
|
||||||
|
|
|
@ -1956,13 +1956,15 @@ namespace IDE
|
||||||
|
|
||||||
let workspaceOptions = GetCurWorkspaceOptions();
|
let workspaceOptions = GetCurWorkspaceOptions();
|
||||||
let options = GetCurProjectOptions(project);
|
let options = GetCurProjectOptions(project);
|
||||||
if (!options.mDebugOptions.mCommand.IsWhiteSpace)
|
|
||||||
{
|
|
||||||
String execCmd = scope .();
|
String execCmd = scope .();
|
||||||
ResolveConfigString(mPlatformName, workspaceOptions, project, options, options.mDebugOptions.mCommand, "command", execCmd);
|
ResolveConfigString(mPlatformName, workspaceOptions, project, options, options.mDebugOptions.mCommand, "command", execCmd);
|
||||||
|
|
||||||
|
if (!execCmd.IsWhiteSpace)
|
||||||
|
{
|
||||||
String initialDir = scope .();
|
String initialDir = scope .();
|
||||||
Path.GetDirectoryPath(execCmd, initialDir);
|
Path.GetDirectoryPath(execCmd, initialDir).IgnoreError();
|
||||||
|
if (!initialDir.IsWhiteSpace)
|
||||||
dialog.InitialDirectory = initialDir;
|
dialog.InitialDirectory = initialDir;
|
||||||
dialog.SetFilter("Debug Session (*.bfdbg)|*.bfdbg");
|
dialog.SetFilter("Debug Session (*.bfdbg)|*.bfdbg");
|
||||||
dialog.DefaultExt = ".bfdbg";
|
dialog.DefaultExt = ".bfdbg";
|
||||||
|
@ -9660,7 +9662,7 @@ namespace IDE
|
||||||
|
|
||||||
if (mWorkspace.mStartupProject != null)
|
if (mWorkspace.mStartupProject != null)
|
||||||
{
|
{
|
||||||
if (mWorkspace.mStartupProject.IsEmpty)
|
if ((mWorkspace.mStartupProject.IsEmpty) && (!mWorkspace.IsDebugSession))
|
||||||
{
|
{
|
||||||
#if !CLI
|
#if !CLI
|
||||||
DarkDialog dlg = new DarkDialog("Initialize Project?",
|
DarkDialog dlg = new DarkDialog("Initialize Project?",
|
||||||
|
@ -10007,8 +10009,14 @@ namespace IDE
|
||||||
IDEUtils.FixFilePath(launchPath);
|
IDEUtils.FixFilePath(launchPath);
|
||||||
IDEUtils.FixFilePath(targetPath);
|
IDEUtils.FixFilePath(targetPath);
|
||||||
|
|
||||||
|
if (launchPath.IsEmpty)
|
||||||
|
{
|
||||||
|
OutputErrorLine("No debug target path was specified");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
if (workingDir.IsEmpty)
|
if (workingDir.IsEmpty)
|
||||||
Path.GetDirectoryPath(launchPath, workingDir);
|
Path.GetDirectoryPath(launchPath, workingDir).IgnoreError();
|
||||||
|
|
||||||
if (!Directory.Exists(workingDir))
|
if (!Directory.Exists(workingDir))
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue