Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
HTML Wrap
width370
floatright
classmenu

Youtube
width370
videoIdqdDb-oYt18k
height210

Magnolia CLI Tool makes web developers' lives easier.
Note: The video was shot with and refers to Magnolia CORE 5.5.1 CE.
The latest release is

Artifact resource link
groupIdinfo.magnolia.bundle
artifactIdmagnolia-community-demo-bundle
label$version
renderTypedisplay_only
resourceTypeZIP
. (See the differences section on this page.)

Magnolia CLI is an npm package providing a command line interface (CLI) tool to set up and facilitate light development with Magnolia. This page describes how to install, set up and use its commands. 

...

-p <path>

optional

The -p option for the jumpstart command specifies the path to the light modules root folder which is observed for changes, not to an alternative location for the bundle to be installed.

If no path is provided, the a default folder named light-modules is created in the current folder. Light modules are then created under this folder which is observed by Magnolia for changes.

The path to the light modules root folder is set by the magnolia.resources.dir  property in the magnolia.properties file of the installed Magnolia bundle.

-m <version>

optional

The desired version of the Magnolia bundle. If not provided, defaults to the latest version of the chosen bundle (magnolia-community-demo-bundle or magnolia-enterprise-pro-demo-bundle).

-i <name>

optional

If provided, a sample light module under the light modules root folder with the given name is created.

-e

optional (since 1.0.5)

Downloads a magnolia-enterprise-pro-demo-bundle. Requires credentials to Magnolia Nexus.

-c

optional (since 2.2.0)

Downloads a Magnolia Cloud bundle. Requires credentials to Magnolia Nexus.

Example

Code Pro
languagebash
mgnl jumpstart -e -m 5.4.5

...

<light-module-name>

required

At least one name of a light module to be downloaded from npm. If installing more than one module from the repository, separate the module names with a space.

-p <path>

optional

The path to the light-modules folder.

If omitted, mgnl is searching for the nearest apache-tomcat* folder and checks the value of the magnolia.resources.dir property as defined within the webapps of the folder.

Example

Code Pro
mgnl install google-maps-magnolia mgnl-bobby -p /Users/johndoe/dev/mgnl/light-modules/other-users-modules/

...

  • Node v 6.10+ is required to run the CLI.
  • A new option option -c  (--cloud) has been added to the the jumpstart command command.  mgnl jumpstart --cloud downloads c downloads and sets up a Magnolia Cloud bundle. It requires credentials to access Magnolia Nexus.

2.1.0

What has changed?

  • Two new commands have been added:
    • search - helps find light modules on npm. NPMCLI-99
    • install - installs a light module from the registry into your light modules folder. NPMCLI-98
  • In the prototype dialog template, the image alt attribute uses the caption property. NPMCLI-31
  • The placeholder __lightDevModuleFolder__ for the name of the corresponding light module can be used in all prototypes files for page and component templates (in mgnl-cli-prototypes/page/* and mgnl-cli-prototypes/component). NPMCLI-84
  • The tab-completion install command, if completed successfully,  will also display the files (together with their paths) to which the autocompletion script has been appended. NPMCLI-107
  • All CLI i18n messages are served from a single location ( lib/locales/ ). The messages in English are located in the en subfolder. NPMCLI-91
  • This release also fixes a few bugfixes. A complete list of the issues which have been resolved in version 2.1.0 is available via the following link:

...