@elasticms/publisher

1.0.1 • Public • Published

Elasticms publisher

NPM package for publishing through elasticms API.

Installation

npm install @elasticms/publisher

Usage

ems-zip-create

npx ems-zip-create --help

Usage: ems-zip-create

Options:
  --filename  Filename zip                     [string] [default: "publish.zip"]
  --globs     glob patterns)                           [array] [default: ["**"]]

examples

create a zip named publish.zip with all files

npx ems-zip-create

create a zip named example.zip with all html files

npx ems-zip-create --filename example.zip --globs *.html

create a zip named example.zip with all files except html files

npx ems-zip-create --filename example.zip --globs ** '!*.html'

create a zip with all files in the directory named assets

npx ems-zip-create --filename example.zip --globs assets/** 

ems-zip-publish

IMPORTANT: for using this command you need to define 2 environment variables named EMS_URL and EMS_TOKEN.

npx ems-zip-publish

Usage: ems-zip-publish

Commands:
  zip-publish.js ems-publish [emsId]  emsId (contentType:ouuid)

Options:
  --filename  Filename zip                     [string] [default: "publish.zip"]
  --field     Field name                          [string] [default: "zip_file"]

examples

Upload the zip named example.zip and create/finalize a new revision for the page with ouuid (AWAST5ok8KzLLWaPKqlr)

npx ems-zip-publish page:AWAST5ok8KzLLWaPKqlr --filename example.zip --field example_zip

Readme

Keywords

none

Package Sidebar

Install

npm i @elasticms/publisher

Weekly Downloads

3

Version

1.0.1

License

MIT

Unpacked Size

9.15 kB

Total Files

8

Last publish

Collaborators

  • davidmattei
  • theus77