{ "info": { "author": "Bj\u00f6rn Andersson", "author_email": "ba@sanitarium.se", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.6", "Programming Language :: Python :: 2.7" ], "description": "A command line interface for common `Go Continuous Delivery`_ tasks\n===================================================================\n\n.. image:: http://codecov.io/github/gaqzi/gocd-cli/coverage.svg?branch=master\n :target: http://codecov.io/github/gaqzi/gocd-cli?branch=master\n :alt: Coverage Status\n\n.. image:: https://snap-ci.com/gaqzi/gocd-cli/branch/master/build_image\n :target: https://snap-ci.com/gaqzi/gocd-cli/branch/master\n :alt: Build Status\n\n.. image:: https://img.shields.io/pypi/v/gocd-cli.svg\n :target: https://pypi.python.org/pypi/gocd-cli/\n :alt: Latest Version\n\n.. image:: https://img.shields.io/pypi/dm/gocd-cli.svg\n :target: https://pypi.python.org/pypi/gocd-cli/\n :alt: Downloads\n\n.. image:: https://img.shields.io/pypi/pyversions/gocd-cli.svg\n :target: https://pypi.python.org/pypi/gocd-cli/\n :alt: Python versions \n\n.. image:: https://img.shields.io/pypi/status/gocd-cli.svg\n :target: https://pypi.python.org/pypi/gocd-cli/\n :alt: Package status\n\nFor work I and colleagues have for the last nine months been writing a lot of\ndifferent small shell scripts with curl that interacts with the Go API.\n\nMost of them are quick n' dirty scripts that aren't very robust, and because\nthey're written in the mindset of the now we just end up copy+pasting it\neverywhere. As well as figuring out what API endpoints are available, how they\nwork and so on.\n\nThe goal of this project is to make these and similar tasks super simple,\nwithout having to write a so-so reliable bash script. And for the most common\nthings just one invocation.\n\nNote\n----\n\nThis is still early in the development and a bit rough around the edges.\nAny bug reports, feature suggestions, etc are greatly appreciated. :)\n\nI'm planning to add support for all the API endpoints that make sense from a CLI\nperspective. And also to handle some of the scenarios where we ended up writing\nshell scripts.\n\nInstallation and usage\n----------------------\n\n**Installation**\n\nSince this is a Python package available on PyPi you can install it like \nany other Python package.\n\n.. code-block:: shell\n\n # on modern systems with Python you can install with pip\n $ pip install gocd-cli\n # on older systems you can install using easy_install\n $ easy_install gocd-cli\n\n\n**Usage**\nThe commands should be mostly self-documenting in how they are defined,\nwhich is made available through the ``help`` command.\n\n.. code-block:: shell\n\n $ gocd\n usage: gocd [, ...] [--kwarg1=value, ...]\n Commands:\n pipeline\n check: Check whether a pipeline has run successfully\n check-all: Checks all pipelines to be green/non-stalled\n list: Lists all pipelines with their current status\n pause: Pauses the named pipeline\n retrigger-failed: Retrigger a pipeline/stage that has failed\n trigger: Triggers the named pipeline\n unlock: Unlocks the named pipeline if it's currently locked\n unpause: Unpauses the named pipeline\n\n $ gocd help pipeline retrigger-failed\n retrigger-failed [--counter] [--stage] [--retrigger]\n\n Retrigger a pipeline/stage that has failed\n\n Flags:\n counter: the pipeline counter to check. Default: latest\n stage: if given the pipeline will only be retriggered if\n this stage failed\n retrigger: possible values (pipeline, stage) default pipeline.\n When pipeline and there's a failed stage retriggers the pipeline.\n When stage and there's a failure retriggers only that stage.\n $ gocd pipeline retrigger-failed Integration --stage external-points --retrigger stage\n\nConfiguration\n-------------\n\nThis script has been prepared to be run two situations:\n\n1. From your local machine\n2. From inside of Go\n\nBecause of this the configuration is handled by a config file and\nit can be overridden by environment variables.\n\nThe current options are:\n\n:server: The server to connect to, example: http://go.example.com:8153/\n:user: The user to login as\n:password: The corresponding password\n\nThe configuration file is stored in ``~/.gocd/gocd-cli.cfg`` and is an ini file.\nExample:\n\n.. code-block:: ini\n\n [gocd]\n server = http://localhost:8153/\n user = admin\n password = badger\n\nThe environment variables are prefixed with ``GOCD_`` and always ALL CAPS.\nExample:\n\n.. code-block:: shell\n\n GOCD_SERVER=http://loaclhost:8153/\n GOCD_USER=admin\n GOCD_PASSWORD=badger\n\n**Encrypted configuration keys**\n\n>From version 0.9 there's support for encrypted configuration keys.\nThere's a builtin module for Rot13, or `Caesar cipher`_, as well as\na standalone module using `blowfish`_ called `gocd-cli.encryption.blowfish`_.\n\nThis feature was added to handle a very specific use case, where the\npassword to the Go server was not allowed to be stored in plaintext. But\nit was okay if the decryption key was stored on the same machine. The\nbuiltin implementation is to be seen as a reference implementation and\nnot to be used. But then again, if you just need it to not be plaintext\u2026\n\n**Usage**\n\nTo then encrypt the current plaintext password do:\n\n.. code-block:: shell\n\n $ gocd settings encrypt --key password\n encryption_module = gocd_cli.encryption.caesar\n password_encrypted = fhcre frperg\n\nCopy these two values into your ``~/.gocd/gocd-cli.cfg`` file and remove\nthe old ``password`` and next time it'll use the encrypted password instead.\n\nTo decrypt:\n\n.. code-block:: shell\n\n $ gocd settings decrypt --key password\n encryption_module = gocd_cli.encryption.caesar\n password = super secret\n\nWriting your own commands\n-------------------------\n\nThis project uses `namespaced packages`_ which means that you as a \nplugin/command author will extend the official namespace with your \ncommands. \n\nThere are several advantages to this:\n\n* The CLI can dynamically be updated with new commands, just \n install a Python package to get it integrated\n* Internal/private commands can easily be used side-by-side with public\n commands, no need to maintain a fork for your personal commands\n* Low entry to making your own commands\n\nThe way the cli searches for commands is quite straightforward:\n\n* The first argument is the package the command belongs to\n* The second argument is the class to call\n* Any unnamed parameters are passed in the same order as on the cli\n* Any ``--parameters`` gets the dashes stripped and sent as keyword arguments\n\nTo make it work this way there's a pattern to keep to. For each package the\n``__init__.py`` file will have to provide all the subcommands in the ``__all__``\nvariable. Each command is a class and it's the name of those classes that are in\nthe ``__all__`` variable. There is an example `gocd-cli.commands.echo`_ \nwhich only does the bare minimum to show how all this works.\n\nThe subcommands will on the command line be divided by dashes, meaning that\n``RetriggerFailed`` will become ``retrigger-failed`` on the command line.\n\n.. code-block:: shell\n\n $ gocd posarg1 --kwarg1\n # or how it's referred to in code\n $ gocd posarg1 --kwarg1\n # or when used\n $ gocd pipeline retrigger-failed Simple-with-lock --stage=firstStage \\\n --retrigger=stage\n\nCalling help for a command or subcommand will list all available commands, for\nmore information about each command ask for help on each in turn.\n\n.. _`Go Continuous Delivery`: http://go.cd/\n.. _namespaced packages: http://pythonhosted.org/setuptools/setuptools.html#namespace-packages\n.. _gocd-cli.commands.echo: https://github.com/gaqzi/gocd-cli.commands.echo\n.. _Caesar cipher: https://en.wikipedia.org/wiki/Caesar_cipher\n.. _gocd-cli.encryption.blowfish: https://github.com/gaqzi/gocd-cli.encryption.blowfish\n.. _blowfish: https://en.wikipedia.org/wiki/Blowfish_(cipher)", "description_content_type": null, "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/gaqzi/gocd-cli/", "keywords": "", "license": "MIT License", "maintainer": "", "maintainer_email": "", "name": "gocd-cli", "package_url": "https://pypi.org/project/gocd-cli/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/gocd-cli/", "project_urls": { "Homepage": "https://github.com/gaqzi/gocd-cli/" }, "release_url": "https://pypi.org/project/gocd-cli/0.10.0/", "requires_dist": [ "gocd (>=0.10.0,<1.0)" ], "requires_python": "", "summary": "A CLI client for interacting with Go Continuous Delivery", "version": "0.10.0" }, "last_serial": 1832430, "releases": { "0.10.0": [ { "comment_text": "", "digests": { "md5": "cb8dfd4f2711bca405012c5342f5bb15", "sha256": "82e63e34963fec2eb42f64297021b4df4a88d8223564d4109ffccc073c0e5e53" }, "downloads": -1, "filename": "gocd_cli-0.10.0-py2-none-any.whl", "has_sig": false, "md5_digest": "cb8dfd4f2711bca405012c5342f5bb15", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 21127, "upload_time": "2015-11-25T03:46:35", "url": "https://files.pythonhosted.org/packages/33/b7/9681f9665af6be4963220f5ef20561551ec924b3a6e572339886b1efcf8d/gocd_cli-0.10.0-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "f2d5bb2841432a6371b139943a057e97", "sha256": "5b396ad0b379c3c449e014a3d1c9c9f7936167aafd104abe700f80d421244f47" }, "downloads": -1, "filename": "gocd-cli-0.10.0.tar.gz", "has_sig": false, "md5_digest": "f2d5bb2841432a6371b139943a057e97", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14288, "upload_time": "2015-11-25T03:46:42", "url": "https://files.pythonhosted.org/packages/c1/3b/5e6b46ecb32491f94b5599737b7b4f8bd5da2372a4bfe796175db93fd0bd/gocd-cli-0.10.0.tar.gz" } ], "0.7.0.3": [ { "comment_text": "", "digests": { "md5": "ac1b19129c8060c628a581263ad5f88a", "sha256": "b476555e66a479d945096916f213bb9acd14f3fd805280bcbbeaf6117696faa0" }, "downloads": -1, "filename": "gocd_cli-0.7.0.3-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "ac1b19129c8060c628a581263ad5f88a", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 14734, "upload_time": "2015-08-11T15:49:33", "url": "https://files.pythonhosted.org/packages/77/03/32f929ea2f037b0d44b9a152edd7274a290459cc6ae7d52e4d3513afada1/gocd_cli-0.7.0.3-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "e07143c1c7eeab8b3b33fddce533bfe4", "sha256": "b7fe31cc72816faef709636a4606dbf20d9b4b432a417d6a33a8591d2c8ced2f" }, "downloads": -1, "filename": "gocd-cli-0.7.0.3.tar.gz", "has_sig": false, "md5_digest": "e07143c1c7eeab8b3b33fddce533bfe4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9363, "upload_time": "2015-08-11T15:49:28", "url": "https://files.pythonhosted.org/packages/af/09/bd15bdb52a940a8cde9b22c971a647ee6a015261bbe6baff643d92117115/gocd-cli-0.7.0.3.tar.gz" } ], "0.7.1": [ { "comment_text": "", "digests": { "md5": "ef3aa96980a6f1eb371a5a25482d516e", "sha256": "d014c78602a490c1850a45d7bd6cc06836d5ca2626825b7e84b2d2f9f8201ac0" }, "downloads": -1, "filename": "gocd_cli-0.7.1-py2-none-any.whl", "has_sig": false, "md5_digest": "ef3aa96980a6f1eb371a5a25482d516e", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 14435, "upload_time": "2015-08-23T14:50:46", "url": "https://files.pythonhosted.org/packages/fa/e9/abddbc98daa70f4f9aebd5b29a68bf1b049f8fa5ded4b0294ce78039afa8/gocd_cli-0.7.1-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "8bcff4d0430091e55f03170ba0e73060", "sha256": "02a87a2d06fc57d4aa168f6282928790dde896e431db554a349884ca83cf0c46" }, "downloads": -1, "filename": "gocd-cli-0.7.1.tar.gz", "has_sig": false, "md5_digest": "8bcff4d0430091e55f03170ba0e73060", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9543, "upload_time": "2015-08-23T14:50:50", "url": "https://files.pythonhosted.org/packages/4b/df/85a7688ec818d9f3a6aa365b02210fcd417fe9102863acaf294e7f69c584/gocd-cli-0.7.1.tar.gz" } ], "0.8.1": [ { "comment_text": "", "digests": { "md5": "7c741c2db48ae8dec43e34d3b6a94708", "sha256": "0182f07fc5f1d2ff53ae6fbf62974a5c91f6814e4dc7fa3a5eda57bc03626383" }, "downloads": -1, "filename": "gocd_cli-0.8.1-py2-none-any.whl", "has_sig": false, "md5_digest": "7c741c2db48ae8dec43e34d3b6a94708", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 17603, "upload_time": "2015-09-16T08:45:37", "url": "https://files.pythonhosted.org/packages/68/4b/9c3bda68c95c6fb6ce6eced20affcb5f7dac0d7e9a0edc8be0f49af180f8/gocd_cli-0.8.1-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "434b0620797660775722289081b63414", "sha256": "061a411d7e20b8c4192dbb191d258315af3bfc489b771385ae667d9eec308911" }, "downloads": -1, "filename": "gocd-cli-0.8.1.tar.gz", "has_sig": false, "md5_digest": "434b0620797660775722289081b63414", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13565, "upload_time": "2015-09-16T08:45:42", "url": "https://files.pythonhosted.org/packages/91/b4/6e359ae434f5e41a30c23d72036b3e67d543eccd60b9ccc4188f42d14496/gocd-cli-0.8.1.tar.gz" } ], "0.9.0": [ { "comment_text": "", "digests": { "md5": "9d4c0385101280124678179db0e8ca7a", "sha256": "cad515e41812a64eafa2c880e8f123206eeefe5d90c300617714655f4f7243e2" }, "downloads": -1, "filename": "gocd_cli-0.9.0-py2-none-any.whl", "has_sig": false, "md5_digest": "9d4c0385101280124678179db0e8ca7a", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 20294, "upload_time": "2015-10-26T15:21:07", "url": "https://files.pythonhosted.org/packages/f1/0d/1f8decbfa66645d0d3a95c3c8c5ade86244c26017c27740f10935d4ed25d/gocd_cli-0.9.0-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "c71f7d0c85b8e96b3c5a087aaa3e9cd9", "sha256": "33f275588d3d0f15b9ab9451368d69826cd64efbe316d8a11a7797d8e31c38c2" }, "downloads": -1, "filename": "gocd-cli-0.9.0.tar.gz", "has_sig": false, "md5_digest": "c71f7d0c85b8e96b3c5a087aaa3e9cd9", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16623, "upload_time": "2015-10-26T15:21:16", "url": "https://files.pythonhosted.org/packages/00/5f/a2f770755abc586563b013bf819d6be3e84d892cd39d6614b3399e713013/gocd-cli-0.9.0.tar.gz" } ], "0.9.1": [ { "comment_text": "", "digests": { "md5": "bda073a04344e590130e0a3e7d67bb05", "sha256": "74c7b098dbe481dba3f8a0f0fbbd2a6520f7de4839030adb35daf31cfc553cc1" }, "downloads": -1, "filename": "gocd_cli-0.9.1-py2-none-any.whl", "has_sig": false, "md5_digest": "bda073a04344e590130e0a3e7d67bb05", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 20500, "upload_time": "2015-11-05T04:07:27", "url": "https://files.pythonhosted.org/packages/da/c8/7bce2f1078f149b00c9d372b4fd5365b4a1c285a406ea2f2af44685b7cc8/gocd_cli-0.9.1-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "519e8d0f92d9c8a61db16ea8f6f490e7", "sha256": "07f7a1d21d0895b949f0a1f4fbcc51218ba27d0a976230d962fd4b663038e3bf" }, "downloads": -1, "filename": "gocd-cli-0.9.1.tar.gz", "has_sig": false, "md5_digest": "519e8d0f92d9c8a61db16ea8f6f490e7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16618, "upload_time": "2015-11-05T04:07:40", "url": "https://files.pythonhosted.org/packages/01/59/e14453b4abfdaa8779c111464a80365a248aed7cee6e7141325bd87cd735/gocd-cli-0.9.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "cb8dfd4f2711bca405012c5342f5bb15", "sha256": "82e63e34963fec2eb42f64297021b4df4a88d8223564d4109ffccc073c0e5e53" }, "downloads": -1, "filename": "gocd_cli-0.10.0-py2-none-any.whl", "has_sig": false, "md5_digest": "cb8dfd4f2711bca405012c5342f5bb15", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 21127, "upload_time": "2015-11-25T03:46:35", "url": "https://files.pythonhosted.org/packages/33/b7/9681f9665af6be4963220f5ef20561551ec924b3a6e572339886b1efcf8d/gocd_cli-0.10.0-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "f2d5bb2841432a6371b139943a057e97", "sha256": "5b396ad0b379c3c449e014a3d1c9c9f7936167aafd104abe700f80d421244f47" }, "downloads": -1, "filename": "gocd-cli-0.10.0.tar.gz", "has_sig": false, "md5_digest": "f2d5bb2841432a6371b139943a057e97", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14288, "upload_time": "2015-11-25T03:46:42", "url": "https://files.pythonhosted.org/packages/c1/3b/5e6b46ecb32491f94b5599737b7b4f8bd5da2372a4bfe796175db93fd0bd/gocd-cli-0.10.0.tar.gz" } ] }