From 23b3dc3d6ed847685c4e56a0f3c3f2225f26eeb2 Mon Sep 17 00:00:00 2001 From: Marc Jakobi Date: Sun, 5 Nov 2023 21:54:50 +0100 Subject: [PATCH] fix(health): broken tree-sitter parser check --- CHANGELOG.md | 4 ++++ lua/neotest-haskell/health.lua | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4b8b254..7ce5fe0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,10 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.0.2] - 2023-11-05 +### Fixed +- Health check: Fix broken tree-sitter parser check. + ## [1.0.1] - 2023-10-29 ### Changed - Remove `plenary.nvim` dependency. diff --git a/lua/neotest-haskell/health.lua b/lua/neotest-haskell/health.lua index 12e4802..a7a5ae6 100644 --- a/lua/neotest-haskell/health.lua +++ b/lua/neotest-haskell/health.lua @@ -138,8 +138,8 @@ function health.check() end start('Checking tree-sitter parsers') - local ok = pcall(vim.treesitter.get_string_parser, '', 'haskell') - if not ok then + local success = pcall(vim.treesitter.get_string_parser, '', 'haskell') + if not success then error('The tree-sitter parser for Haskell is not installed.') else ok('The tree-sitter parser for Haskell is installed.')