private boolean writeProject(TaskMonitor monitor) throws IOException {
		boolean ok = false;

		JarOutputStream jarOut = new JarOutputStream(new FileOutputStream(jarFile));
		// exclude the lock files on programs
		JarWriter writer = new JarWriter(jarOut, new String[] { ArchivePlugin.DB_LOCK_EXT });
		String archiveComment = "Ghidra archive file for " + projectName + " project.";
		jarOut.setComment(archiveComment);
		// write the .gpr file 
		File projectFile = project.getProjectLocator().getMarkerFile();
		ok = writer.outputFile(projectFile, "", monitor);
		if (ok) {
			// write an indicator that this is jar format vs writing XML files
			ZipEntry entry = new ZipEntry(ArchivePlugin.JAR_VERSION_TAG);
			jarOut.putNextEntry(entry);

			ok = writeProjectDirs(writer, monitor);

		}
		jarOut.close();
		return ok;
	}
Write project out to the jar file.
@param monitor monitor that can be cancelled
@return true if no errors occurred within the JarWriter object
@throws IOException
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/archive/ArchiveTask.java