{ "info": { "author": "jisaacstone", "author_email": "jisaacstone+python@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "License :: OSI Approved :: MIT License", "Topic :: Utilities" ], "description": "# command line tool #\n\nUse like this:\n\n cat data.tsv | cut -c4,9 | py \"print('DELETE FROM sites WHERE id IN ({0})'.format(','.join(IN)))\" | psql testdb admin\n\nWhere the `py` bit replaces the slightly longer command:\n\n python -c \"import sys; print 'DELETE FROM sites WHERE id IN ({0})'.format(','.join(sys.stdin))\"\n\nI made this because I am tired of reading man pages for `awk` and `sed` and others; I already know python, but I am also tired of typing `import sys`, etc repeatedly.\n\n`os`, `sys`, `csv` and `json` are pre-imported, as well as `unicode_literals` and `print_function` from the future.\n\nAditionally the following are imported and renamed:\n\n sys.stdin -> IN\n sys.stdout -> OUT\n functools -> FT\n itertools -> IT\n operator -> OP\n pprint.pprint -> PP\n\n-----\n\nFor those interested in more robust solutions checkout pawk or pyp.", "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/jisaacstone/pype", "keywords": null, "license": "MIT", "maintainer": null, "maintainer_email": null, "name": "shell-pype", "package_url": "https://pypi.org/project/shell-pype/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/shell-pype/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/jisaacstone/pype" }, "release_url": "https://pypi.org/project/shell-pype/0.1/", "requires_dist": null, "requires_python": null, "summary": "Tiny helper for command-line python", "version": "0.1" }, "last_serial": 799489, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "735c623f61a2018a488f05fa852bd279", "sha256": "971c74da0c1019b1c2415cf17d2e9d8abac5ab070d2614302c1d571c6d903bc9" }, "downloads": -1, "filename": "shell-pype-0.1.1.tar.gz", "has_sig": false, "md5_digest": "735c623f61a2018a488f05fa852bd279", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 894, "upload_time": "2013-02-19T04:13:54", "url": "https://files.pythonhosted.org/packages/d3/97/0e0e2ce69f0bb7132b83fed45634cbc938bcc6fdb8753523ed585b1d1577/shell-pype-0.1.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "735c623f61a2018a488f05fa852bd279", "sha256": "971c74da0c1019b1c2415cf17d2e9d8abac5ab070d2614302c1d571c6d903bc9" }, "downloads": -1, "filename": "shell-pype-0.1.1.tar.gz", "has_sig": false, "md5_digest": "735c623f61a2018a488f05fa852bd279", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 894, "upload_time": "2013-02-19T04:13:54", "url": "https://files.pythonhosted.org/packages/d3/97/0e0e2ce69f0bb7132b83fed45634cbc938bcc6fdb8753523ed585b1d1577/shell-pype-0.1.1.tar.gz" } ] }