From 0907bf195e0504585986dee5111fad94bc68d49e Mon Sep 17 00:00:00 2001 From: "Veronica K. B. Olsen" <1619840+vkbo@users.noreply.github.com> Date: Sun, 17 Jan 2021 21:11:51 +0100 Subject: [PATCH 01/10] Bump version to 1.0.2 and update changelog --- CHANGELOG.md | 24 ++++++++++++++++++++++++ docs/source/conf.py | 4 ++-- nw/__init__.py | 6 +++--- 3 files changed, 29 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 12ab3ef6..d1162cdf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,29 @@ # novelWriter Change Log +## Version 1.0.2 [2021-01-24] + +### Release Notes + +### Detailed Changelog + +**Bug Fixes** + +* Fixed an issue with note files being moved between a non-novel root folder and a novel root + folder without clearing its index entry in the former note or novel index. This would cause + duplicate entries for such a file. PR #558. +* Fixed a cosmetic issue where the meta data panel below the project tree was not cleared when the + project was closed. PR #559. +* Fixed an issue where the main window title was not cleared when a project was closed, and the new + title not set when a new project was first created. Issue #560, PR #561. + +**Documentation** + +* Fixed some typos and spelling mistakes in the documentation, and reworded parts of the text that + were unclear. The technical page has also been extended with more information of project folder + structure. PR #557. + +---- + ## Version 1.0.1 [2021-01-10] ### Release Notes diff --git a/docs/source/conf.py b/docs/source/conf.py index d6f4580a..86a78181 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -25,9 +25,9 @@ copyright = "2018–2021, Veronica Berglyd Olsen" author = "Veronica Berglyd Olsen" # The short X.Y version -version = "1.0.1" +version = "1.0.2" # The full version, including alpha/beta/rc tags -release = "1.0.1" +release = "1.0.2" # -- General configuration --------------------------------------------------- diff --git a/nw/__init__.py b/nw/__init__.py index 51126435..f0d09ff3 100644 --- a/nw/__init__.py +++ b/nw/__init__.py @@ -63,9 +63,9 @@ __license__ = "GPLv3" __author__ = "Veronica Berglyd Olsen" __maintainer__ = "Veronica Berglyd Olsen" __email__ = "code@vkbo.net" -__version__ = "1.0.1" -__hexversion__ = "0x010001f0" -__date__ = "2021-01-10" +__version__ = "1.0.2" +__hexversion__ = "0x010002f0" +__date__ = "2021-01-24" __status__ = "Stable" __domain__ = "novelwriter.io" __url__ = "https://novelwriter.io" From 211a06e9bcb9e4df2972132cb68f4d1eefeff427 Mon Sep 17 00:00:00 2001 From: stranger-danger-zamu <70606846+stranger-danger-zamu@users.noreply.github.com> Date: Tue, 19 Jan 2021 11:44:44 -0500 Subject: [PATCH 02/10] Issue #570 --- setup.cfg | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/setup.cfg b/setup.cfg index 848c51a6..ee034b55 100644 --- a/setup.cfg +++ b/setup.cfg @@ -23,10 +23,6 @@ classifiers = Natural Language :: English Topic :: Text Editors python_requires = >=3.6 -install_requires = - pyqt5>=5.2.1 - lxml>=4.2.0 - pyenchant>=3.0.0 project_urls = Bug Tracker = https://github.com/vkbo/novelWriter/issues Documentation = https://github.com/vkbo/novelWriter/issues @@ -35,6 +31,10 @@ project_urls = [options] include_package_data = True packages = find: +install_requires = + pyqt5>=5.2.1 + lxml>=4.2.0 + pyenchant>=3.0.0 [options.packages.find] exclude = docs, tests, sample From 9f9028b7ce9c23bd718c9bd2298d561e375594d7 Mon Sep 17 00:00:00 2001 From: "Veronica K. B. Olsen" <1619840+vkbo@users.noreply.github.com> Date: Tue, 19 Jan 2021 19:08:51 +0100 Subject: [PATCH 03/10] Fix "Add Word to Dictionary" missing when there are no spell suggestions --- nw/gui/doceditor.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/nw/gui/doceditor.py b/nw/gui/doceditor.py index 3421276c..dace3fd3 100644 --- a/nw/gui/doceditor.py +++ b/nw/gui/doceditor.py @@ -1014,15 +1014,15 @@ class GuiDocEditor(QTextEdit): lambda thePos, aWord=aWord : self._correctWord(posCursor, aWord) ) mnuContext.addAction(mnuWord) - mnuContext.addSeparator() - mnuAdd = QAction("Add Word to Dictionary", mnuContext) - mnuAdd.triggered.connect(lambda thePos : self._addWord(posCursor)) - mnuContext.addAction(mnuAdd) - else: - mnuHead = QAction("No Suggestions", mnuContext) + mnuHead = QAction("%s No Suggestions" % nwUnicode.U_ENDASH, mnuContext) mnuContext.addAction(mnuHead) + mnuContext.addSeparator() + mnuAdd = QAction("Add Word to Dictionary", mnuContext) + mnuAdd.triggered.connect(lambda thePos : self._addWord(posCursor)) + mnuContext.addAction(mnuAdd) + # Open the context menu mnuContext.exec_(self.viewport().mapToGlobal(thePos)) From 4d690252504de5d788bd6be6e5f65b5ce8801475 Mon Sep 17 00:00:00 2001 From: "Veronica K. B. Olsen" <1619840+vkbo@users.noreply.github.com> Date: Tue, 19 Jan 2021 19:09:37 +0100 Subject: [PATCH 04/10] Fix lambda function syntax --- nw/gui/doceditor.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nw/gui/doceditor.py b/nw/gui/doceditor.py index dace3fd3..a06c3035 100644 --- a/nw/gui/doceditor.py +++ b/nw/gui/doceditor.py @@ -1011,7 +1011,7 @@ class GuiDocEditor(QTextEdit): for aWord in theSuggest: mnuWord = QAction("%s %s" % (nwUnicode.U_ENDASH, aWord), mnuContext) mnuWord.triggered.connect( - lambda thePos, aWord=aWord : self._correctWord(posCursor, aWord) + lambda thePos, aWord=aWord: self._correctWord(posCursor, aWord) ) mnuContext.addAction(mnuWord) else: @@ -1020,7 +1020,7 @@ class GuiDocEditor(QTextEdit): mnuContext.addSeparator() mnuAdd = QAction("Add Word to Dictionary", mnuContext) - mnuAdd.triggered.connect(lambda thePos : self._addWord(posCursor)) + mnuAdd.triggered.connect(lambda thePos: self._addWord(posCursor)) mnuContext.addAction(mnuAdd) # Open the context menu From ed9313759bf62bd9ccb2111550f6353e67fda61b Mon Sep 17 00:00:00 2001 From: "Veronica K. B. Olsen" <1619840+vkbo@users.noreply.github.com> Date: Tue, 19 Jan 2021 19:30:14 +0100 Subject: [PATCH 05/10] Clarify install instructions on dependency install --- README.md | 10 +++++++++- docs/source/int_started.rst | 4 ++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 4d3d1ae7..a521ab34 100644 --- a/README.md +++ b/README.md @@ -51,11 +51,19 @@ To upgrade an existing installation, use: pip install --upgrade novelwriter ``` -Dependencies are installed automatically, but can generally be installed with: +Dependencies are installed automatically. + + +If you're running from source, dependencies can be installed with: ```bash pip install -r requirements.txt ``` +You can also install the dependencies manually with: +```bash +pip install pyqt5 lxml pyenchant +``` + Below are some brief instructions on how to get started on different operating systems. diff --git a/docs/source/int_started.rst b/docs/source/int_started.rst index 9658ab1f..b3037537 100644 --- a/docs/source/int_started.rst +++ b/docs/source/int_started.rst @@ -82,8 +82,8 @@ and it is less sophisticated than full spell checking libaries, but if you only files, the performance loss is not noticeable. The spell check library must be at least 3.0 to work with Windows. On Linux, 2.0 also works fine. -If you install from PyPi, these dependencies should be installed automatically. They can be -manually installed with: +If you install from PyPi, these dependencies should be installed automatically. If you install from +source, dependencies can still be installed from PyPi with: .. code-block:: console From 2c191a9bd341c95742cee7a8c79b1920a727196e Mon Sep 17 00:00:00 2001 From: "Veronica K. B. Olsen" <1619840+vkbo@users.noreply.github.com> Date: Tue, 19 Jan 2021 19:30:35 +0100 Subject: [PATCH 06/10] Minor modification to the macOS workflow --- .github/workflows/test_mac.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/test_mac.yml b/.github/workflows/test_mac.yml index daaca247..aa63cbf2 100644 --- a/.github/workflows/test_mac.yml +++ b/.github/workflows/test_mac.yml @@ -24,6 +24,7 @@ jobs: run: | pip install --upgrade pip pip install -r requirements.txt + pip install pyobjc pip install pytest-timeout pip install pytest-cov pip install pytest-qt From 5c4e230f694d6ce588cd4daf2ac26b5e55b437cd Mon Sep 17 00:00:00 2001 From: "Veronica K. B. Olsen" <1619840+vkbo@users.noreply.github.com> Date: Tue, 19 Jan 2021 19:55:25 +0100 Subject: [PATCH 07/10] No need to duplicate instructions, but added a TLDR section --- README.md | 129 ++++++++++++------------------------------------------ 1 file changed, 27 insertions(+), 102 deletions(-) diff --git a/README.md b/README.md index a521ab34..b4bcfd41 100644 --- a/README.md +++ b/README.md @@ -28,7 +28,8 @@ is primarily saved in JSON files. The full documentation is available at [novelwriter.readthedocs.io](https://novelwriter.readthedocs.io/). -The contributing guide is available in [CONTRIBUTING](CONTRIBUTING.md). +The contributing guide is available at +[CONTRIBUTING](https://github.com/vkbo/novelWriter/blob/main/CONTRIBUTING.md). ## Implementation @@ -40,126 +41,50 @@ tests are run on the latest versions of Ubuntu Linux, Windows Server and macOS. # Installing and Running +For install instructions, please check the [documentation](https://novelwriter.readthedocs.io/) in +the [Getting Started](https://novelwriter.readthedocs.io/en/latest/int_started.html) section. + +## TLDR Instructions + +**Note:** You may need to replace `python` with `python3` and `pip` with `pip3` in the instructions +below on some systems. You may also want to add the `--user` flag for `pip` to install in your user +space only. + +### Install from PyPi + novelWriter is available on [pypi.org](https://pypi.org/project/novelWriter/), and can be installed with: ```bash pip install novelwriter ``` - -To upgrade an existing installation, use: -```bash -pip install --upgrade novelwriter -``` - -Dependencies are installed automatically. - - -If you're running from source, dependencies can be installed with: -```bash -pip install -r requirements.txt -``` - -You can also install the dependencies manually with: +Dependencies should be installed automatically, but can also be installed directly with: +with: ```bash pip install pyqt5 lxml pyenchant ``` -Below are some brief instructions on how to get started on different operating systems. +### Setup on Linux - -## Linux - -Either download the source, or install with pip. - -If you run from source, install the dependencies via pip, or directly from the OS repo. There are -very few dependencies, and they should be available in the standard repo. The Python packages -needed are `pyqt5`, `lxml` and `pyenchant`. - -### Installing from Source - -You can also install novelWriter from source with: +If you're running from source, the following commands will set up novelWriter on Linux: ```bash -python setup.py sample -sudo python setup.py install -sudo python setup.py xdg-install +pip install -r requirements.txt +python setup.py install +python setup.py xdg-install ``` -The last line will install the application icons and set up a launcher for novelWriter. The script -may prompt you to choose which executable to configure if it finds more than one. +### Setup on macOS -**Note:** If your distro has multiple versions of Python installed, you may need to use the -`python3` command instead of `python`. - -### Running from Source - -If you want to run directly from the source, the application can be started with: -```bash -./novelWriter.py -``` - -You can also create a launcher for running directly from source with: -```bash -python3 setup.py xdg-install -``` -This will install the launcher and icons for the current user. To install them system-wide, run the -above command with `sudo` or as root. - -For more install options, see [Build and Install novelWriter](setup/README.md). - - -## macOS - -These instructions assume you're using brew, and have Python and pip set up. If not, see the -[brew docs](https://docs.brew.sh/Homebrew-and-Python) for help. - -Main requirements are installed via the requirements file. You also need to install the `pyobjc` -package on macOS, so you must run: +If you're running from source, the following commands will set up novelWriter on macOS: ```bash +brew install enchant pip3 install --user -r requirements.txt pip3 install --user pyobjc ``` -For spell checking you may also need to install the enchant package. It comes with a lot of default -dictionaries. -```bash -brew install enchant -``` +### Setup on Windows -## Windows - -On Windows, you may first need to install Python. See the [python.org](https://www.python.org/) -website for download packages. It is recommended that you install the latest version of Python 3.8. - -To install dependencies, run: -```bash -pip install --user -r requirements.txt -``` - -**Note:** On Windows, make sure Python3 is in your PATH if you want to launch novelWriter from -command line. You can also right click the `novelWriter.py` file, create a shortcut, then right -click again, select "Properties" and change the target to your python executable and -`novelWriter.py`. - -It should look something like this: -``` -C:\...\AppData\Local\Programs\Python\Python38\python.exe novelWriter.py -``` - -You can also run the `make.py` script to generate a single executable, or an installer. -See [Build and Install novelWriter](setup/README.md) for more details. - - -## Package Versions - -Exporting to Markdown requires PyQt/Qt 5.14. There are no known minimum for `lxml`, but the code -was originally written with 4.2. The optional spell check library must be at least 3.0.0 to work -with Windows 64 bit systems. On Linux, 2.0.0 also works fine. - -If no external spell checking tool is installed, novelWriter will use a basic spell checker based -on standard Python package `difflib`. Currently, only English dictionaries are available for this -spell checker, but more can be added to the `nw/assets/dict` folder. See the -[README](nw/assets/dict/README.md) file in that folder for how to generate more dictionaries. Note -that the difflib-based option is both slow and limited. +For Windows, you can either install via PyPi, or use the Windows installer available from the +[releases](https://github.com/vkbo/novelWriter/releases) page. ## Debugging @@ -257,7 +182,7 @@ to quickly navigate between the documents while editing. This is Open Source software, and novelWriter is licensed under GPLv3. See the [GNU General Public License website](https://www.gnu.org/licenses/gpl-3.0.en.html) for more -details, or consult the [LICENSE](LICENSE.md) file. +details, or consult the [LICENSE](https://github.com/vkbo/novelWriter/blob/main/LICENSE.md) file. Bundled assets have the following licenses: From adc17272dcf09785633d3bf6c1b028dafa6579c4 Mon Sep 17 00:00:00 2001 From: "Veronica K. B. Olsen" <1619840+vkbo@users.noreply.github.com> Date: Tue, 19 Jan 2021 20:17:15 +0100 Subject: [PATCH 08/10] Updated changelog with latest changes --- CHANGELOG.md | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d1162cdf..9a02b966 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,12 @@ ### Detailed Changelog +**Installation** + +* The dependency list was missing in the setup configuration for PyPi due to a bug in the + `setup.cfg` file. The dependencies have been moved to a different section where the setup tool + now picks them up properly. Issue #570, PR #573 by @stranger-danger-zamu. + **Bug Fixes** * Fixed an issue with note files being moved between a non-novel root folder and a novel root @@ -13,14 +19,20 @@ duplicate entries for such a file. PR #558. * Fixed a cosmetic issue where the meta data panel below the project tree was not cleared when the project was closed. PR #559. -* Fixed an issue where the main window title was not cleared when a project was closed, and the new - title not set when a new project was first created. Issue #560, PR #561. +* Fixed an issue where the main window title would not be cleared when a project was closed, and + the new title not set when a new project was first created. Issue #560, PR #561. +* The editor context menu option to "Add Word to Dictionary" should also be visible when there are + no spell checker suggestions. The entry was erroneously added under an if-condition that excluded + it in those cases. Issue #574, PR #575. **Documentation** * Fixed some typos and spelling mistakes in the documentation, and reworded parts of the text that - were unclear. The technical page has also been extended with more information of project folder + were unclear. The technical page has also been extended with more information on project folder structure. PR #557. +* Clarify install instructions, and remove the duplicate instructions in the README file and + replace them with a brief section. The full instructions are in the documentation. Issues #566 + and #570, PR #576. ---- From 447966e3b826428535c884ef8e8ce0ad4dfdc353 Mon Sep 17 00:00:00 2001 From: "Veronica K. B. Olsen" <1619840+vkbo@users.noreply.github.com> Date: Tue, 19 Jan 2021 20:56:29 +0100 Subject: [PATCH 09/10] Changed release date and updated release notes --- CHANGELOG.md | 6 +++++- nw/__init__.py | 2 +- nw/assets/text/release_notes.htm | 14 +++++++++++--- sample/nwProject.nwx | 6 +++--- 4 files changed, 20 insertions(+), 8 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9a02b966..8a875128 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,9 +1,13 @@ # novelWriter Change Log -## Version 1.0.2 [2021-01-24] +## Version 1.0.2 [2021-01-19] ### Release Notes +This patch release fixes a few minor cosmetic issues, a minor issue with the indexer, and a bug +when adding words to the user's own spell check dictionary. Additionally, the documentation has +been updated based on user feedback, and some install issues resolved. + ### Detailed Changelog **Installation** diff --git a/nw/__init__.py b/nw/__init__.py index f0d09ff3..02438d68 100644 --- a/nw/__init__.py +++ b/nw/__init__.py @@ -65,7 +65,7 @@ __maintainer__ = "Veronica Berglyd Olsen" __email__ = "code@vkbo.net" __version__ = "1.0.2" __hexversion__ = "0x010002f0" -__date__ = "2021-01-24" +__date__ = "2021-01-19" __status__ = "Stable" __domain__ = "novelwriter.io" __url__ = "https://novelwriter.io" diff --git a/nw/assets/text/release_notes.htm b/nw/assets/text/release_notes.htm index f1a9bfaa..cdee0872 100644 --- a/nw/assets/text/release_notes.htm +++ b/nw/assets/text/release_notes.htm @@ -2,6 +2,17 @@
+Released on 19 January 2021
+This patch release fixes a few minor cosmetic issues, a minor issue with the indexer, and a bug +when adding words to the user's own spell check dictionary. Additionally, the documentation has +been updated based on user feedback, and some install issues resolved.
+ +The full changelog is available +here.
+ +Released on 10 January 2021
This release is mainly to bring the documentation up to date, as I forgot to update the install @@ -13,9 +24,6 @@ issues with the document and project changed icons on the status bar have also b indicators were previously set to changed status even if no actual change had been made to the project.
-The full changelog is available -here.
-