{ "info": { "author": "John Thorvald Wodder II", "author_email": "daemail@varonathe.org", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Environment :: No Input/Output (Daemon)", "Intended Audience :: Information Technology", "Intended Audience :: System Administrators", "License :: OSI Approved :: MIT License", "Operating System :: POSIX", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.2", "Programming Language :: Python :: 3.3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Topic :: Communications :: Email", "Topic :: Utilities" ], "description": ".. image:: http://www.repostatus.org/badges/latest/active.svg\n :target: http://www.repostatus.org/#active\n :alt: Project Status: Active - The project has reached a stable, usable\n state and is being actively developed.\n\n.. image:: https://img.shields.io/pypi/pyversions/daemail.svg\n :target: https://pypi.python.org/pypi/daemail\n\n.. image:: https://img.shields.io/github/license/jwodder/daemail.svg?maxAge=2592000\n :target: https://opensource.org/licenses/MIT\n :alt: MIT License\n\n`GitHub `_\n| `PyPI `_\n| `Issues `_\n\n``daemail`` (pronounced \"DEE-mayl\", like \"e-mail\" but with a D) is a Python\nscript for running a normally-foreground command in the background and\ne-mailing its output (by default, the combined stdout and stderr) once it's\ndone. It should work in both Python 2.7 and Python 3.2+, the only external\ndependencies being the `python-daemon\n`_ package and the ubiquitous `six\n`_ package.\n\n\nInstallation\n============\n\nJust use `pip `_ (You have pip, right?) to install\n``daemail`` and its dependencies::\n\n pip install daemail\n\n\nUsage\n=====\n\n::\n\n daemail [-C|--chdir ]\n [-D|--dead-letter ]\n [-e|--encoding ]\n [-E|--stderr-encoding ]\n [-f|--from|--from-addr
]\n [-F|--failure-only]\n [-l|--logfile ]\n [-M|--mime-type|--mime ]\n [-n|--nonempty]\n [--no-stdout]\n [--no-stderr]\n [-S|--split]\n [--stdout-filename ]\n [-Z|--utc]\n -t|--to|--to-addr
[-t|--to|--to-addr
...]\n []\n [ ...]\n\nwhere ```` is one of::\n\n -s|--sendmail # default\n\n --mbox \n\n --smtp-host \n [--smtp-port ]\n [--smtp-username ]\n [--smtp-password | --smtp-password-file | --netrc | --netrc-file ]\n [--smtp-ssl | --smtp-starttls]\n\n\nOptions\n-------\n\n- ``-C ``, ``--chdir `` \u2014 Change to ```` after\n daemonizing but before running ````; defaults to the current\n directory\n\n- ``-D ``, ``--dead-letter `` \u2014 If an error occurs when trying to\n send, append the e-mail (including a description of the error) to the file\n ````; defaults to ``dead.letter``. If the file already exists, it must\n be a valid mbox file.\n\n- ``-e ``, ``--encoding `` \u2014 Expect the stdout (and stderr,\n if ``--split`` is not in effect) of ```` to be in the given\n encoding; defaults to the preferred encoding returned by Python's\n |getpreferredencoding|_. If decoding fails, the output will be attached to\n the e-mail as an ``application/octet-stream`` file named \"``stdout``\".\n\n When ``--mime-type`` or ``--stdout-filename`` is also given, this option has\n no effect other than to set the default value for ``--stderr-encoding``.\n\n- ``-E ``, ``--stderr-encoding `` \u2014 Expect the stderr of\n ```` to be in the given encoding; defaults to the value specified\n via ``--encoding`` or its default. If decoding fails, the stderr output will\n be attached to the e-mail as an ``application/octet-stream`` file named\n \"``stderr``\".\n\n This option only has an effect when ``--split`` is given, either implicitly\n or explicitly.\n\n- ``-f
``, ``--from
``, ``--from-addr
`` \u2014 Set the\n ``From:`` address of the e-mail. The address may be given in either the form\n \"``address@example.com``\" or \"``Real Name ``.\" If not\n specified, ``daemail`` will not set the ``From:`` header and will expect the\n mail command or SMTP server to do it instead.\n\n- ``--from-name `` \u2014 Deprecated; set the \"real name\" in the argument to\n ``--from-addr`` instead\n\n- ``-F``, ``--failure-only`` \u2014 Only send an e-mail if the command failed to run\n or exited with a nonzero status\n\n- ``-l ``, ``--logfile `` \u2014 If an unexpected & unhandleable\n fatal error occurs after daemonization, append a report to ````;\n defaults to ``daemail.log``\n\n - Such an error is a deficiency in the program; please report it!\n\n- ``-s ``, ``--sendmail `` \u2014 Send e-mail by passing the\n message on stdin to ```` (executed via the shell, in the directory\n specified with ``--chdir`` or its default); default command: ``sendmail -i\n -t``. This is the default if neither ``--mbox`` nor ``--smtp-host`` is\n specified.\n\n- ``--mbox `` \u2014 \"Send\" e-mail by appending it to the mbox file ````\n\n- ``-M ``, ``--mime-type ``, ``--mime `` \u2014\n Attach the standard output of ```` to the e-mail as an inline\n attachment with the given MIME type. The MIME type may include parameters,\n e.g., ``--mime-type \"text/html; charset=utf-16\"``. If ``--stdout-filename``\n is not also supplied, the attachment is named \"``stdout``\". Implies\n ``--split``.\n\n- ``-n``, ``--nonempty`` \u2014 Do not send an e-mail if the command exited\n successfully and both the command's stdout & stderr were empty or not\n captured\n\n- ``--no-stdout`` \u2014 Don't capture the command's stdout; implies ``--split``\n\n- ``--no-stderr`` \u2014 Don't capture the command's stderr; implies ``--split``\n\n- ``--smtp-host `` \u2014 Send e-mail via SMTP, connecting to the given host.\n ``--smtp-host`` may be accompanied by the following options:\n\n - ``--smtp-port `` \u2014 Connect to ```` on the given port; defaults\n to 25, or to 465 if ``--smtp-ssl`` is specified\n\n - ``--smtp-username `` \u2014 Authenticate to the SMTP server using the\n given username. If a username is supplied (either on the command line or\n in a netrc file) but no password is, ``daemail`` will prompt the user for\n the SMTP password before daemonizing.\n\n - ``--smtp-password `` \u2014 Authenticate to the SMTP server using the\n given password\n\n - ``--smtp-password-file `` \u2014 Authenticate to the SMTP server using the\n contents of the given file (after removing the final line ending) as the\n password\n\n - ``--netrc`` \u2014 Fetch the SMTP username and/or password from ``~/.netrc``.\n If ``--smtp-username`` specifies a different username for the host than is\n given in the netrc file, the netrc file is ignored.\n\n - ``--netrc-file `` \u2014 Like ``--netrc``, but use the given file instead\n of ``~/.netrc``\n\n - ``--smtp-ssl`` \u2014 Use the SMTPS protocol to communicate with the server\n\n - ``--smtp-starttls`` \u2014 Use the SMTP protocol with the STARTTLS extension to\n communicate with the server\n\n- ``-S``, ``--split`` \u2014 Capture the command's stdout and stderr separately\n rather than as a single stream\n\n- ``--stdout-filename `` \u2014 Attach the standard output of\n ```` to the e-mail as an inline attachment with the given filename.\n If ``--mime-type`` is not also supplied, the MIME type of the attachment is\n deduced from the file extension, falling back to ``application/octet-stream``\n for unknown extensions. Implies ``--split``.\n\n- ``-t
``, ``--to
``, ``--to-addr
`` \u2014 Set the\n recipient of the e-mail. The address may be given in either the form\n \"``address@example.com``\" or \"``Real Name ``.\"\n\n - This option is required. It may be given multiple times in order to\n specify multiple recipients.\n\n- ``--to-name `` \u2014 Deprecated; set the \"real name\" in the argument to\n ``--to-addr`` instead\n\n- ``-Z``, ``--utc`` \u2014 Show start & end times in UTC instead of local time\n\n\nCaveats\n=======\n- Input cannot be piped to the command, as standard input is closed when\n daemonizing. If you really need to pass data on standard input, run a shell,\n e.g.::\n\n daemail bash -c 'command < file'\n\n or::\n\n daemail bash -c 'command | other-command'\n\n\n.. |getpreferredencoding| replace:: ``locale.getpreferredencoding``\n.. _getpreferredencoding: https://docs.python.org/3/library/locale.html#locale.getpreferredencoding", "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/jwodder/daemail", "keywords": "daemon email e-mail mail smtp background output notifications", "license": "MIT", "maintainer": null, "maintainer_email": null, "name": "daemail", "package_url": "https://pypi.org/project/daemail/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/daemail/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/jwodder/daemail" }, "release_url": "https://pypi.org/project/daemail/0.5.0/", "requires_dist": null, "requires_python": null, "summary": "Daemonize a command and e-mail the results", "version": "0.5.0" }, "last_serial": 2621277, "releases": { "0.3.0": [ { "comment_text": "", "digests": { "md5": "8f55a291f8face7aa5f35593c478b0c6", "sha256": "2a96659ddafeffa6d24122943c9b92c484ffb43ad2368d354c065ee1fe75a553" }, "downloads": -1, "filename": "daemail-0.3.0-py2.py3-none-any.whl", "has_sig": true, "md5_digest": "8f55a291f8face7aa5f35593c478b0c6", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 14784, "upload_time": "2016-08-28T21:45:41", "url": "https://files.pythonhosted.org/packages/a7/b9/5274f8123454605b3c52fc0559031779f645205b475895a3d468c7c07948/daemail-0.3.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "1186856a2e6b98533ef767da03363c57", "sha256": "3ab66803cbfaa3079a5859810b1916d2afdc1a206ecd5c7f379aae4340edb927" }, "downloads": -1, "filename": "daemail-0.3.0.tar.gz", "has_sig": true, "md5_digest": "1186856a2e6b98533ef767da03363c57", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12559, "upload_time": "2016-08-28T21:45:43", "url": "https://files.pythonhosted.org/packages/b1/94/e389c208ecbd61febddfba89d1e395382357772534bbf80adb1f6f171283/daemail-0.3.0.tar.gz" } ], "0.4.0": [ { "comment_text": "", "digests": { "md5": "59103ed836abb7f8f0887b84a531962a", "sha256": "7c4832843062665ca8c77fbed8336c4f9084b55a89f24fa712bf678dc36982a6" }, "downloads": -1, "filename": "daemail-0.4.0-py2.py3-none-any.whl", "has_sig": true, "md5_digest": "59103ed836abb7f8f0887b84a531962a", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 16838, "upload_time": "2016-11-06T03:20:29", "url": "https://files.pythonhosted.org/packages/11/a3/fb5af7fabdd8ae6f9d22ee46810824c199dfaf8343e24b976da7b0f09142/daemail-0.4.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "b330e2ee3c5aa43f980b9c3d7a53bd39", "sha256": "a01ab6089834879fc42f901ae02cdeffe006d3f8ef4f6f09c635ab0875f6c08d" }, "downloads": -1, "filename": "daemail-0.4.0.tar.gz", "has_sig": true, "md5_digest": "b330e2ee3c5aa43f980b9c3d7a53bd39", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14691, "upload_time": "2016-11-06T03:20:32", "url": "https://files.pythonhosted.org/packages/c9/2d/4a1e81895a68cfbd4c3f71d864acedf6639035f951640d656425c24de1e1/daemail-0.4.0.tar.gz" } ], "0.5.0": [ { "comment_text": "", "digests": { "md5": "0fe47b666977b1a4f375ee4131077281", "sha256": "a5c240beee596c6ea6156d0d3bb813252dde57c2033bdf789c8a34827aae628f" }, "downloads": -1, "filename": "daemail-0.5.0-py2.py3-none-any.whl", "has_sig": true, "md5_digest": "0fe47b666977b1a4f375ee4131077281", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 17270, "upload_time": "2017-02-05T22:07:33", "url": "https://files.pythonhosted.org/packages/1d/c6/14e8f16810256ee1aa6a2ebd322d17b96af2f06b38e24fa65c7a0b215422/daemail-0.5.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "f29af1c265724241e57cc919b43e6ed4", "sha256": "15952faee3f306e429ba1aea4929aaf3abd5069f142f742d2b4bc79729bddd63" }, "downloads": -1, "filename": "daemail-0.5.0.tar.gz", "has_sig": true, "md5_digest": "f29af1c265724241e57cc919b43e6ed4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15074, "upload_time": "2017-02-05T22:07:26", "url": "https://files.pythonhosted.org/packages/18/f9/f9c88f9381b73fd979c0bb3b10264a2bad0a0953d8c5c989b0fa81c9d1e4/daemail-0.5.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "0fe47b666977b1a4f375ee4131077281", "sha256": "a5c240beee596c6ea6156d0d3bb813252dde57c2033bdf789c8a34827aae628f" }, "downloads": -1, "filename": "daemail-0.5.0-py2.py3-none-any.whl", "has_sig": true, "md5_digest": "0fe47b666977b1a4f375ee4131077281", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 17270, "upload_time": "2017-02-05T22:07:33", "url": "https://files.pythonhosted.org/packages/1d/c6/14e8f16810256ee1aa6a2ebd322d17b96af2f06b38e24fa65c7a0b215422/daemail-0.5.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "f29af1c265724241e57cc919b43e6ed4", "sha256": "15952faee3f306e429ba1aea4929aaf3abd5069f142f742d2b4bc79729bddd63" }, "downloads": -1, "filename": "daemail-0.5.0.tar.gz", "has_sig": true, "md5_digest": "f29af1c265724241e57cc919b43e6ed4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15074, "upload_time": "2017-02-05T22:07:26", "url": "https://files.pythonhosted.org/packages/18/f9/f9c88f9381b73fd979c0bb3b10264a2bad0a0953d8c5c989b0fa81c9d1e4/daemail-0.5.0.tar.gz" } ] }