Using Java Web Start
There is also the JAR way (download the jar file. double-click the jar file to run it) that will work in most cases. See JOSM/Installation and Java Runtime Environment#How to run a Java application.
There is also a Windows Installer.
You may wish to download josm-setup.exe, the windows installer, instead.
When you run this, windows may give you various a security warnings, and then it will guide you through a set-up process which ensures java is installed, and gives you a JOSM start menu icon. Otherwise you can set things up to run from a jar file as detailed in the following sections.
Where to put the jar file?
You can put the jar file anywhere, but having a separate folder is a good idea when it comes to organising other files which you may end up placing alongside the jar. On a Windows XP/ME/2000/9x machine you might typically create a folder 'C:\Program files\JOSM' for consistency.
Windows command line
The JOSM/Installation instructions talk about running the jar from the command line. Do this in windows by click 'Start' menu -> 'Run...', and enter "cmd" as the name of the program to run.
An easy way to avoid fiddling with the command line every time, while still running JOSM with extra command line options, is to place commands in a .bat file.
- Open the folder where you placed the jar (e.g. 'C:\Program files\JOSM')
- Right-click to get context menu, then select 'new > Text Document'
- Set the name 'run-josm.bat' ('Are you sure want to change it?' YES)
- Open this new file in notepad
- Put your commands here e.g. start javaw.exe -jar -Xmx8192M "C:\Program Files\JOSM\josm-latest.jar"
- Xmx8192M represents the amount of RAM that will be dedicated (in this case 8GB). You can change the number to whichever you see fit.
- "C:\Program Files\JOSM\josm-latest" (brackets included) represents the location of the .jar that starts JOSM.
- ...and save
Double-click the bat file to run JOSM. You should see a black command window each time where the bat file runs. This can actually be helpful (extra error reporting can appear here sometimes)
CMD script to check for changes in JOSM and download
A cmd script (basically a .bat file) basing the update on the version number is available below.
Edit the lines that begin with SET to match your system. curl.exe and unzip.exe are needed for this to run.
optional java parameters "-Xmx512M" sets java to use 512Meg of memory, and "-Dsun.java2d.opengl=true" to use Open GL graphics acceleration. Remove them if you have any problems.
SETLOCAL SET josmver=tested SET josmjar=josm-%josmver%.jar SET josmsite=https://josm.openstreetmap.de SET josmpath=c:\documents and settings\username\mapping SET curlexe=c:\program files\curl\curl.exe SET unzipexe=c:\program files\zip\unzip.exe SET tempfile=%temp%\REVISION SET revfile=%temp%\%josmver% SET javaopt=-Xmx512M -Dsun.java2d.opengl=true SET currentrev=0 REM ======= End of config options section ======= "%unzipexe%" -o "%josmpath%\%josmjar%" REVISION -d %temp% "%curlexe%" %josmsite%/%josmver% -o %revfile% FOR /f "tokens=1,2" %%A in ('findstr "Revision" %tempfile%') DO SET currentrev=%%B FOR /f %%A in (%revfile%) DO SET latestrev=%%A IF NOT %currentrev%==%latestrev% "%curlexe%" %josmsite%/%josmjar% -o "%josmpath%\%josmjar%" REM Start JOSM java.exe %javaopt% -jar "%josmpath%\%josmjar%"
Create a shortcut
To create a shortcut to run the latest version of JOSM from the JOSM pages (tested on Windows 10):
- Right click -> New -> Shortcut
- As the location of the item, paste:
javaws.exe -J-Xmx1G https://josm.openstreetmap.de/download/josm.jnlp
- Choose any name for the shortcut.
- Now you can run the shortcut, pin it to the taskbar etc.
In case your shortcut doesn't work, try to reinstall your Java or put the whole path to your javaws.exe to the shortcut.
Plugins and preferences
When running JOSM for the first time, it will create a folder where plugins are stored. This can be found in a 'My Computer' window by going to "%APPDATA%" (type this in the location bar)
In the 'JOSM' folder there you will also find your preferences file. Note that this is a per-user set of files. If you log on to windows with a different user, you can run JOSM with a different set of preferences and plugins.
Look and feel
JOSM should look like a windows app when it runs. The graphical style of the app can be changed to suite other operating systems, but should be auto-detected as windows when you first run. Other options can be seen in the JOSM 'preferences'