Commits

nitrogenycs  committed f6cfe3c

- fixed relative imports
- added pyflakes to buildout
- make pep8 and pyflakes happy

  • Participants
  • Parent commits bc1201e

Comments (0)

Files changed (7)

File buildout.cfg

 [buildout]
 develop = .
-parts = py.test
+parts = py.test pyflakes
 
 [py.test]
 recipe = z3c.recipe.scripts
   if __name__ == '__main__': sys.exit(pytest.main())
 eggs = js.extjs
        pytest
+
+
+[pyflakes]
+recipe = z3c.recipe.scripts
+eggs = pyflakes
+entry-points = pyflakes=pkg_resources:run_script
+arguments = 'pyflakes', 'pyflakes'
+scripts = pyflakes

File js/__init__.py

-__import__('pkg_resources').declare_namespace(__name__)
+__import__('pkg_resources').declare_namespace(__name__)

File js/extjs/__init__.py

-import library
-import adapter
-import extjs
-import theme
-import ux
+from js.extjs import library, adapter, extjs, theme, ux
 
 # convenience
 from extjs import basic

File js/extjs/adapter.py

 from fanstatic import Resource
-from library import library
+from js.extjs.library import library
 
 ext = Resource(library, 'adapter/ext/ext-base.js',
-                debug='adapter/ext/ext-base-debug.js')
+                debug='adapter/ext/ext-base-debug.js')

File js/extjs/extjs.py

 from fanstatic import Resource, GroupResource
-import adapter
-from library import library
+from js.extjs import adapter
+from js.extjs.library import library
 
 js = Resource(library, 'ext-all.js', depends=[adapter.ext],
               debug='ext-all-debug-w-comments.js')
 
 css = Resource(library, 'resources/css/ext-all.css')
 
-basic = all = GroupResource( [adapter.ext, js, css] )
+basic = all = GroupResource([adapter.ext, js, css])

File js/extjs/theme.py

 from fanstatic import Resource
-from library import library
-import extjs
+from js.extjs.library import library
+from js.extjs import extjs
 
-defaultThemes = [ 'gray', 'access' ]   # what about vista?
+defaultThemes = ['gray', 'access']   # what about vista?
 themes = {}
 
+
 def add_theme(themeName):
     css = Resource(library, 'resources/css/xtheme-%s.css' % themeName,
-                   depends = [extjs.css] )
+                   depends=[extjs.css])
 
     global themes
     themes[themeName] = globals()[themeName] = css
 
 for themeName in defaultThemes:
     add_theme(themeName)
-    

File js/extjs/ux.py

 from library import library
 from fanstatic import Resource, GroupResource
-import extjs
+from js.extjs import extjs
 
 js = Resource(library, 'examples/ux/ux-all.js',
-                  debug   = 'examples/ux/ux-all-debug.js',
-                  depends = [extjs.js] )
+              debug='examples/ux/ux-all-debug.js',
+              depends=[extjs.js])
 
 css = Resource(library, 'examples/ux/css/ux-all.css',
-                   depends = [extjs.css] )
+               depends=[extjs.css])
 
-all = GroupResource( [js, css] )
-
-basic_with_ux = GroupResource( [extjs.basic, all] )
+all = basic_with_ux = GroupResource([js, css])