Giter Club home page Giter Club logo

cognomen's Introduction

This project has been ported to roots/trellis-cli and been abandoned.

Use roots/trellis-cli instead and checkout similar tools by:


cognomen

oclif Version Downloads/week License Hire Itineris

Goal

Generate WP CLI aliases for Trellis projects.

Learn more on:

Requirements

  • NodeJS v10 or later
  • WP CLI v2 or later
  • Ansible v2.7.4 or later

Installation

$ npx @itinerisltd/cognomen just works! No installation required.

Usage

$ cd /path/to/trellis
$ npx @itinerisltd/cognomen

Add these lines to <bedrock>/wp-cli.yml or <bedrock>/wp-cli.local.yml:

_:
  inherit: wp-cli.cognomen.yml
$ cd /path/to/bedrock
$ wp @staging cli info
$ wp @production cli info

Options

# Specific remote environments
$ npx @itinerisltd/cognomen --remotes=staging,testing,qa

# Specific local environment
$ npx @itinerisltd/cognomen --local=dev

$ npx @itinerisltd/cognomen --help
Generate WP CLI aliases for Trellis projects

USAGE
  $ cognomen

OPTIONS
  -h, --help             show CLI help

  -l, --local=local      (required) [default: development] local environment
                         name

  -r, --remotes=remotes  comma-separated list of remote environment names

  -v, --version          show CLI version

FAQ

Error: Alias '@xxx' not found.

Add these lines to <bedrock>/wp-cli.yml or <bedrock>/wp-cli.local.yml:

_:
  inherit: wp-cli.cognomen.yml

What if I have a multiple web server setup?

Only 1 alias is generated per enviroment even if you have a multiple web server setup. Under the hood, cogomen use anisble run_once option to achive that.

Can I change default flag values via environment variables?

Yes.

These 2 commands are equivalent:

$ npx @itinerisltd/cognomen --remotes=staging,testing,qa --local=dev
$ COGNOMEN_REMOTES=staging,testing,qa COGNOMEN_LOCAL=dev npx @itinerisltd/cognomen

Can I install cognomen instead of using $ npx?

Yes. However, you are responsible for updating it.

# yarn or npm doesn't matter
$ yarn global add @itinerisltd/cognomen
$ cognomen --remotes=staging,testing,qa --local=dev

Why don't you make an Ansible Galaxy role instead?

Because we have too many sites to maintain, adding/updating roles to all of our sites is tedious.

It looks awesome. Where can I find some more goodies like this?

This isn't on wp.org. Where can I give a ⭐️⭐️⭐️⭐️⭐️ review?

Thanks! Glad you like it. It's important to make my boss know somebody is using this project. Instead of giving reviews on wp.org, consider:

Feedback

Please provide feedback! We want to make this library useful in as many projects as possible. Please submit an issue and point out what you do and don't like, or fork the project and make suggestions. No issue is too small.

Security

If you discover any security related issues, please email [email protected] instead of using the issue tracker.

Change log

Please see CHANGELOG for more information on what has changed recently.

Credits

cognomen is a Itineris Limited project created by Tang Rufus.

Full list of contributors can be found here.

License

cognomen is released under the MIT License.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.