Welcome, guest | Sign In | My Account | Store | Cart

Notice! PyPM is being replaced with the ActiveState Platform, which enhances PyPM’s build and deploy capabilities. Create your free Platform account to download ActivePython or customize Python with the packages you require and get automatic updates.

Download
ActivePython
INSTALL>
pypm install largeblue.tag

How to install largeblue.tag

  1. Download and install ActivePython
  2. Open Command Prompt
  3. Type pypm install largeblue.tag
 Python 2.7Python 3.2Python 3.3
Windows (32-bit)
0.1.1 Available View build log
Windows (64-bit)
0.1.1 Available View build log
Mac OS X (10.5+)
0.1.1 Available View build log
Linux (32-bit)
0.1.1 Available View build log
Linux (64-bit)
0.1.1 Available View build log
 
Author
License
Public Domain
Lastest release
version 0.1.1 on Jan 5th, 2011

largeblue.tag provides an uber simple tagging adapter. If included:

<include package="largeblue.tag" />

It will adapt any object configured to implement largeblue.tag.interfaces.ITaggable, e.g:

<class class=".objects.MyContentObject">
<implements interface="largeblue.tag.interfaces.ITaggable" />

System Message: ERROR/3 (<string>, line 10)

Inconsistent literal block quoting.

... </class>

This will hang a @@tags.html view of each instance of the adapted content object, which provides a single textline input to enter tags (seperated by a space). Thus if you enter 'foo bar dolores' into the text input and submit, you'll find:

>>> context = my_obj
>>> from largeblue.tag.interfaces import ITag
>>> t = ITag(context)
>>> t.tags

System Message: ERROR/3 (<string>, line 21)

Inconsistent literal block quoting.

['foo', 'bar', 'dolores'] >>> t.tagstring u'foo bar dolores'

You can add, remove and update:

>>> t.add_tag('elephants')
>>> t.tags

System Message: ERROR/3 (<string>, line 29)

Inconsistent literal block quoting.

['foo', 'bar', 'dolores', 'elephants'] >>> t.remove_tag('dolores') >>> t.tags ['foo', 'bar', 'elephants'] >>> t.update_tags(['coffee', 'milk']) >>> t.tags ['coffee', 'milk']

That's it.

Subscribe to package updates

Last updated Jan 5th, 2011

Download Stats

Last month:1

What does the lock icon mean?

Builds marked with a lock icon are only available via PyPM to users with a current ActivePython Business Edition subscription.

Need custom builds or support?

ActivePython Enterprise Edition guarantees priority access to technical support, indemnification, expert consulting and quality-assured language builds.

Plan on re-distributing ActivePython?

Get re-distribution rights and eliminate legal risks with ActivePython OEM Edition.