mirror of
https://github.com/NationalSecurityAgency/ghidra
synced 2024-10-30 02:29:46 +00:00
GP-1034: New script action now creates ~/ghidra_scripts if it didn't exist
This commit is contained in:
parent
ead982a5e5
commit
a8b9db5f32
1 changed files with 5 additions and 1 deletions
|
@ -549,8 +549,12 @@ public class GhidraScriptComponentProvider extends ComponentProviderAdapter {
|
|||
return;
|
||||
}
|
||||
|
||||
// Create user script directory if it doesn't exist
|
||||
File userScriptsDir = new File(GhidraScriptUtil.USER_SCRIPTS_DIR);
|
||||
FileUtilities.checkedMkdirs(userScriptsDir);
|
||||
|
||||
ResourceFile newFile = GhidraScriptUtil.createNewScript(provider,
|
||||
new ResourceFile(GhidraScriptUtil.USER_SCRIPTS_DIR), getScriptDirectories());
|
||||
new ResourceFile(userScriptsDir), getScriptDirectories());
|
||||
SaveDialog dialog = new SaveNewScriptDialog(getComponent(), "New Script", this, newFile,
|
||||
actionManager.getNewHelpLocation());
|
||||
if (dialog.isCancelled()) {
|
||||
|
|
Loading…
Reference in a new issue