{ "info": { "author": "Filip Krikava", "author_email": "krikava@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Environment :: Console", "License :: OSI Approved :: MIT License", "Operating System :: MacOS :: MacOS X", "Programming Language :: Python :: 2.7", "Topic :: Utilities" ], "description": "OmniGraffle Export tool\n=======================\n\nA command line tool that allows to export one or more canvases from [OmniGraffle](http://www.omnigroup.com/products/omnigraffle/) into various formats using [OmniGraffle AppleScript interface](http://www.omnigroup.com/mailman/archive/omnigraffle-users/2008/004785.html).\n\nInstallation\n------------\n\nIn order to have it successfully installed and working, following is required:\n\n- [OmniGraffle](http://www.omnigroup.com/mailman/archive/omnigraffle-users/2008/004785.html) 5 or 6\n- python \\>= 2.7\n- [appscript](http://appscript.sourceforge.net/py-appscript/index.html) \\>= 0.22\n\nYou can either clone the repository and use the setup tool:\n\n setup.py install\n\nOr using the PIP:\n\n pip install omnigraffle_export\n\nUsage\n-----\n\n Usage: omnigraffle-export [options] \n\n Options:\n -h, --help show this help message and exit\n -c NAME canvas name. If not given it will be guessed from the target\n filename unless it is a directory.\n -f FMT format (one of: pdf, png, svg, eps). Guessed from the target\n filename suffix unless it is a directory. Defaults to pdf\n --force force the export\n --debug print out debug messages\n\nIf the target file exists it tries to determine whether the canvas has been changed. It does that by comparing the checkums. Since the PDF export always results into a different file, it uses the PDF subject attribute to store there a checksum that will be generated by exporting to a PNG format.\n\nExamples\n--------\n\n- Export *all* canvases into directory *figures* using EPS\n\n ```sh\n $ omnigraffle-export -f eps schemas.graffle figures\n ```\n \n- Export canvas named *FullModel* into a *FullModel.svg* SVG file:\n\n ```\n $ omnigraffle-export schemas.graffle FullModel.svg\n ```\n \n- Export canvas name *FullModel* into a *my\\_new\\_model.pdf* PDF file:\n \n ```sh\n $ omnigraffle-export -c FullModel -f pdf schemas.graffle my_new_model\n ```\n \n or\n \n ```sh\n $ omnigraffle-export -c FullModel schemas.graffle my_new_model.pdf\n ```\n \n *Note: that the \u2019.pdf\u2019 suffix will be automatically added in the first case.*\n\n- Export *all* canvases into directory *figures* using EPS\n \n ```\n $ omnigraffle-export -f eps schemas.graffle figures\n ```\n\nLaTeX Support Example\n---------------------\n\nOne of the main motivation for this package was to be able to quickly export OmniGraffle canvases and use them in LaTeX. One of the possible setup is following: every time a figure is included add some instruction so it can be later exported from OmniGraffle file. For example using a comment like:\n\n```\n% omnigraffle sources/schemas.graffle figures/CondorKernel.pdf\n```\n\nto export a canvas `CondorKernel` from `sources/schemas.graffle` into `figures/CondorKernel.pdf` as `PDF`.\n\n```latex\n\\begin{figure}\n \\center\n % omnigraflle: sources/schemas.graffle figures/CondorKernel.pdf\n \\includegraphics[scale=.5]{images/CondorKernel}\n\\end{figure}\n```\n\nAn example preprocesor in Python using [frabric](http://docs.fabfile.org/en/1).\n\n```python\nfrom fabric.api import *\nimport re\n\n# latex files to process\nfnames = ['UCGridRLDecisionModel.tex']\nomnigraffle_re = re.compile(r'%\\s*omnigraflle:\\s*([^ ]+)\\s+([^ ]+)')\n\ndef _convert(source, target):\n local('omnigraffle-export %s %s' % (source, target))\n\n@task\ndef schemas():\n '''\n Generate all schemas\n '''\n\n for fname in fnames:\n with open(fname) as f:\n for l in f:\n m = omnigraffle_re.match(l.strip())\n if m:\n _convert(*m.groups())\n```\n\nExport on Demand\n----------------\n\nThe `omnigraffle-export` can be used either in a batch mode or in a more interactive way. For example it can be used to export the currently selected canvas into a file.\n\nFollowing is an example Python script that will export currently active canvas into a PDF file that has the same name as the canvas and is placed in the same directory as the OmniGraffle document:\n\n```python\n#!/usr/bin/env python\n\nimport os\nimport sys\nimport omnigraffle\n\nog = omnigraffle.OmniGraffle()\nschema = og.active_document()\n\nschema_path = schema.path\nschema_fname = os.path.basename(schema_path)\nschema_dir = os.path.dirname(schema_path)\nexport_info_fname = os.path.join(schema_dir, '.' + schema_fname[0:schema_fname.rindex('.')] + '.omnigraffle_export')\n\ncanvas_name = schema.active_canvas_name()\n\nformat = 'pdf'\ntarget_path = os.path.join(schema_dir, canavs_name + '.' + format)\n\nschema.export(canvas_name, target_path, format=format)\n```\n\nFancier version can be download [here](https://gist.github.com/4195669).\n\nMaking a release\n----------------\n\n- update the version number in `setup.py`\n- rerun tests `$ python setup.py test`\n- commit\n- push\n- register release `$ python setup.py register`\n- upload release `$ python setup.py bdist upload`\n\nDeveloping omnigraffle-export\n-----------------------------\n\n- clone\n- stage `$ python setup.py develop`\n- make a new feature branch\n- code\n- do release\n- unstage `$python setup.py develop --uninstall`", "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/fikovnik/omnigraffle-export", "keywords": "omnigraffle export", "license": "http://www.opensource.org/licenses/mit-license.php", "maintainer": null, "maintainer_email": null, "name": "omnigraffle-export", "package_url": "https://pypi.org/project/omnigraffle-export/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/omnigraffle-export/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/fikovnik/omnigraffle-export" }, "release_url": "https://pypi.org/project/omnigraffle-export/1.7.1/", "requires_dist": null, "requires_python": null, "summary": "A command line utility that exports omnigraffle canvases files into various formats.", "version": "1.7.1" }, "last_serial": 1462662, "releases": { "1.0": [], "1.1": [ { "comment_text": "built for Darwin-10.7.0", "digests": { "md5": "3d5101310084b782d1587065bde82618", "sha256": "ea97c1a96e7738ceff9976b4a64182b339a4a7d9e57b66db200ae4c3564311f1" }, "downloads": -1, "filename": "omnigraffle-export-1.1.macosx-10.6-x86_64.tar.gz", "has_sig": false, "md5_digest": "3d5101310084b782d1587065bde82618", "packagetype": "bdist_dumb", "python_version": "any", "requires_python": null, "size": 11366, "upload_time": "2011-06-07T12:04:58", "url": "https://files.pythonhosted.org/packages/a0/8e/a03077bfe4786d6658cf48ce39a2635d6d4f0aecbfa23451160f2478f32f/omnigraffle-export-1.1.macosx-10.6-x86_64.tar.gz" } ], "1.2": [ { "comment_text": "built for Darwin-10.7.0", "digests": { "md5": "cc2270e01af1aa4bd7cae2505f7fd2af", "sha256": "89d0543291c950a5427ad4c1814194eef85e7f9cc2b7a01cda022dbb4e732f33" }, "downloads": -1, "filename": "omnigraffle-export-1.2.macosx-10.6-x86_64.tar.gz", "has_sig": false, "md5_digest": "cc2270e01af1aa4bd7cae2505f7fd2af", "packagetype": "bdist_dumb", "python_version": "any", "requires_python": null, "size": 11360, "upload_time": "2011-06-07T12:06:09", "url": "https://files.pythonhosted.org/packages/fc/a3/b6bd7043f64fcac5dd46a2d746fffaf026b56f2426c310915d744131a999/omnigraffle-export-1.2.macosx-10.6-x86_64.tar.gz" } ], "1.3": [], "1.3.1": [], "1.4.0": [ { "comment_text": "built for Darwin-11.3.0", "digests": { "md5": "81d50bcd07d5d8fdbe8d2976be520ff5", "sha256": "23933ed823a049e41efa1db607fc7fb08779b6c96378cfa51fd2d772400af73c" }, "downloads": -1, "filename": "omnigraffle-export-1.4.0.macosx-10.7-intel.tar.gz", "has_sig": false, "md5_digest": "81d50bcd07d5d8fdbe8d2976be520ff5", "packagetype": "bdist_dumb", "python_version": "any", "requires_python": null, "size": 11962, "upload_time": "2012-02-14T13:30:48", "url": "https://files.pythonhosted.org/packages/d9/8a/7cf72da722812aa3a9026ea79d0774a49250739b7e08358ab299db2b4fb2/omnigraffle-export-1.4.0.macosx-10.7-intel.tar.gz" } ], "1.4.1": [ { "comment_text": "built for Darwin-11.3.0", "digests": { "md5": "efee3700bc716152a3fa4f7a846b5c28", "sha256": "3aa1034982db627d028324491904b549c2a4e86a8875e882f5421683bc768d83" }, "downloads": -1, "filename": "omnigraffle-export-1.4.1.macosx-10.7-intel.tar.gz", "has_sig": false, "md5_digest": "efee3700bc716152a3fa4f7a846b5c28", "packagetype": "bdist_dumb", "python_version": "any", "requires_python": null, "size": 11967, "upload_time": "2012-02-14T13:32:29", "url": "https://files.pythonhosted.org/packages/b6/84/69a23fe23c167a1e6d176de70b5929c7182b9adb35b4c68c40b2e1054f6e/omnigraffle-export-1.4.1.macosx-10.7-intel.tar.gz" } ], "1.4.2": [ { "comment_text": "built for Darwin-11.3.0", "digests": { "md5": "cee5cbb412ca9d76b00cf1e66d3639e2", "sha256": "9be4142d8d50abf350ef182c0cf12e922178d89656e02eda30cf6d5a149fa5a5" }, "downloads": -1, "filename": "omnigraffle-export-1.4.2.macosx-10.7-intel.tar.gz", "has_sig": false, "md5_digest": "cee5cbb412ca9d76b00cf1e66d3639e2", "packagetype": "bdist_dumb", "python_version": "any", "requires_python": null, "size": 12052, "upload_time": "2012-02-14T14:15:05", "url": "https://files.pythonhosted.org/packages/77/d4/99bc2b702546a3a53b9d0c41e782430f45061c25ebadeebd60c944bb86a5/omnigraffle-export-1.4.2.macosx-10.7-intel.tar.gz" } ], "1.5": [ { "comment_text": "built for Darwin-11.4.2", "digests": { "md5": "5575c8855c48afd1bd0f0c834222ada1", "sha256": "c44167b72bc0ac7251b59b206189008d4024b6d1ae7546ef82b847990177f05d" }, "downloads": -1, "filename": "omnigraffle-export-1.5.macosx-10.7-intel.tar.gz", "has_sig": false, "md5_digest": "5575c8855c48afd1bd0f0c834222ada1", "packagetype": "bdist_dumb", "python_version": "any", "requires_python": null, "size": 12474, "upload_time": "2012-12-03T15:30:30", "url": "https://files.pythonhosted.org/packages/f8/dd/850f4486611756d6afed742bf37ee00f709d9961b12e9dedbf87e41bbfd9/omnigraffle-export-1.5.macosx-10.7-intel.tar.gz" } ], "1.5.1": [ { "comment_text": "built for Darwin-11.4.2", "digests": { "md5": "741a2e438b95477965fccc1a08c3fd8e", "sha256": "fe291b4c233c516f25c444b12658f6050d6b4572d08d5a83168950d1561577de" }, "downloads": -1, "filename": "omnigraffle-export-1.5.1.macosx-10.7-intel.tar.gz", "has_sig": false, "md5_digest": "741a2e438b95477965fccc1a08c3fd8e", "packagetype": "bdist_dumb", "python_version": "any", "requires_python": null, "size": 13431, "upload_time": "2013-01-03T10:44:22", "url": "https://files.pythonhosted.org/packages/81/16/5ef46569717f2e595dd8464ae0953eb8369403b039e2fa099c71cf0c4d37/omnigraffle-export-1.5.1.macosx-10.7-intel.tar.gz" }, { "comment_text": "built for Darwin-13.0.2", "digests": { "md5": "4ea9235caaa1a78cde610822a2130242", "sha256": "4a3179fd52a3ffba6ef0963dc3806ecdfb37a832b6a4a421b055ea74eda72bd1" }, "downloads": -1, "filename": "omnigraffle-export-1.5.1.macosx-10.9-x86_64.tar.gz", "has_sig": false, "md5_digest": "4ea9235caaa1a78cde610822a2130242", "packagetype": "bdist_dumb", "python_version": "any", "requires_python": null, "size": 11446, "upload_time": "2014-01-15T14:52:11", "url": "https://files.pythonhosted.org/packages/76/ab/64683efa7c38321898d4a8585c5fe3c294d6c806e8defd70db906c104f08/omnigraffle-export-1.5.1.macosx-10.9-x86_64.tar.gz" } ], "1.6": [ { "comment_text": "built for Darwin-13.1.0", "digests": { "md5": "c3a103dee896daeff2ab7ff371acfdbd", "sha256": "a61bc2ac37221d5027185b4996c4a6b7a479de41d5f163009bf3fe64b414ecc0" }, "downloads": -1, "filename": "omnigraffle-export-1.6.macosx-10.9-x86_64.tar.gz", "has_sig": false, "md5_digest": "c3a103dee896daeff2ab7ff371acfdbd", "packagetype": "bdist_dumb", "python_version": "any", "requires_python": null, "size": 12237, "upload_time": "2014-03-03T10:05:54", "url": "https://files.pythonhosted.org/packages/d3/e3/24501f5458f73050865895a3e8dd39538be25666b5a4a4c44902a779f81f/omnigraffle-export-1.6.macosx-10.9-x86_64.tar.gz" }, { "comment_text": "", "digests": { "md5": "ebc795a35dc16733227f3ac997b4bbee", "sha256": "312103c4f7820be3048cf567a7057c91b114d89358e474154f9e6a10981188a7" }, "downloads": -1, "filename": "omnigraffle-export-1.6.tar.gz", "has_sig": false, "md5_digest": "ebc795a35dc16733227f3ac997b4bbee", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7205, "upload_time": "2014-01-15T15:38:30", "url": "https://files.pythonhosted.org/packages/76/10/bcea190b30082f6392ebba2177ef3f26c26421cbdf86182e968d0d2c5287/omnigraffle-export-1.6.tar.gz" } ], "1.7": [ { "comment_text": "built for Darwin-14.1.0", "digests": { "md5": "fc05a9bd479f3cc912e9a2ea7f1d9234", "sha256": "d0e1cfc2bfdcb66492cda903af7b21bbe9557b9fd0689ebc7cecc29911704422" }, "downloads": -1, "filename": "omnigraffle-export-1.7.macosx-10.10-x86_64.tar.gz", "has_sig": false, "md5_digest": "fc05a9bd479f3cc912e9a2ea7f1d9234", "packagetype": "bdist_dumb", "python_version": "any", "requires_python": null, "size": 12270, "upload_time": "2015-03-12T12:11:52", "url": "https://files.pythonhosted.org/packages/2a/90/928af8262f33310734c885436b80374c80acdea4e80b9efd83b21528d358/omnigraffle-export-1.7.macosx-10.10-x86_64.tar.gz" } ], "1.7.1": [ { "comment_text": "built for Darwin-14.1.0", "digests": { "md5": "ad4e53c3416df48231f6410bd98ccb7c", "sha256": "6cf52573b793a8f4d220b171ebd27e1e745895b7cde0f6309cd24f13196657f5" }, "downloads": -1, "filename": "omnigraffle-export-1.7.1.macosx-10.10-x86_64.tar.gz", "has_sig": false, "md5_digest": "ad4e53c3416df48231f6410bd98ccb7c", "packagetype": "bdist_dumb", "python_version": "any", "requires_python": null, "size": 13113, "upload_time": "2015-03-16T12:37:33", "url": "https://files.pythonhosted.org/packages/7b/25/b643d32a98ec3d2e059ca168219a6b75a8c4f07c937fa05bf07f4ac10146/omnigraffle-export-1.7.1.macosx-10.10-x86_64.tar.gz" } ] }, "urls": [ { "comment_text": "built for Darwin-14.1.0", "digests": { "md5": "ad4e53c3416df48231f6410bd98ccb7c", "sha256": "6cf52573b793a8f4d220b171ebd27e1e745895b7cde0f6309cd24f13196657f5" }, "downloads": -1, "filename": "omnigraffle-export-1.7.1.macosx-10.10-x86_64.tar.gz", "has_sig": false, "md5_digest": "ad4e53c3416df48231f6410bd98ccb7c", "packagetype": "bdist_dumb", "python_version": "any", "requires_python": null, "size": 13113, "upload_time": "2015-03-16T12:37:33", "url": "https://files.pythonhosted.org/packages/7b/25/b643d32a98ec3d2e059ca168219a6b75a8c4f07c937fa05bf07f4ac10146/omnigraffle-export-1.7.1.macosx-10.10-x86_64.tar.gz" } ] }