static String getProjectName(String archivePathName) {
		if (archivePathName == null) {
			return null;
		}
		File archiveFile = new File(archivePathName);
		FileInputStream fileIn = null;
		JarInputStream jarIn = null;
		try {
			fileIn = new FileInputStream(archiveFile);
			jarIn = new JarInputStream(fileIn);
			while (true) {
				ZipEntry zipEntry = jarIn.getNextEntry();
				if (zipEntry == null) {
					break;
				}
				String name = zipEntry.getName();
				jarIn.closeEntry();
				if (name.endsWith(ProjectLocator.getProjectExtension())) {
					int endIndex = name.length() - ProjectLocator.getProjectExtension().length();
					String projectName = name.substring(0, endIndex);
					return projectName;
				}
			}
		}
		catch (IOException e) {
			// just return null below
		}
		finally {
			if (jarIn != null) {
				try {
					jarIn.close();
				}
				catch (IOException e) {
					// we tried
				}
			}
			if (fileIn != null) {
				try {
					fileIn.close();
				}
				catch (IOException e) {
					// we tried
				}
			}
		}
		return null;
	}
Gets the project name for the indicated project archive file.
@param archivePathName the archive project file.
@return the project name or null if the file is not a valid
project archive file.
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/archive/ArchivePlugin.java