{ "info": { "author": "Jasper Steegmans", "author_email": "jasper.steegmans.code@gmail.com", "bugtrack_url": null, "classifiers": [ "License :: OSI Approved :: Apache Software License", "Operating System :: OS Independent", "Programming Language :: Python :: 3" ], "description": "# Code 2 JSON\nA command line utility that can insert code into JSON files and extract code from JSON to insert into a source code file.\n\n## Features\n- Create your source code in a separate file and have them be automatically written to JSON with in source markup\n- Write all files in a directory and it's subdirectories to the json\n- Specify the extension of the source code files\n- Specify the delimiter of the identifiers in the source code used to indicate the marked up parts (useful if the language does not support the default delimiter (`//`)\n- Update the source code based on the source code in the JSON\n\n### Planned features\n- A safe mode that allows the user to check the made changes before committing to them\n\n\n## Requirements\n* Python 3: I use print functions in the Python 3 style and I just don't feel like support Python 2 especially since it won't be supported after 2020/01/01\n* (Optionally) Pip: The Python Package Installer can be used to easily install Code 2 JSON but this can also be done by hand\n\n## Installation\nThere are multiple ways to install Code 2 JSON:\n### Using pip and PyPi\nSimply run the following command\n```\npip install code2json\n```\n### Cloning the repository and installing with pip\n1. Clone the repository\n```\ngit clone https://gitlab.com/Deathray_II/code2json.git\n```\nof if you prefer to use SSH\n```\ngit clone git@gitlab.com:Deathray_II/code2json.git\n```\n2. go inside the git directory\n```\ncd code2json\n```\n3. run pip install on the setup file\n```\npip install .\n```\nor if you wish to install it for just your user\n```\npip install --user .\n```\n### Cloning the repository and manually installing (on Linux)\n1. Clone repository\n```\ngit clone https://gitlab.com/Deathray_II/code2json.git\n```\nof if you prefer to use SSH\n```\ngit clone git@gitlab.com:Deathray_II/code2json.git\n```\n2. Make accessible in your shell\nThere are two ways to do this either adding an alias or link it into your `/usr/bin` folder\n - Adding an alias:\n Got to your `~/.bashrc` or `~/.zshrc` and add the line `alisas code2json=/path/to/cmd.py \"$@\"`, where `/path/to/cmd.py` is the path to the `cmd.py` file in the `src/code2json/` folder in the repository.\n - linking it into your `/usr/bin`: run (as a user who has access to write in `/usr/bin`) the command `ln -s /path/to/cmd.py /usr/bin/code2json`, where `/path/to/cmd.py` is the path to the `cmd.py` file in the `src/code2json/` folder in the repository.\n\n## Usage\n\nIf you have cloned the repository you can have a look at the test files and try some of the command on them so you get an idea of how it works\n\n### Code to JSON\nIf we wish to write all the code from a file (`apples.c`) to the corresponding JSON file we would execute the the following command from the folder that contains our source file\n```\ncode2json ./apples.c .c 2json\n```\nIf we wish to write all the .js file underneath the current directory to their JSON file we would run the following command.\n```\ncode2json . .js 2json\n```\n\n### JSON to code\n\n```\ncode2json ./apples.c .c 2code\n```\n\n```\ncode2json . .js 2json\n```\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://gitlab.com/Deathray_II/code2json", "keywords": "", "license": "Apache-2.0", "maintainer": "", "maintainer_email": "", "name": "code2json", "package_url": "https://pypi.org/project/code2json/", "platform": "", "project_url": "https://pypi.org/project/code2json/", "project_urls": { "Homepage": "https://gitlab.com/Deathray_II/code2json" }, "release_url": "https://pypi.org/project/code2json/0.1.0/", "requires_dist": null, "requires_python": ">=3", "summary": "A tool to easily automatically write all your source code to a JSON file and the other way around", "version": "0.1.0" }, "last_serial": 5596897, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "05b53ac38b417bc6fc401b4b513c972a", "sha256": "03f22d11904c0fdd92fa1e0deec9ec28a7f1e5a573499187a43d94c7c6cfeee6" }, "downloads": -1, "filename": "code2json-0.1.0-py3-none-any.whl", "has_sig": false, "md5_digest": "05b53ac38b417bc6fc401b4b513c972a", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3", "size": 13599, "upload_time": "2019-07-28T22:11:06", "url": "https://files.pythonhosted.org/packages/61/91/c8e08f3eb3b142e473e8e6f6f050102ea9bc45dbaf201027ad2e84710571/code2json-0.1.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "bb4814e02aa16cafa6cbf5a54ec18213", "sha256": "72ff8dfa7776261346d6464d87e58a9e33abb6b1e6982e4b880fe2eb393793e3" }, "downloads": -1, "filename": "code2json-0.1.0.tar.gz", "has_sig": false, "md5_digest": "bb4814e02aa16cafa6cbf5a54ec18213", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3", "size": 9722, "upload_time": "2019-07-28T22:11:09", "url": "https://files.pythonhosted.org/packages/d6/42/a5b0deb055371b63ac261bb88e06ef88fa61d85cb6be852d7f86d9fbb861/code2json-0.1.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "05b53ac38b417bc6fc401b4b513c972a", "sha256": "03f22d11904c0fdd92fa1e0deec9ec28a7f1e5a573499187a43d94c7c6cfeee6" }, "downloads": -1, "filename": "code2json-0.1.0-py3-none-any.whl", "has_sig": false, "md5_digest": "05b53ac38b417bc6fc401b4b513c972a", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3", "size": 13599, "upload_time": "2019-07-28T22:11:06", "url": "https://files.pythonhosted.org/packages/61/91/c8e08f3eb3b142e473e8e6f6f050102ea9bc45dbaf201027ad2e84710571/code2json-0.1.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "bb4814e02aa16cafa6cbf5a54ec18213", "sha256": "72ff8dfa7776261346d6464d87e58a9e33abb6b1e6982e4b880fe2eb393793e3" }, "downloads": -1, "filename": "code2json-0.1.0.tar.gz", "has_sig": false, "md5_digest": "bb4814e02aa16cafa6cbf5a54ec18213", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3", "size": 9722, "upload_time": "2019-07-28T22:11:09", "url": "https://files.pythonhosted.org/packages/d6/42/a5b0deb055371b63ac261bb88e06ef88fa61d85cb6be852d7f86d9fbb861/code2json-0.1.0.tar.gz" } ] }