Difference between revisions of "Silme:Tutorial:Setting up environment"
Jump to navigation
Jump to search
Zbraniecki (talk | contribs) |
Zbraniecki (talk | contribs) |
||
Line 6: | Line 6: | ||
You need Python 2.5. Nothing more. | You need Python 2.5. Nothing more. | ||
− | For serveral | + | For serveral IOClients and FormatParsers you will need additional modules like MySQLdb for MySQL, pysqlite for SQLite, pysvn for SVN etc. |
=== Linux and MacOS === | === Linux and MacOS === | ||
<pre> | <pre> | ||
− | + | hg clone http://hg.mozilla.org/users/zbraniecki_mozilla.com/silme | |
</pre> | </pre> | ||
Line 19: | Line 19: | ||
sys.path.append('./lib') | sys.path.append('./lib') | ||
− | from | + | from silme.core import Entity |
def test(): | def test(): | ||
Line 28: | Line 28: | ||
</code> | </code> | ||
− | You can also checkout from | + | You can also checkout from HG ./silme/scripts to see examples. (launch from the directory above ./scripts, like: ./scripts/test.py) |
=== Windows === | === Windows === | ||
Not sure... didn't try... should require nothing more than Python. | Not sure... didn't try... should require nothing more than Python. |
Revision as of 11:09, 13 February 2009
Overview
This section explains how to set up an environment to work with silme.
Requirements
You need Python 2.5. Nothing more. For serveral IOClients and FormatParsers you will need additional modules like MySQLdb for MySQL, pysqlite for SQLite, pysvn for SVN etc.
Linux and MacOS
hg clone http://hg.mozilla.org/users/zbraniecki_mozilla.com/silme
And then you can write first example.py:
- !/usr/bin/python
sys.path.append('./lib')
from silme.core import Entity
def test():
entity = Entity('id, 'value')
if __name__ == "__main__":
test()
You can also checkout from HG ./silme/scripts to see examples. (launch from the directory above ./scripts, like: ./scripts/test.py)
Windows
Not sure... didn't try... should require nothing more than Python.