mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2025-10-03 09:49:23 +02:00
Merge remote-tracking branch 'origin/Ghidra_12.0'
This commit is contained in:
commit
15760581ad
3 changed files with 12 additions and 17 deletions
|
@ -4,9 +4,9 @@
|
|||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
|
@ -268,10 +268,8 @@ public class ExtensionDetails implements Comparable<ExtensionDetails> {
|
|||
}
|
||||
|
||||
/**
|
||||
* Returns true if this extension is installed under an installation folder or inside of a
|
||||
* source control repository folder.
|
||||
* @return true if this extension is installed under an installation folder or inside of a
|
||||
* source control repository folder.
|
||||
* {@return true if this extension is installed under an installation folder or inside of a
|
||||
* source control repository folder}
|
||||
*/
|
||||
public boolean isInstalledInInstallationFolder() {
|
||||
if (installDir == null) {
|
||||
|
@ -287,11 +285,10 @@ public class ExtensionDetails implements Comparable<ExtensionDetails> {
|
|||
}
|
||||
|
||||
// extDirs.get(0) is the user extension dir
|
||||
ResourceFile appExtDir = extDirs.get(1);
|
||||
if (FileUtilities.isPathContainedWithin(appExtDir.getFile(false), installDir)) {
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
return extDirs.stream()
|
||||
.skip(1)
|
||||
.anyMatch(
|
||||
dir -> FileUtilities.isPathContainedWithin(dir.getFile(false), installDir));
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -227,9 +227,8 @@ public class GhidraApplicationLayout extends ApplicationLayout {
|
|||
* Returns a prioritized list of directories where Ghidra extensions are installed. These
|
||||
* should be at the following locations:<br>
|
||||
* <ul>
|
||||
* <li><code>[user settings dir]/Extensions</code></li>
|
||||
* <li><code>[application install dir]/Ghidra/Extensions</code> (Release Mode)</li>
|
||||
* <li><code>ghidra/Ghidra/Extensions</code> (Development Mode)</li>
|
||||
* <li>{@code [user settings dir]/Extensions}</li>
|
||||
* <li>{@code [application root dirs]/Extensions}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @return the install folder, or null if can't be determined
|
||||
|
|
|
@ -129,9 +129,8 @@ public abstract class ApplicationLayout {
|
|||
* Returns a prioritized {@link List ordered list} of the application Extensions installation
|
||||
* directories. Typically, the values may be any of the following locations:<br>
|
||||
* <ul>
|
||||
* <li><code>[user settings dir]/Extensions</code></li>
|
||||
* <li><code>[application install dir]/Ghidra/Extensions</code> (Release Mode)</li>
|
||||
* <li><code>ghidra/Ghidra/Extensions</code> (Development Mode)</li>
|
||||
* <li>{@code [user settings dir]/Extensions}</li>
|
||||
* <li>{@code [application root dirs]/Extensions}</li>
|
||||
* </ul>
|
||||
*
|
||||
* @return an {@link List ordered list} of the application Extensions installation directories.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue