This is an automated email from the ASF dual-hosted git repository.
ntimofeev pushed a commit to branch STABLE-4.1
in repository https://gitbox.apache.org/repos/asf/cayenne.git
The following commit(s) were added to refs/heads/STABLE-4.1 by this push:
new e1d4126 CAY-2727 .xml platform path separator to unix
new 04e57b2 Merge pull request #488 from
Ivan-nikitko/STABLE-4.1_CAY-2727_Modeler_cgen_testDir_platform_path_separator
e1d4126 is described below
commit e1d41267736ff4de9abab620fd8eb135316c7fd7
Author: Ivan-nikitko <[email protected]>
AuthorDate: Sun Jan 23 21:05:28 2022 +0300
CAY-2727 .xml platform path separator to unix
---
.../org/apache/cayenne/gen/CgenConfiguration.java | 23 ++++++++++++++--------
1 file changed, 15 insertions(+), 8 deletions(-)
diff --git
a/cayenne-cgen/src/main/java/org/apache/cayenne/gen/CgenConfiguration.java
b/cayenne-cgen/src/main/java/org/apache/cayenne/gen/CgenConfiguration.java
index 156097c..cb9fc2a 100644
--- a/cayenne-cgen/src/main/java/org/apache/cayenne/gen/CgenConfiguration.java
+++ b/cayenne-cgen/src/main/java/org/apache/cayenne/gen/CgenConfiguration.java
@@ -392,23 +392,30 @@ public class CgenConfiguration implements Serializable,
XMLSerializable {
.attribute("xmlns", CgenExtension.NAMESPACE)
.simpleTag("excludeEntities", getExcludeEntites())
.simpleTag("excludeEmbeddables", getExcludeEmbeddables())
- .simpleTag("destDir", buildRelPath())
+ .simpleTag("destDir", separatorsToUnix(buildRelPath()))
.simpleTag("mode", this.artifactsGenerationMode.getLabel())
- .simpleTag("template", this.template)
- .simpleTag("superTemplate", this.superTemplate)
- .simpleTag("embeddableTemplate", this.embeddableTemplate)
- .simpleTag("embeddableSuperTemplate",
this.embeddableSuperTemplate)
- .simpleTag("queryTemplate", this.queryTemplate)
- .simpleTag("querySuperTemplate", this.querySuperTemplate)
+ .simpleTag("template", separatorsToUnix(this.template))
+ .simpleTag("superTemplate",
separatorsToUnix(this.superTemplate))
+ .simpleTag("embeddableTemplate",
separatorsToUnix(this.embeddableTemplate))
+ .simpleTag("embeddableSuperTemplate",
separatorsToUnix(this.embeddableSuperTemplate))
+ .simpleTag("queryTemplate",
separatorsToUnix(this.queryTemplate))
+ .simpleTag("querySuperTemplate",
separatorsToUnix(this.querySuperTemplate))
.simpleTag("outputPattern", this.outputPattern)
.simpleTag("makePairs", Boolean.toString(this.makePairs))
.simpleTag("usePkgPath", Boolean.toString(this.usePkgPath))
.simpleTag("overwrite", Boolean.toString(this.overwrite))
.simpleTag("createPropertyNames",
Boolean.toString(this.createPropertyNames))
- .simpleTag("superPkg", this.superPkg)
+ .simpleTag("superPkg", separatorsToUnix(this.superPkg))
.simpleTag("createPKProperties",
Boolean.toString(this.createPKProperties))
.simpleTag("client", Boolean.toString(client))
.end();
}
+ private String separatorsToUnix (String path){
+ if (path!=null) {
+ return path.replace('\\', '/');
+ }
+ return null;
+ }
+
}