1 file was added to this release more than 14 days after its initial publication. Inspect the release files before installing.
SublimeCodeIntel configuration recipe for buildout
==================================================
This recipe generates a configuration file for SublimeCodeIntel_, a SublimeText_ plugin .
To use it, add a codeintel configuration section to your ``buildout.cfg`` file and the corresponding part::
[buildout]
parts =
django
codeintel
...
[codeintel]
recipe = corneti.recipes.codeintel
eggs = ${django:eggs}
extra-paths =
${django:location}
${django:extra-paths}
Setting .codeintel folder
===========================
SublimeCodeIntel will pick up auto-completion information from ``.codeintel``
folder from your Sublime Text project root.
By default, this recipe generates the folder in the buildout root.
You can specify optional ``codeintel-path`` if you want to generate
``.codeintel`` in some other location.
Example how to create CodeIntel information inside ``src/`` folder.
Usually ``src/`` is used for all Python eggs you are currently developing yourself i.e.
essentially all of your project codebase::
[codeintel]
recipe = corneti.recipes.codeintel
eggs = ${instance:eggs}
codeintel-path = ${buildout:directory}/src/.codeintel
This will generate file ``src/.codeintel/config`` which will list all your eggs
used by ``[instance]`` in your *buildout.cfg*.
Now you can open your ``src/`` folder as project in Sublime with perfect auto-completion support::
subl src
... or just open src/ folder using *File > Open folder*.
(`See how to configure Sublime Text 2 commaline commands <http://opensourcehacker.com/2012/05/11/sublime-text-2-tips-for-python-and-web-developers/>`_)
We'll start by creating a buildout that uses the recipe::
We form a config which uses paths for every language supported::
>>> from corneti.recipes.codeintel import CodeintelRecipe
>>> extra_info = "\n".join(map(lambda x: r"""
... {0}-path = /some/bin/{0}
... {0}-extra-paths = /some/{0}/path
... /some/{0}/path2
... """.format(x.lower()), CodeintelRecipe.SUPPORTED_LANGUAGES))
>>> write('buildout.cfg',
... r"""
... [buildout]
... parts = codeintel
... newest = false
...
... [codeintel]
... recipe = corneti.recipes.codeintel
... eggs = zc.buildout
... {0}
... """.format(extra_info))
Running the buildout gives us::
>>> print system(buildout)
Installing codeintel.
We see the folder with codeintel config is created::
>>> print ls('.')
d .codeintel
...
>>> print ls('./.codeintel')
- config
...
We check the contents of the config::
>>> import os
>>> import simplejson
>>> import pprint
>>> contents = open(os.path.join('.codeintel', 'config')).read()
>>> contents_json = simplejson.loads(contents)
>>> '/some/python/path' in contents_json['Python']['pythonExtraPaths']
True
>>> '/some/python/path2' in contents_json['Python']['pythonExtraPaths']
True
>>> len(contents_json['Python']['pythonExtraPaths'])
4
We check that every lang is present in config::
>>> contents_json.keys() == CodeintelRecipe.SUPPORTED_LANGUAGES
True
Let's check the usage with only one additional language::
>>> write('buildout.cfg',
... r"""
... [buildout]
... parts = codeintel
... newest = false
...
... [codeintel]
... recipe = corneti.recipes.codeintel
... eggs = zc.buildout
... javascript-extra-paths = /some
... """)
>>> print system(buildout)
Uninstalling codeintel.
Installing codeintel.
>>> contents = open(os.path.join('.codeintel', 'config')).read()
>>> contents_json = simplejson.loads(contents)
>>> len(contents_json) == 2
True
>>> contents_json['JavaScript']
{'javascriptExtraPaths': ['/some']}
Tips
=======
Reset auto-completion by choosing *SublimeCodeIntel: Reset* in command browser (CMD + SHIFT + P) [OSX].
Force auto-completion dialog: CMD + P [OSX].
Testing
=======
To test this recipe, bootstrap the included buildout, build it and execute the test section::
$ python bootstrap.py
$ bin/buildout -v
$ bin/buildout test
If the first command gives you a setuptools dependency error, try the following variant to use distribute::
$ python bootstrap.py -d
$ bin/buildout -v
$ bin/buildout test
Credits
=======
Based on the ``mkcodeintel`` script available in optilude's SublimeTextMisc_ repository.
``codeintel-path`` option and much better documentation by Mikko Ohtamaa .
Support for executable path and extra paths for all languages which Codeintel supports by Anatoly Bubenkov .
.. _SublimeCodeIntel: https://github.com/Kronuz/SublimeCodeIntel
.. _SublimeText: http://www.sublimetext.com/2
.. _SublimeTextMisc: https://github.com/optilude/SublimeTextMisc
Metadata
Release files for corneti.recipes.codeintel 0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
File added late
1 file was uploaded more than 14 days after the first file in this release.
While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.
We recommend inspecting the release files before installing.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| corneti.recipes.codeintel-0.3.tar.gz | 6.2 kB | Without provenance | Details for corneti.recipes.codeintel-0.3.tar.gz |
Release files / corneti.recipes.codeintel-0.3.tar.gz
File added late
This file was uploaded more than 14 days after the first file in this release.
While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.
We recommend inspecting the release file before installing.
| Download URL | corneti.recipes.codeintel-0.3.tar.gz |
|---|---|
| Size | 6.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
26f283af208cc480a7bb4d89fa1198d1f8ebe2afb06b3020ed20c299f4084193
|
|
BLAKE2b-256 checksum How to use checksums |
3560fdc6dbc319438900746702a6111e0e2c72344c8d7a0bac30d2f350779b0f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for corneti.recipes.codeintel 0.3
Upload timing
File added late
1 file was uploaded more than 14 days after the first file in this release.
While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.