Uploaded image for project: 'Magnolia CLI'
  1. Magnolia CLI
  2. NPMCLI-35

Error when creating component with -a availability option, outside the light module

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.0.1
    • Labels:
    • Sprint:
      Basel 53
    • Story Points:
      1

      Description

      The error is

      /usr/local/lib/node_modules/@magnolia/cli/bin/addAvailability.js:122
      Error: ENOENT: no such file or directory, open '../mod1/mod1/templates/pages/page1.ftl'
      And the contents of the page1.yaml file are erased.

      To reproduce:

      mgnl create-light-module mod1
      mgnl create-page page1 -p mod1

      Any of the following commands then produce the same error

      mgnl create-component comp2 -p mod1 -a pages/page1@main
      mgnl create-component comp2 -p mod1 -a mod1:pages/page1@main

      -
      I looked at this with Christoph Meier and he was able to accomplish the same basic task - but we didnt understand under what conditions it worked. The above commands failed on both our systems with version 0.0.1-snapshot-70

        Checklists

        Acceptance criteria

          Attachments

            Activity

              People

              Assignee:
              fgrilli Federico Grilli
              Reporter:
              czimmermann Christopher Zimmermann
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Checklists

                  Bug DoR
                  DoD

                    Time Tracking

                    Estimated:
                    Original Estimate - Not Specified
                    Not Specified
                    Remaining:
                    Remaining Estimate - 0d
                    0d
                    Logged:
                    Time Spent - 0.5h
                    0.5h