Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 359068

Summary: Preview mode attempts to create target folders
Product: [Modeling] Acceleo Reporter: Ed Willink <ed>
Component: CoreAssignee: Project Inbox <acceleo-inbox>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: laurent.goubet
Version: 3.1.1   
Target Milestone: ---   
Hardware: PC   
OS: Windows Vista   
See Also: https://git.eclipse.org/r/69919
https://git.eclipse.org/c/acceleo/org.eclipse.acceleo.git/commit/?id=6b5618f90c320974c15757ccabb0515be8d7d5bf
Whiteboard:

Description Ed Willink CLA 2011-09-27 09:53:19 EDT
In preview mode the target folder may not exist, or may be some application-specific name. If it does not exist because it is "" I get

java.io.IOException: target directory  couldn't be created.
	at org.eclipse.acceleo.engine.service.AbstractAcceleoGenerator.generate(AbstractAcceleoGenerator.java:173)
	at org.eclipse.ocl.examples.codegen.ecore.generator.OCLGeneratorAdapterFactory.initialize(OCLGeneratorAdapterFactory.java:65)
	at org.eclipse.emf.codegen.ecore.generator.Generator.initialize(Generator.java:256)
	at org.eclipse.emf.codegen.ecore.generator.Generator.setInput(Generator.java:225)
	at org.eclipse.emf.codegen.ecore.genmodel.util.GenModelUtil.createGenerator(GenModelUtil.java:62)
Comment 1 Eclipse Genie CLA 2016-04-05 10:01:29 EDT
New Gerrit change created: https://git.eclipse.org/r/69919
Comment 2 Laurent Goubet CLA 2016-04-05 10:05:57 EDT
The associated gerrit allows users to remove the existence check, which is the best we can do without modifying signatures in this heavily subclassed file. The exitence check is necessary since it is a user's action to decide to use a preview strategy or a regular one, and even with a preview strategy there might be places that actually need the target folder to exist.