diff --git a/docs/source/setup_windows.rst b/docs/source/setup_windows.rst index 2f5c7686..858286ff 100644 --- a/docs/source/setup_windows.rst +++ b/docs/source/setup_windows.rst @@ -69,6 +69,10 @@ Open the folder where you extracted the novelWriter source, and double-click the setup script to install dependencies, and desktop and start menu icons. It will also check that it can find Python from Step 1. +.. note:: + If you upgrade Python to a newer version and the path to ``pythonw.exe`` changes, you may need + to run this script again. + **Alternative B: Manual Installation** The above alternative can also be run manually. diff --git a/setup.py b/setup.py index 435db317..c9f424de 100755 --- a/setup.py +++ b/setup.py @@ -686,7 +686,7 @@ def winInstall(): """Will attempt to install icons and make a launcher for Windows. """ import winreg - from nw import __version__, __hexversion__ + from nw import __version__, __status__ try: import win32com.client except ImportError: @@ -702,7 +702,7 @@ def winInstall(): print("===============") print("") - nwTesting = not __hexversion__.endswith("f0") + nwTesting = not __status__.lower().startswith("stable") wShell = win32com.client.Dispatch("WScript.Shell") if nwTesting: @@ -780,7 +780,7 @@ def winInstall(): winreg.SetValueEx(regKey, kName, 0, winreg.REG_SZ, kVal) winreg.CloseKey(regKey) - mimeIcon = os.path.join(targetDir, "assets", "icons", "x-novelwriter-project.ico") + mimeIcon = os.path.join(targetDir, "nw", "assets", "icons", "x-novelwriter-project.ico") mimeExec = '"%s" "%s" "%%1"' % (pythonExe, targetPy) try: