Bug 26699 Create Jar fails with no warning if jar read-only
Once *.jardesc has been created, if I invoke "Create JAR" from the context menu and the jar file already exists and is read-only, the progress dialog flashes and nothing more happens. Please add check for this condition and at least an error message should be displayed. Even better, ask something like "Jar file read-only, overwrite?" Y/N and overwrite the file on yes (similar to what the option "warn if jar file exists" does).
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/jarpackager/JarFileExportOperation.java
}
	private void exportContainer(IProgressMonitor progressMonitor, IContainer container) throws java.lang.InterruptedException {
		if (container.getType() == IResource.FOLDER && isOutputFolder((IFolder)container))
			return;
		
		IResource[] children= null;
		try {
			children= container.members();
		} catch (CoreException e) {
			
			addWarning(JarPackagerMessages.getFormattedString("JarFileExportOperation.errorDuringExport", container.getFullPath()), e); 
		}
		for (int i= 0; i < children.length; i++)
			exportElement(children[i], progressMonitor);
	}
	private IPackageFragmentRoot findPackageFragmentRoot(IJavaProject jProject, IPath path) throws JavaModelException {
		if (jProject == null || path == null || path.segmentCount() <= 0)
			return null;
		IPackageFragmentRoot pkgRoot= jProject.findPackageFragmentRoot(path);
		if (pkgRoot != null)
			return pkgRoot;
		else 
			return findPackageFragmentRoot(jProject, path.removeLastSegments(1));
	}
	private void exportResource(IProgressMonitor progressMonitor, IPackageFragmentRoot pkgRoot, boolean isInJavaProject, IResource resource, IPath destinationPath, boolean isInOutputFolder) {
		boolean isNonJavaResource= !isInJavaProject || pkgRoot == null;
		boolean isInClassFolder= false;
		try {
			isInClassFolder= pkgRoot != null && !pkgRoot.isArchive() && pkgRoot.getKind() == IPackageFragmentRoot.K_BINARY;
		} catch (JavaModelException ex) {