Changes between Version 33 and Version 34 of DevelopersGuide/DevelopingPlugins
- Timestamp:
- 2009-11-08T09:21:06+01:00 (16 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
DevelopersGuide/DevelopingPlugins
v33 v34 7 7 = Setting up the environment = 8 8 9 * Get the complete osm - trunk from http://svn.openstreetmap.org. This checks out everythinginto a directory called''osm''9 * Check out the plugin environment into an empty directory called {{{josm}}} 10 10 {{{ 11 svn co http://svn.openstreetmap.org 11 svn co http://svn.openstreetmap.org/applications/editors/josm josm 12 12 }}} 13 * If you only want to work with JOSM and its plugins, it is possible to download only the JOSM directory. (''http://svn.openstreetmap.org/applications/editors/josm'' 100MB in 2009-10) 14 * create a new plugin-directory {{{osm/applications/editors/josm/plugins/yourpluginname}}}. You may create a copy of the template directory [http://svn.openstreetmap.org/applications/editors/josm/plugins/00_plugin_dir_template/ 00_plugin_dir_template]. It includes a directory layout, a [http://svn.openstreetmap.org/applications/editors/josm/plugins/00_plugin_dir_template/LICENSE license file] and a template for the [http://svn.openstreetmap.org/applications/editors/josm/plugins/00_plugin_dir_template/build.xml build.xml]. 13 * create a new plugin-directory {{{josm/plugins/yourpluginname}}}. You may create a copy of the template directory [http://svn.openstreetmap.org/applications/editors/josm/plugins/00_plugin_dir_template/ 00_plugin_dir_template]. It includes a directory layout, a [http://svn.openstreetmap.org/applications/editors/josm/plugins/00_plugin_dir_template/LICENSE license file] and a template for the [http://svn.openstreetmap.org/applications/editors/josm/plugins/00_plugin_dir_template/build.xml build.xml]. 15 14 * Open the ant script ({{{build.xml}}}) in your plugin directory and configure the properties in the configuration section. The important thing of your build script is, that it places some attributes into the {{{MANIFEST.MF}}} of the jar file. See below. {{{build.xml}}} in the template directory takes care of this. 16 15 * [http://svn.openstreetmap.org/applications/editors/josm/plugins/00_plugin_dir_template/README.template This readme] explains how your plugin is built and made available to other JOSM users. 17 16 * Also note, that JOSM is compiled into Java5 compatible class files, so if you are using Java6 or Java7, specify "-target 1.5" as parameter to javac or your plugin will not be usable with the official josm builds. 17 * If you need other OSM resources you can check out the complete osm - trunk: {{{svn co http://svn.openstreetmap.org/}}} 18 18 19 19 = The ''Plugin'' class =