Skip to content

Commit

Permalink
modified to work for Python 3, added CHANGES.txt
Browse files Browse the repository at this point in the history
  • Loading branch information
paul-wolf committed Jan 4, 2014
1 parent 38047b6 commit 8e780a0
Show file tree
Hide file tree
Showing 6 changed files with 439 additions and 34 deletions.
5 changes: 5 additions & 0 deletions CHANGES.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@

Changes from version 0.1.1 to 1.1.2
------------------------------------
- fixed to work with Python 3 and 2.7

14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,24 +20,24 @@ will generate something like the following:
Constructor
-----------

import StringGenerator from strgen
StringGenerator(<template>)
from strgen import StringGenerator
sg = StringGenerator(<template>)

Usage:

import StringGenerator from strgen
from strgen import StringGenerator
StringGenerator(<template>).render()

or:

import StringGenerator from strgen
from strgen import StringGenerator
StringGenerator(<template>).render_list(10,unique=True)

The latter produces a list of 10 strings that are unique within the list.

Example:

>>> import StringGenerator from strgen
>>> from strgen import StringGenerator
>>> StringGenerator('[\l\d]{4:18}&[\d]&[\p]').render()
u'Cde90uC{X6lWbOueT'

Expand All @@ -58,7 +58,7 @@ Example:

abc

Special characters need to be escaped with backslash `\\`.
Special characters need to be escaped with backslash `\`.


Character class: [\<class specification>]
Expand Down Expand Up @@ -172,7 +172,7 @@ Special Characters, Escaping and Errors

There are fewer special characters than regular expressions:

[](){}|&-
[](){}|&-$

They can be used as literals by escaping with backslash. All other
characters are treated as literals. The hyphen is only special in a
Expand Down
Loading

0 comments on commit 8e780a0

Please sign in to comment.