> > Hello all > > I'm new to qooxdoo and struggling with a (hopefully) simple problem. I'd > like to add custom settings to the config.json file and access these > settings from within my classes.
Use the config key "settings" [1] in your job definition. Remember that you have to use this key in the context of a job definition (s.further). > > A simple example: I need a base URL for my server requests (since i'm > trying > to develop a client-server app). I'd like to have some sort of a global > setting like: myapp.BaseUrl, which holds the base URL of the server. > Optimally, this setting would be different for source and "release" build. Override the jobs "source-script" and "build-script" in your config like so: "source-script" : { "settings" : { "myapp.BaseUrl" : "<some_url>" } } > I already tried "--use-setting" as generator flag, as it is described in > the > documentation. This flag doesn't seem to be recognized however (i'm using > qooxdoo 0.8.1). This is a pre-0.8 way of doing it, and is no longer supported. But apart from the generator options, [2] is still a good introduction to settings. > > Is there a solution to this problem? Could somebody point me to a recent > documentation or post a example how i can add such custom settings and how > i > can then access it from within my classes? You access settings with qx.core.Setting.get() [3]. HTH, Thomas [1] http://qooxdoo.org/documentation/0.8/generator_config_ref#settings [2] http://qooxdoo.org/documentation/0.7/settings [3] http://demo.qooxdoo.org/current/apiviewer/#qx.core.Setting > -- > View this message in context: > http://n2.nabble.com/Adding-custom-settings-to-the-config-file--tp2003077p2003077.html > Sent from the qooxdoo mailing list archive at Nabble.com. > > > ------------------------------------------------------------------------------ > _______________________________________________ > qooxdoo-devel mailing list > qooxdoo-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel > > > ------------------------------------------------------------------------------ _______________________________________________ qooxdoo-devel mailing list qooxdoo-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel