--- gazpacho/__init__.py.orig 2007-07-29 07:57:30 UTC +++ gazpacho/__init__.py @@ -16,19 +16,20 @@ import os from kiwi.environ import Library +from kiwi.environ import _KiwiProvider dirname = os.path.abspath( os.path.join(os.path.dirname(os.path.realpath(__file__)), '..')) lib = Library('gazpacho', root=dirname) if lib.uninstalled: - lib.add_global_resource('catalog', 'catalogs') - lib.add_global_resource('glade', 'glade') - lib.add_global_resource('resource', 'resources') - lib.add_global_resource('doc', '.') - lib.add_global_resource('pixmap', 'pixmaps') - lib.add_global_resource('pixmap', 'pixmaps/kiwi') - lib.add_global_resource('plugins', 'plugins') + _KiwiProvider.add_resource('catalog', os.path.join(dirname, 'catalog')) + _KiwiProvider.add_resource('glade', os.path.join(dirname, 'glade')) + _KiwiProvider.add_resource('resource', os.path.join(dirname, 'resources')) + _KiwiProvider.add_resource('doc', os.path.join(dirname, '.')) + _KiwiProvider.add_resource('pixmap', os.path.join(dirname, 'pixmaps')) + _KiwiProvider.add_resource('pixmap', os.path.join(dirname, 'pixmaps/kiwi')) + _KiwiProvider.add_resource('plugins', os.path.join(dirname, 'plugins')) lib.enable_translation() __version__ = "0.7.2"
def _get_external_plugins_paths(): import stoqlib # This is the dir containing stoq/kiwi/stoqdrivers/etc checkout = os.path.dirname( os.path.dirname(os.path.dirname(stoqlib.__file__))) # If there's n foobar plugin on the checkout, it will expand to find: # CHECKOUT/<git_repository>/foobar/foobar.plugin for filename in glob.iglob(os.path.join(checkout, '*', '*', '*.plugin')): # In the example above, the path here is expected to be on # <git_repository>, not on <git_repository>/foobar/ yield os.path.dirname(os.path.dirname(filename)) library = Library('stoq', root='..' + os.sep + '..') if library.uninstalled: library.add_global_resource('csv', 'data/csv') library.add_global_resource('docs', '.') library.add_global_resource('glade', 'data/glade') library.add_global_resource('html', 'data/html') library.add_global_resource('misc', 'data/misc') library.add_global_resource('pixmaps', 'data/pixmaps') library.add_global_resource('sql', 'data/sql') library.add_global_resource('template', 'data/template') library.add_global_resource('uixml', 'data/uixml') library.add_resource('plugin', 'plugins') for dirname in _get_external_plugins_paths(): library.add_resource('plugin', dirname) externals = os.path.join(library.get_root(), 'external') else:
## along with this program; if not, write to the Free Software ## Foundation, Inc., or visit: http://www.gnu.org/. ## ## ## Author(s): Stoq Team <*****@*****.**> ## ## import os import site from kiwi.environ import Library __all__ = ['library'] library = Library('stoq', root='..' + os.sep + '..') if library.uninstalled: library.add_global_resource('config', 'data/config') library.add_global_resource('csv', 'data/csv') library.add_global_resource('docs', '.') library.add_global_resource('glade', 'data/glade') library.add_global_resource('html', 'data/html') library.add_global_resource('misc', 'data/misc') library.add_global_resource('pixmaps', 'data/pixmaps') library.add_global_resource('sql', 'data/sql') library.add_global_resource('template', 'data/template') library.add_global_resource('uixml', 'data/uixml') library.add_resource('plugin', 'plugins') externals = os.path.join(library.get_root(), 'external') else: # root = $prefix/lib/pythonX.Y/site-packages
# This program is free software; you can redistribute it and/or modify it under # the terms of the GNU General Public License as published by the Free Software # Foundation; either version 2 of the License, or (at your option) any later # version. # # This program is distributed in the hope that it will be useful, but WITHOUT # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS # FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details # # You should have received a copy of the GNU General Public License along with # this program; if not, write to the Free Software Foundation, Inc., # 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. from kiwi.environ import Library, environ import os lib = Library("metanomon") if lib.uninstalled: if os.path.exists("/usr/share/metanomon"): lib.add_global_resource('glade', '/usr/share/metanomon/glade') lib.add_global_resource('images', '/usr/share/metanomon/images') else: environ.add_resource('glade', 'glade') environ.add_resource('images', 'images')
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ## GNU Lesser General Public License for more details. ## ## You should have received a copy of the GNU Lesser General Public License ## along with this program; if not, write to the Free Software ## Foundation, Inc., or visit: http://www.gnu.org/. ## ## ## Author(s): Stoq Team <*****@*****.**> ## ## import os import site from kiwi.environ import Library __all__ = ["library"] library = Library("stoq", root=".." + os.sep + "..") if library.uninstalled: externals = os.path.join(library.get_root(), "external") else: # root = $prefix/lib/pythonX.Y/site-packages # We want $prefix/lib/stoqlib, eg ../../stoqlib externals = os.path.join(library.prefix, "lib", "stoqlib") site.addsitedir(externals) library.enable_translation(domain="stoq", enable_global=True)
## Copyright (C) 2005-2011 Async Open Source <http://www.async.com.br> ## All rights reserved ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by ## the Free Software Foundation; either version 2 of the License, or ## (at your option) any later version. ## ## This program is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY; without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ## GNU General Public License for more details. ## ## You should have received a copy of the GNU General Public License ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, ## USA. ## ## Author(s): Henrique Romano <*****@*****.**> ## Johan Dahlin <*****@*****.**> ## __version__ = (1, 2, 2) from kiwi.environ import Library __all__ = ["library"] library = Library("stoqdrivers", root="..") library.enable_translation()
raise SystemExit( "PyGTK 2.8 or PyGObject 2.9.0 or higher is required by kiwi\n" "Error was: %s" % e) # if gobject.pygtk_version[:2] < (2, 8, 0): # raise ImportError("Your PyGTK/PyGObject version is too old, found %s, " # "but 2.8.0 or higher is required by kiwi" % ( # ('.'.join(map(str, gobject.pygtk_version))),)) from kiwi.__version__ import version as kiwi_version from kiwi.environ import Library assert kiwi_version # pyflakes lib = Library('kiwi') if lib.uninstalled: lib.add_global_resource('glade', 'glade') lib.add_global_resource('pixmap', 'pixmaps') lib.enable_translation() # Be careful to not export too much del Library, lib, gobject class ValueUnset: """To differentiate from places where None is a valid default. Used mainly in the Kiwi Proxy""" pass __all__ = ['ValueUnset', 'kiwi_version']
## Copyright (C) 2005-2011 Async Open Source <http://www.async.com.br> ## All rights reserved ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by ## the Free Software Foundation; either version 2 of the License, or ## (at your option) any later version. ## ## This program is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY; without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ## GNU General Public License for more details. ## ## You should have received a copy of the GNU General Public License ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, ## USA. ## ## Author(s): Henrique Romano <*****@*****.**> ## Johan Dahlin <*****@*****.**> ## __version__ = (1, 7, 2) from kiwi.environ import Library __all__ = ["library"] library = Library("stoqdrivers", root="..") library.enable_translation()
from kiwi.environ import Library lib = Library('package') if lib.uninstalled: lib.add_global_resource('glade', 'glade')
# along with Foobar. If not, see <http://www.gnu.org/licenses/>. """ This is the basic package for the Crisk Application. """ import sys import os import gtk.glade from kiwi.environ import Library #if os.name in ['win32', 'windows', 'nt']: # sys.stderr = sys.stdout # Adicionando paths para achar os resources lib = Library('crisk', '../../') if lib.uninstalled: lib.add_global_resource('glade', 'glade') lib.add_global_resource('pixmaps', 'pixmaps') lib.enable_translation('crisk') lib.set_application_domain('crisk') __author__ = 'José de Paula E. Júnior (coredump)' __url__ = 'http://coredump.github.com/crisk/' __version__ = '0.3' __shortdescription__ = 'Simple Risk Management Tool' __description__ = """
Kiwi includes a Framework and a set of enhanced widgets - Authors: - Christian Reis <*****@*****.**> - Johan Dahlin <*****@*****.**> - Website: U{http://www.async.com.br/projects/kiwi/} - Organization: Async Open Source """ from kiwi.__version__ import version as kiwi_version from kiwi.environ import Library assert kiwi_version # pyflakes library = Library('kiwi') library.enable_translation() # Be careful to not export too much del Library class ValueUnset: """To differentiate from places where None is a valid default. Used mainly in the Kiwi Proxy""" pass __all__ = ['ValueUnset', 'kiwi_version'] # by default locale uses the C locale but our date conversions use the user
## ## Copyright (C) 2015 Async Open Source <http://www.async.com.br> ## All rights reserved ## ## This program is free software; you can redistribute it and/or ## modify it under the terms of the GNU Lesser General Public License ## as published by the Free Software Foundation; either version 2 ## of the License, or (at your option) any later version. ## ## This program is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY; without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ## GNU Lesser General Public License for more details. ## ## You should have received a copy of the GNU Lesser General Public License ## along with this program; if not, write to the Free Software ## Foundation, Inc., or visit: http://www.gnu.org/. ## ## Author(s): Stoq Team <*****@*****.**> ## from kiwi.environ import Library __version__ = (0, 28, 0) __all__ = ["library"] library = Library("stoqserver", root="..") library.enable_translation(domain='stoqserver', enable_global=True) version_str = '.'.join(str(i) for i in __version__)
# This program is free software; you can redistribute it and/or modify it under # the terms of the GNU General Public License as published by the Free Software # Foundation; either version 2 of the License, or (at your option) any later # version. # # This program is distributed in the hope that it will be useful, but WITHOUT # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS # FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details # # You should have received a copy of the GNU General Public License along with # this program; if not, write to the Free Software Foundation, Inc., # 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. from kiwi.environ import Library, environ import os lib = Library("lintgtk") if lib.uninstalled: if os.path.exists("/usr/share/lintgtk"): lib.add_global_resource('glade', '/usr/share/lintgtk/glade') lib.add_global_resource('images', '/usr/share/lintgtk/images') else: environ.add_resource('glade', 'glade') environ.add_resource('images', 'images')
## ## Copyright (C) 2015 Async Open Source <http://www.async.com.br> ## All rights reserved ## ## This program is free software; you can redistribute it and/or ## modify it under the terms of the GNU Lesser General Public License ## as published by the Free Software Foundation; either version 2 ## of the License, or (at your option) any later version. ## ## This program is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY; without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ## GNU Lesser General Public License for more details. ## ## You should have received a copy of the GNU Lesser General Public License ## along with this program; if not, write to the Free Software ## Foundation, Inc., or visit: http://www.gnu.org/. ## ## Author(s): Stoq Team <*****@*****.**> ## from kiwi.environ import Library __version__ = (0, 28, 0, "alpha1") __all__ = ["library"] library = Library("stoqserver", root="..") library.enable_translation(domain='stoqserver', enable_global=True) version_str = '.'.join(str(i) for i in __version__)
## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by ## the Free Software Foundation; either version 2 of the License, or ## (at your option) any later version. ## ## This program is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY; without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ## GNU General Public License for more details. ## ## You should have received a copy of the GNU General Public License ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, ## USA. ## ## Author(s): Henrique Romano <*****@*****.**> ## Johan Dahlin <*****@*****.**> ## __version__ = (0, 9, 17) from kiwi.environ import Library __all__ = ["library"] library = Library("stoqdrivers", root="..") if library.uninstalled: library.add_global_resource("conf", "stoqdrivers/conf") library.enable_translation()
## This program is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY; without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ## GNU Lesser General Public License for more details. ## ## You should have received a copy of the GNU Lesser General Public License ## along with this program; if not, write to the Free Software ## Foundation, Inc., or visit: http://www.gnu.org/. ## ## ## Author(s): Stoq Team <*****@*****.**> ## ## import os from kiwi.environ import Library __all__ = ['library'] library = Library('stoq', root='..' + os.sep + '..') if library.uninstalled: externals = os.path.join(library.get_root(), 'external') else: # root = $prefix/lib/pythonX.Y/site-packages # We want $prefix/lib/stoqlib, eg ../../stoqlib externals = os.path.join(library.prefix, 'lib', 'stoqlib') library.enable_translation(domain="stoq", enable_global=True)
# vi:si:et:sw=4:sts=4:ts=4 ## ## Copyright (C) 2015 Async Open Source <http://www.async.com.br> ## All rights reserved ## ## This program is free software; you can redistribute it and/or ## modify it under the terms of the GNU Lesser General Public License ## as published by the Free Software Foundation; either version 2 ## of the License, or (at your option) any later version. ## ## This program is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY; without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ## GNU Lesser General Public License for more details. ## ## You should have received a copy of the GNU Lesser General Public License ## along with this program; if not, write to the Free Software ## Foundation, Inc., or visit: http://www.gnu.org/. ## ## Author(s): Stoq Team <*****@*****.**> ## from kiwi.environ import Library __version__ = (0, 12) __all__ = ["library"] library = Library("stoqserver", root="..") version_str = '.'.join(str(i) for i in __version__)
# as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU Lesser General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. # # This file contains code from Gazpacho # Copyright (C) 2005 by Async Open Source ''' sacam module ''' import os from kiwi.environ import Library DIRNAME = os.path.abspath( os.path.join(os.path.dirname(os.path.realpath(__file__)), '..')) LIB = Library('sacam', root=DIRNAME) if LIB.uninstalled: LIB.add_global_resource('glade', 'glade') LIB.add_global_resource('doc', 'doc') LIB.add_global_resource('xml', 'xml') LIB.enable_translation("sacam")
# along with Foobar. If not, see <http://www.gnu.org/licenses/>. """ This is the basic package for the Crisk Application. """ import sys import os import gtk.glade from kiwi.environ import Library #if os.name in ['win32', 'windows', 'nt']: # sys.stderr = sys.stdout # Adicionando paths para achar os resources lib = Library('crisk', '../../') if lib.uninstalled: lib.add_global_resource('glade', 'glade') lib.add_global_resource('pixmaps', 'pixmaps') lib.enable_translation('crisk') lib.set_application_domain('crisk') __author__ = 'José de Paula E. Júnior (coredump)' __url__ = 'http://coredump.github.com/crisk/' __version__ = '0.3' __shortdescription__ = 'Simple Risk Management Tool' __description__ = """ Crisk is a simple tool for Risk Management, aimed at security officers, security consultants and risk professionals.
# modify it under the terms of the GNU Lesser General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU Lesser General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. # # This file contains code from Gazpacho # Copyright (C) 2005 by Async Open Source ''' sacam module ''' import os from kiwi.environ import Library DIRNAME = os.path.abspath( os.path.join(os.path.dirname(os.path.realpath(__file__)), '..')) LIB = Library('sacam', root=DIRNAME) if LIB.uninstalled: LIB.add_global_resource('glade', 'glade') LIB.add_global_resource('doc', 'doc') LIB.add_global_resource('xml', 'xml') LIB.enable_translation("sacam")
## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by ## the Free Software Foundation; either version 2 of the License, or ## (at your option) any later version. ## ## This program is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY; without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ## GNU General Public License for more details. ## ## You should have received a copy of the GNU General Public License ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, ## USA. ## ## Author(s): Henrique Romano <*****@*****.**> ## Johan Dahlin <*****@*****.**> ## __version__ = (0, 9, 21) from kiwi.environ import Library __all__ = ["library"] library = Library("stoqdrivers", root="..") if library.uninstalled: library.add_global_resource("conf", "stoqdrivers/conf") library.enable_translation()
raise SystemExit( "PyGTK 2.8 or PyGObject 2.9.0 or higher is required by kiwi\n" "Error was: %s" % e) # if gobject.pygtk_version[:2] < (2, 8, 0): # raise ImportError("Your PyGTK/PyGObject version is too old, found %s, " # "but 2.8.0 or higher is required by kiwi" % ( # ('.'.join(map(str, gobject.pygtk_version))),)) from kiwi.__version__ import version as kiwi_version from kiwi.environ import EnvironmentError, Library assert kiwi_version # pyflakes library = Library('kiwi') if library.uninstalled: try: library.add_global_resource('glade', 'glade') except EnvironmentError: pass library.enable_translation() # Be careful to not export too much del Library, gobject class ValueUnset: """To differentiate from places where None is a valid default. Used mainly in the Kiwi Proxy""" pass
except: raise SystemExit( "PyGTK 2.8 or PyGObject 2.9.0 or higher is required by kiwi\n" "Error was: %s" % e) # if gobject.pygtk_version[:2] < (2, 8, 0): # raise ImportError("Your PyGTK/PyGObject version is too old, found %s, " # "but 2.8.0 or higher is required by kiwi" % ( # ('.'.join(map(str, gobject.pygtk_version))),)) from kiwi.__version__ import version as kiwi_version from kiwi.environ import Library assert kiwi_version # pyflakes library = Library('kiwi') if library.uninstalled: library.add_global_resource('glade', 'glade') library.add_global_resource('pixmap', 'pixmaps') library.enable_translation() # Be careful to not export too much del Library, gobject class ValueUnset: """To differentiate from places where None is a valid default. Used mainly in the Kiwi Proxy""" pass