GP-3523: The GhidraDev Eclipse plugin now deletes the intermediate build

directory following a Ghidra Module Extension export action.  This fixes
a Ghidra runtime/debugging issue. (Closes #5327)
This commit is contained in:
Ryan Kurtz 2023-05-25 11:34:55 -04:00
parent 457517669a
commit 86d4aafab0
5 changed files with 62 additions and 31 deletions

View file

@ -44,6 +44,7 @@ import ghidra.launch.JavaConfig;
import ghidradev.ghidraprojectcreator.utils.GhidraProjectUtils;
import ghidradev.ghidraprojectcreator.wizards.pages.ChooseGhidraModuleProjectWizardPage;
import ghidradev.ghidraprojectcreator.wizards.pages.ConfigureGradleWizardPage;
import utilities.util.FileUtilities;
/**
* Wizard for exporting a Ghidra module project to a releasable extension zip bundle.
@ -151,6 +152,11 @@ public class ExportGhidraModuleWizard extends Wizard implements INewWizard {
monitor.worked(1);
// Delete the build directory...we don't want Ghidra finding/using it in the module
File buildDir = new File(workingDir, "build");
FileUtilities.deleteDir(buildDir);
// Refresh the project to make the new items visible
project.refreshLocal(IResource.DEPTH_INFINITE, monitor);
monitor.worked(1);