1 | README
|
---|
2 | ======
|
---|
3 |
|
---|
4 | This is a template project structure for a JOSM plugin.
|
---|
5 |
|
---|
6 | Layout
|
---|
7 | ======
|
---|
8 | +--- src source of your plugin
|
---|
9 | |- images images your plugin needs
|
---|
10 | |- resources resources your plugin needs
|
---|
11 |
|
---|
12 | build.number the build number, maintained by the build script
|
---|
13 | LICENSE license file
|
---|
14 | README README for your plugin
|
---|
15 |
|
---|
16 | README.template this file
|
---|
17 |
|
---|
18 |
|
---|
19 | Build
|
---|
20 | =====
|
---|
21 | A JOSM plugin is built as a single jar. We use ant to build.
|
---|
22 |
|
---|
23 | See build.xml in this directory and update the plugin specific properties in the
|
---|
24 | configuration section.
|
---|
25 |
|
---|
26 |
|
---|
27 | Maintaining versions
|
---|
28 | ====================
|
---|
29 | There are two versions maintained with each plugin:
|
---|
30 | 1) the main version
|
---|
31 | You have to manually set the plugins main version in the build script.
|
---|
32 | Set the property plugin.main.version in build.xml accordingly.
|
---|
33 |
|
---|
34 | 2) the build version
|
---|
35 | The build version is unique for every build of the plugin. It is equal
|
---|
36 | to the SVN revision of the file 'build.number'. The build script automatically
|
---|
37 | increments the the build number and checks 'build.number' back in. Thus,
|
---|
38 | the SVN revision for build.number is incremented on every build.
|
---|
39 |
|
---|
40 | Both the main version and the build version are included in properties of the plugins
|
---|
41 | manifest:
|
---|
42 | Plugin-Version the build version
|
---|
43 | Plugin-Mainversion the main version
|
---|
44 |
|
---|
45 | JOSM automatically detects whether a plugin needs to be upgraded. It compares the build
|
---|
46 | version of the currently installed plugin jar with the build version of the plugin jar in
|
---|
47 | the SVN. The main version is irrelevant for this process.
|
---|
48 |
|
---|
49 | Making your plugin available to JOSM users
|
---|
50 | ===========================================
|
---|
51 | When a plugin jar is checked into SVN a script updates the plugins list on the JOSM wiki:
|
---|
52 | http://josm.openstreetmap.de/wiki/Plugins
|
---|
53 | JOSM retrieves the list of available plugins and their build versions from this list.
|
---|
54 |
|
---|
55 | commit publish read
|
---|
56 | meta data meta data
|
---|
57 | Build ==> SVN =======> JOSM Wiki <======= JOSM
|
---|
58 | ^
|
---|
59 | ==================================
|
---|
60 | fetch current plugin jar
|
---|
61 |
|
---|
62 | Note that you have to manually publish (commit) your plugin jar. There is no nightly build
|
---|
63 | in place. Everything else (pulishing meta data, updating plugins in the client) is then handled
|
---|
64 | by automatic processes.
|
---|
65 |
|
---|
66 | See also
|
---|
67 | ========
|
---|
68 | * Developing Plugins
|
---|
69 | http://josm.openstreetmap.de/wiki/DevelopingPlugins
|
---|
70 |
|
---|
71 | * List of JOSM Plugins
|
---|
72 | http://josm.openstreetmap.de/wiki/Plugins
|
---|
73 |
|
---|
74 |
|
---|
75 |
|
---|
76 |
|
---|
77 |
|
---|
78 |
|
---|