[
https://issues.apache.org/jira/browse/CAMEL-22028?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17948156#comment-17948156
]
Thomas Diesler commented on CAMEL-22028:
----------------------------------------
I prpose an addition check at the low level export command, like this ...
{code}
private void verifyExportFiles() throws FileNotFoundException {
for (var fn : files) {
if (fn.startsWith("classpath:")) {
continue;
}
if (fn.startsWith("file:")) {
fn = fn.substring(5);
}
if (fn.endsWith("/*")) {
fn = fn.substring(0, fn.length() - 2);
}
if (!Paths.get(fn).toFile().exists()) {
throw new FileNotFoundException("Path does not exist: " + fn);
}
}
}
{code}
> camel-jbang - Regression with missing routes file
> -------------------------------------------------
>
> Key: CAMEL-22028
> URL: https://issues.apache.org/jira/browse/CAMEL-22028
> Project: Camel
> Issue Type: Bug
> Components: camel-jbang
> Reporter: Thomas Diesler
> Assignee: Thomas Diesler
> Priority: Major
> Fix For: 4.12.0
>
>
> An invalid routes file should produce: ERROR: Project export failed!
--
This message was sent by Atlassian Jira
(v8.20.10#820010)