← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #688984]: IDE: imported helper files are not automatically reimported if changed

 

Question #688984 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/688984

SeltiX posted a new comment:
ok I think I found how to do it, with the help of this info :
http://doc.sikuli.org/globals.html

for others who may search for this, my setup to have the images in a
dedicated folder with sikulix-2.0.3.jar is :

├── myapp.sikuli/
│   ├── myapp.py
│   ├── helpers.sikuli/
│   │   ├── helpers.py
│   ├── images.sikuli/
│   │   ├── images.py
│   │   ├── all my image files....


>>> myapp.py :

import os

myPath = os.path.dirname(getBundlePath())
if not "helpers" in sys.path: sys.path.append("helpers")
if not "images" in sys.path: sys.path.append("images")

import helpers
import images

reload(helpers)
reload(images)
...

>>> helpers.py and images.py
from sikuli import *
...


im I doing it correctly?
Thanks!

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.