While not documented as such, it appears that the repository record is
required with trusted publishing of npm packages.
Test-bot: skip
Build-bot: skip
Fixes#8795.
Relates to #9090.
Cleans up and makes consistent compiler messages in kmc, and related
unit tests.
Adds support for colorized messages.
After installing chalk for ansi coloring in kmc, @types/node needed to
be brought in sync with the Typescript version, per the suggestion of
checking against `npm dist-tags @types/node`,found in a discussion at
https://github.com/DefinitelyTyped/DefinitelyTyped/discussions/64262#discussioncomment-4905069
Additional tidying up includes:
* Deprecating a set of functions in compiler-interfaces, bringing them
together under a new CompilerError class.
Separating CompilerErrorSeverity and CompilerErrorMask enums.
* Making CompilerError.formatEvent (formerly compilerEventFormat) print
messages in the same format as NodeCompilerCallbacks (sans coloring).
* Adding a wrapper class for CompilerCallbacks that manages the filename
reporting, used currently exclusively by kmc itself.
The build/ folder for most packages was missing due to being listed in
.gitignore.
Also, @keymanapp/ldml-keyboard-constants package was not being published
despite being a dependency of @keymanapp/kmc-keyboard.
Instead of relying on npm's use of .gitignore / .npmignore (which has
seriously wonky behaviours), we list the files that should be included
in package.json.
NPM Wonky behaviours: it seems that .npmignore causes .gitignore in the
same folder to be ignored. But, higher level .gitignore files still
affect the files included in the package, which makes
specification-by-exclusion painful (negating exclusions, etc). We do not
recommend use of .npmignore anywhere for this reason.
As KEYMAN-VERSION changed from being a type to a class, this broke the
bundling and referencing strategies in Developer/Server and
Developer/kmlmc. This updates the bundling process and fixes the
references in both projects.
Note that keyman-version no longer depends on gosh. Given we are
currently manually calling the build for this in all projects (or should
be!), it's better that we keep the build of this explicit for now.
If we want to restore the postinstall/postci steps in the future, the
gosh dependency would need to be manually removed from package.json in
order for the bundling builds to work for Developer/Server and
Developer/kmlmc.
Starts to resolve the chaos of putting version numbers into every
package.json file.
Adds a new keyman-version package which mimics the
version information in build-utils.sh. This will eventually replace
resources/web-environment.
Fixes the build for the lexical model compiler tools to remove refs to
package.json version and use keyman-version instead.
More fixes coming in a follow-up.