Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@prototyp-stockholm/contentful-migrator-programme

Package Overview
Dependencies
Maintainers
4
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@prototyp-stockholm/contentful-migrator-programme

Tool to manage and keep track of contentful migrations.

  • 0.0.3
  • Source
  • npm
  • Socket score

Version published
Maintainers
4
Created
Source

Contentful Migrator Programme

Tool to manage Contentful migrations

Setup

Install package

npm i --save @prototyp-stockholm/contentful-migrator-programme

Set environment variables

Create a .env file in your project root and add those variables:

# required
CTF_SPACE=<SECRET>
CTF_ENVIRONMENT=<SECRET>
CTF_CMA_TOKEN=<SECRET>

# optional
MIGRATIONS_DIR=migrations
MIGRATIONS_TYPE=migrations
ALIAS_AMOUNT=1
ENV_AMOUNT=3

Usage

Available commands

cmp generate <migrationName> # generates a migration with the given name and a timestamp prepended ex: YYYYMMDDhhmmssxxx-add-user-type.js.
cmp apply # applies all _up_ operations of the non applied migrations to the CTF_ENVIRONMENT set in the `.env` file
cmp rollback # applies the _down_ operation of the latest migration
cmp aux:create <name?> # creates an aux env based on CTF_ENVIRONMENT. You can give it an optional name.
cmp aux:drop <name> # drop the env with the given name
cmp aux:test # creates env from CTF_ENVIRONMENT, applies new migrations, and drops the env

If you did not install the package globally you'll have to prepend node_modules/.bin/ to the cmp command.

Otherwise, you can add the cmp command in the scripts section of the project package.json.

Then you can use it like so: npm run cmp.

{
   "scripts": {
       "cmp": "cmp"
   }
}

Keywords

FAQs

Package last updated on 02 Sep 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc