[yocto] [PATCH] [PATCH:v2][eclipse-poky][branch:windows-build]Ignore files from repository with invalid resource names

Ioana Grigoropol ioanax.grigoropol at intel.com
Mon Dec 10 08:30:47 PST 2012


- when browsing through files in poky repository, files that contain '<', '>', ':','"', '/', '\', '|', '?', '*' will not be displayed on a Windows environment and will through a ResourceException
- since these files are needed for the internal cooking files should not be deleted, but the user does not need to see or modify them -> just ignore these exception, causing the files to be skipped when browsing the repo

Signed-off-by: Ioana Grigoropol <ioanax.grigoropol at intel.com>
---
 .../newproject/CreateBBCProjectOperation.java      |    5 +++++
 1 file changed, 5 insertions(+)

diff --git a/plugins/org.yocto.bc.ui/src/org/yocto/bc/ui/wizards/newproject/CreateBBCProjectOperation.java b/plugins/org.yocto.bc.ui/src/org/yocto/bc/ui/wizards/newproject/CreateBBCProjectOperation.java
index 1a19479..42fa5b1 100644
--- a/plugins/org.yocto.bc.ui/src/org/yocto/bc/ui/wizards/newproject/CreateBBCProjectOperation.java
+++ b/plugins/org.yocto.bc.ui/src/org/yocto/bc/ui/wizards/newproject/CreateBBCProjectOperation.java
@@ -15,6 +15,7 @@ import java.lang.reflect.InvocationTargetException;
 import java.util.Arrays;
 import java.util.Vector;
 
+import org.eclipse.core.internal.resources.ResourceException;
 import org.eclipse.core.resources.IProject;
 import org.eclipse.core.resources.IProjectDescription;
 import org.eclipse.core.resources.IWorkspace;
@@ -82,6 +83,10 @@ public class CreateBBCProjectOperation extends WorkspaceModifyOperation {
 			proj.open(monitor);
 		} catch (IOException e) {
 			throw new InvocationTargetException(e);
+		} catch (ResourceException e){
+			// ignore this exception since it only occurs for special internal files from the repository on Windows platform
+			// the resource names on Windows must not contain '<', '>', ':','"', '/', '\', '|', '?', '*'
+			// the ignored files must not be removed since they are internal cooking files, but the user does not need to see/modify them
 		} catch (Exception e) {
 			e.printStackTrace();
 		}
-- 
1.7.9.5




More information about the yocto mailing list