I've hit the same bug as described in https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=225213. The root of the problem seems to be missing configuration file which should be placed somewhere and made accessible by chktex. It is used by, for example, tex-mode in Emacs.
cc @vcunat
cc @vcunat
I'm just getting this warning:
chktex: WARNING -- Could not find global resource file.
Otherwise the output seems normal to me, but I've never really used the utility.
Oh, I see, -v is still a problem, as it used to be in Debian.
Actually, that config file is provided by chktex package, so if I include it in texlive.combine, it works fine even with -v.
Still, it's a bit confusing that the core provides chktex binary but doesn't fully support it.
I currently can't see a simple way how to improve that.
I am not able to use chktex on emacs because it does not accept the option --verbosity=0. In the command line I get:
$ chktex --verbosity=0
chktex: WARNING -- Could not find global resource file.
chktex: ERROR -- Illegal verbosity level.
Is it related to this issue, or should I report a new issue?
cc @vcunat
When explicitly adding chktex to texlive.combine there are checksum errors. The following patch fixes it for me:
diff --git a/pkgs/tools/typesetting/tex/texlive-new/fixedHashes.nix b/pkgs/tools/typesetting/tex/texlive-new/fixedHashes.nix
index 130c063..3134f9d 100644
--- a/pkgs/tools/typesetting/tex/texlive-new/fixedHashes.nix
+++ b/pkgs/tools/typesetting/tex/texlive-new/fixedHashes.nix
@@ -353,8 +353,8 @@
"bibtexu.doc-2015"="yppzw0banxngki9dzgm7dlm8cr9vnxya";
"bundledoc-3.2"="k3x1sdf7244dr1zi3san9xmvislq7k8x";
"bundledoc.doc-3.2"="fkw0kw3wzyrl2gs3rdq5hrrk8yjsjznd";
-"chktex-1.7.2"="ap8080aajx0wdi73i6cni1ysczlbmd52";
-"chktex.doc-1.7.2"="c1992w9jc2hyhgj3vkhivhhifqppdmrv";
+"chktex-1.7.4"="8a92aw3pmfm3jwyjyx4w67igj60hnyr3";
+"chktex.doc-1.7.4"="d1992w9jc2hyhgj3vkhivhhifqppdmrv";
"ctan_chk.doc-1.0"="m4i1vj19h48zyk9pxadfq1qrwmvqy3i1";
"ctanify-1.5"="5shi1i1vm1anxzqhy0s673vin786fba7";
"ctanify.doc-1.5"="bnb9bfq1b1hmi5nyqxvs9r55psamjayb";
diff --git a/pkgs/tools/typesetting/tex/texlive-new/pkgs.nix b/pkgs/tools/typesetting/tex/texlive-new/pkgs.nix
index 62de54c..f2448c7 100644
--- a/pkgs/tools/typesetting/tex/texlive-new/pkgs.nix
+++ b/pkgs/tools/typesetting/tex/texlive-new/pkgs.nix
@@ -3212,10 +3212,10 @@ tl: { # no indentation
version = "0.1";
};
"chktex" = {
- md5.run = "5985f5a591f03571f3d644afbfd40355";
- md5.doc = "e4f8696eb259ddf7fe980bdb215fee0e";
+ md5.run = "8263d8aeff53dacb7214615f53e025db";
+ md5.doc = "f4f8696eb259ddf7fe980bdb215fee0e";
hasRunfiles = true;
- version = "1.7.2";
+ version = "1.7.4";
};
"chletter" = {
stripPrefix = 0;
With that, chktex does not give the Illegal verbosity level error anymore.
Oh, no, they're updating files in-place on the only mirror. Many of them won't download anymore :angry:
Better discuss the mirroring stuff at this thread: https://github.com/NixOS/nixpkgs/issues/10026#issuecomment-207384934.
triage: this might have been fixed in the meantime, is that so?
@Profpatsch it's still necessary to explicitly add the chktex package, otherwise the problem persists.
Could anyone, please, provide steps to reproduce?
The "chktex -v" works for me, I have texlive.combined.scheme-full installed with nix-env.
chktex -v works in texlive.combined.scheme-medium but not texlive.combined.scheme-small.
$ nix-shell --pure -p texlive.combined.scheme-small --run 'chktex -v /dev/null'
chktex: WARNING -- Could not find global resource file.
chktex: ERROR -- Illegal verbosity level.
$ nix-shell --pure -p texlive.combined.scheme-medium --run 'chktex -v /dev/null'
ChkTeX v1.7.6 - Copyright 1995-96 Jens T. Berger Thielemann.
Compiled with POSIX extended regex support.
No errors printed; No warnings printed; No user suppressed warnings; No line suppressed warnings.
$ nix-info
system: "x86_64-linux", multi-user?: yes, version: nix-env (Nix) 2.3.7, channels(root): "nixos-21.03pre243690.441a7da8080", channels(anders): "", nixpkgs: /nix/var/nix/profiles/per-user/root/channels/nixos