From cebf92573c429f52ee0684e06f93a29010c36b21 Mon Sep 17 00:00:00 2001 From: "Benjamin K." <53038537+treee111@users.noreply.github.com> Date: Wed, 16 Oct 2024 12:37:54 +0200 Subject: [PATCH] [FIX] Windows: adjust location of mapwriter plugin (#262) [FIX] adjust location of mapwriter plugin - where plugin is downloaded into - see https://wiki.openstreetmap.org/wiki/Osmosis/Detailed_Usage_0.48#Plugin_Tasks - see https://www.rennrad-news.de/forum/threads/aktuelles-kartenmaterial-f%C3%BCr-wahoo-elemnt-bolt-roam-elemnt-selbst-generieren.175315/page-48#post-6327012 --- wahoomc/downloader.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/wahoomc/downloader.py b/wahoomc/downloader.py index 1716ab49..134b34a1 100644 --- a/wahoomc/downloader.py +++ b/wahoomc/downloader.py @@ -138,8 +138,12 @@ def download_tooling(): download_file(get_tooling_win_path('osmfilter.exe', in_user_dir=True), 'http://m.m.i24.cc/osmfilter.exe') - mapwriter_plugin_path = os.path.join(USER_TOOLING_WIN_DIR, - 'Osmosis', 'lib', 'default', map_writer_filename) + # it seams, that as of Osmosis version 0.49.0 or at least in 0.49.2 + # the old mapwriter plugin location does not work anymore. + # until v0.48.3, the location c:\Users\\wahooMapsCreatorData\Osmosis\lib\default worked + # since v0.49.0, the location c:\Users\\AppData\Roaming\Openstreetmap\Osmosis\Plugins\ works + mapwriter_plugin_path = os.path.join( + str(USER_DIR), 'AppData', 'Roaming', 'Openstreetmap', 'Osmosis', 'Plugins', map_writer_filename) # Non-Windows else: