{ "info": { "author": "Stefan C. Mueller", "author_email": "scm@smurn.org", "bugtrack_url": null, "classifiers": [], "description": "cish - Write shell-like python scripts to control continuous builds\n===================================================================\n\nI used to write small bash scripts that created the virtualenv and\nexecuted the `python setup.py` and `nosetests` commands using\none of several Python versions I keep installed on my build machines. \nBut bash scripts aren't supported on Windows, so I want to write\nthis script in Python instead. \n\n`cish` is a set of utility functions to write bash-like python\nscripts that deal with several installed python interpreters.\n\n----------------\nLet's get going!\n----------------\n\n.. code-block:: python\n\n import cish\n cish.rm(\"build\")\n cish.default.pip(\"install\", \"nose\")\n cish.default.python(\"setup.py\", \"build\")\n cish.default.nosetests()\n\nThis will delete the `build` directory if it exists with all content,\ninstall `nose`, and build and test the package.\n\n`default` is an 'environment' which consists of a python interpreter,\nlibrary path, and utilities such as `pip`. `default` is the environent\nof the interpreter executing the script itself.\n\nWe can also use a different interpreter:\n\n.. code-block:: python\n\n import cish\n env = cish.from_interpreter(\"path/to/python\")\n env.python(\"setup.py\", \"build\")\n env.nosetests()\n\nThe installation location of the python interpreters is often\ndependent on the test machine. We can place a simple JSON file\nin one of several locations, for example in `/etc/cish.json`, \nto specifiy their location:\n\n.. code-block:: json\n\n {\n \"2.6.9\": \"/opt/python2.6.9/bin/python\",\n \"2.7.8\": \"/opt/python2.7.8/bin/python\"\n }\n\nWe can then choose the interpeter in our script using, say,\nan environment variable set by jenkins:\n\n.. code-block:: python\n\n import cish, os\n env = cish.from_config()[os.environ[\"PYTHON_VERSION\"]]\n env.python(\"setup.py\", \"build\")\n\n`virtualenv` is very easy too:\n\n.. code-block:: python\n\n import cish\n venv = cish.default.virtualenv(\"optional/location\")\n venv.pip(\"install\", \"package_to_install_inside_virtualenv\")\n\n-----------------------------------\nBug Reports and other contributions\n-----------------------------------\n\nThis project is hosted here `cish github page `_.\n \n------------\nAlternatives\n------------\n\nYou might want to look at `sh `_ a cool library to\nrun executables without dealing with `subprocess` directly. It has a far wider\nscope than `cish` but lacks the abstraction we offer for different python installations\nand OS specific file extensions and installation locations.", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/smurn/cish", "keywords": null, "license": "UNKNOWN", "maintainer": null, "maintainer_email": null, "name": "cish", "package_url": "https://pypi.org/project/cish/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/cish/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/smurn/cish" }, "release_url": "https://pypi.org/project/cish/0.2.1/", "requires_dist": null, "requires_python": null, "summary": "Write shell-like python scripts to control continuous builds.", "version": "0.2.1" }, "last_serial": 1404421, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "e0746fd845dd59a66189f08d8d699cf2", "sha256": "2b8b8d6ccd1ee1649e7b217d5035862a0ffc5c3734a68a1cc2b90335ad95fb43" }, "downloads": -1, "filename": "cish-0.1.0.zip", "has_sig": false, "md5_digest": "e0746fd845dd59a66189f08d8d699cf2", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13760, "upload_time": "2014-10-31T04:05:30", "url": "https://files.pythonhosted.org/packages/77/3c/ccd75335cdb158962153cd919c698ec8c039a0c755b4c4c6f402a601fae8/cish-0.1.0.zip" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "15e037862f55110d68301172eea2861d", "sha256": "3806b02ca38ea9018956388466a506d9d0c782e38feb85dd24c786fca92470d8" }, "downloads": -1, "filename": "cish-0.1.1.zip", "has_sig": false, "md5_digest": "15e037862f55110d68301172eea2861d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15176, "upload_time": "2014-10-31T22:36:45", "url": "https://files.pythonhosted.org/packages/00/dd/ae9344a0a531f2625da9261957bd7f65743140b3be7eecb586d4f3ce7db3/cish-0.1.1.zip" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "cbf269b11ad151a63a8f5e31deeae9bb", "sha256": "83563f61226521cdc3fcabc93bd540e2d94dccc7bec6668d10aa94448d4d7d31" }, "downloads": -1, "filename": "cish-0.1.2.zip", "has_sig": false, "md5_digest": "cbf269b11ad151a63a8f5e31deeae9bb", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15212, "upload_time": "2014-11-01T20:12:38", "url": "https://files.pythonhosted.org/packages/3f/23/a610d36e17edf26d4930c96d218c3a4bf0cd3be3d90b8bb1db6197f27252/cish-0.1.2.zip" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "46222675fc7ac198e2d75183097c3abd", "sha256": "e99d6664d0b847a87723cc5196354f93a813691444a56a2411c812bf8bba2b14" }, "downloads": -1, "filename": "cish-0.2.0.zip", "has_sig": false, "md5_digest": "46222675fc7ac198e2d75183097c3abd", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15288, "upload_time": "2015-01-31T18:22:45", "url": "https://files.pythonhosted.org/packages/f9/3a/cd512da06edcf9a3ff7371bf349def1dd38f6d1cb4aaed615282bd1eeb22/cish-0.2.0.zip" } ], "0.2.1": [ { "comment_text": "", "digests": { "md5": "509efa1f5f4cbf434a2b60186b6a7a81", "sha256": "9196c0cca5aed869f21bbe324fca244e79f77dfa43868fb9506c6ffe3880a172" }, "downloads": -1, "filename": "cish-0.2.1.zip", "has_sig": false, "md5_digest": "509efa1f5f4cbf434a2b60186b6a7a81", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15318, "upload_time": "2015-01-31T18:50:45", "url": "https://files.pythonhosted.org/packages/d9/22/c66531b2afba5bc97cb2c68021f9403290a040d86a8f5a2c8e4bfc19313b/cish-0.2.1.zip" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "509efa1f5f4cbf434a2b60186b6a7a81", "sha256": "9196c0cca5aed869f21bbe324fca244e79f77dfa43868fb9506c6ffe3880a172" }, "downloads": -1, "filename": "cish-0.2.1.zip", "has_sig": false, "md5_digest": "509efa1f5f4cbf434a2b60186b6a7a81", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15318, "upload_time": "2015-01-31T18:50:45", "url": "https://files.pythonhosted.org/packages/d9/22/c66531b2afba5bc97cb2c68021f9403290a040d86a8f5a2c8e4bfc19313b/cish-0.2.1.zip" } ] }