Giter Club home page Giter Club logo

trello-cli's Introduction

DTAC (Docopt Trello API CLI)

DTAC (Docopt Trello API CLI)

Usage:
  base.py member-boards
  base.py boards [--create=<data>]
  base.py boards <id>
  base.py boards <id> [--delete | --update=<data>]
  base.py boards <id> [<nested-entity>]
  base.py cards [--create=<data>]
  base.py cards <id>
  base.py cards <id> [--delete | --update=<data>]
  base.py cards <id> [<nested-entity> --create=<data>]
  base.py (-h | --help)
  base.py --version

Options:
  -h --help     Show this screen.
  --version     Show version.

Credentials

To access the Trello API you will need a key and a token - for more info on generating these check Trello's Developer API Keys. The CLI expects two environment variables, TRELLO_KEY & TRELLO_TOKEN- if not set a message will be displayed.

To add a card with labels on board Y to the X column with labels and a comment:

  • cd into source folder and install requirements - pip install -r requirements.txt
  • all of the following commands should be preceded by python trello-cli/base.py
  • fetch all boards and explore ids - member-boards
  • fetch all of the lists on a board (and find id) - boards <board-id> lists
  • fetch all of the labels on a board (and find ids) - boards <board-id> labels
  • create a card on a list - cards --create='{"name": <card-name>, "idList":<list-id>, "idLabels":[<label-id-1>, <label-id-2>]}'
  • add a comment to the card - cards <card-id> comments --create='{"text": <comment-text>}'

Future development

  • find how to refresh the Trello token (it has been exposed in this repo in previous commits)
  • explore the whole Trello API
  • explore if the current CLI format is good enough
  • explore ways to improve the docopt help message - this and this
  • ideally new request types & endpoints can be implemented by only changing the docopt help message - the current challenge is to find a better way to handle paths like /members/me/boards & /actions/comments
  • expose Trello's key and token config as docopt options and fallback to environment variables
  • add proper nested entities support - currently any value is allowed for a nested entity, but these should be restricted depending on the command
  • make the CLI installable
  • choose a test framework and start adding tests
  • single source of truth - read the docopt help message from this readme - that way a change here would be reflected directly in the code!
  • implement the whole Trello API
  • logging + verbose options
  • custom colors, formatting, others

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.