[NPMCLI-103] create-light-module: warn if nearest tomcat has different light-module dir Created: 13/Feb/17 Updated: 07/Feb/18 Resolved: 07/Feb/18 |
|
| Status: | Closed |
| Project: | Magnolia CLI |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.2.0 |
| Type: | Improvement | Priority: | Neutral |
| Reporter: | Robert Kowalski | Assignee: | Federico Grilli |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Attachments: |
|
||||||||
| Issue Links: |
|
||||||||
| Template: |
|
||||||||
| Acceptance criteria: |
Empty
|
||||||||
| Task DoD: |
[ ]*
Doc/release notes changes? Comment present?
[ ]*
Downstream builds green?
[ ]*
Solution information and context easily available?
[ ]*
Tests
[ ]*
FixVersion filled and not yet released
[ ] 
Architecture Decision Record (ADR)
|
||||||||
| Date of First Response: | |||||||||
| Sprint: | Basel 89, Basel 90, Basel 91, Basel 92, Basel 93, Basel 122, Basel 128, Basel 129 | ||||||||
| Story Points: | 3 | ||||||||
| Description |
|
From: https://git.magnolia-cms.com/projects/BUILD/repos/npm-cli/pull-requests/45/overview?commentId=13210 Add a check that tests the nearest `apache-tomcat/webapps/magnoliaAuthor/WEB-INF/config/default/magnolia.properties#magnolia.resources.dir` if the Light Module root is set correctly. If not, print a warning – or exit with error (continue anyway with --force / -f) |
| Comments |
| Comment by Federico Grilli [ 16/Nov/17 ] |
|
Doesn't work as expected. E.g. running mgnl create-light-module my-module from within the light-modules root folder bails out as the lm root is resolved incorrectly |
| Comment by Christopher Zimmermann [ 07/Dec/17 ] |
|
We need to improve the language of the error message. |
| Comment by Christopher Zimmermann [ 07/Dec/17 ] |
|
Example of error message: cmeier@chmsLittleMacBookPro ~/dev/light-modules $ mgnl create-light-module jabadabadu info Using configuration at /usr/local/lib/node_modules/@magnolia/cli/lib/config/mgnl-cli.json ERR! Module is being created at [/Users/cmeier/dev/light-modules] which doesn't match the light modules root [false] found at the nearest Tomcat installation at []. This means Magnolia likely won't be able to observe your module. Use --force if you really want to continue or specify the --path to a valid light modules root folder. |
| Comment by Federico Grilli [ 03/Jan/18 ] |
|
I verified that the pattern to look for the nearest tomcat installation is not restrictive and would work also with manually downloaded bundles. |