{"id":15491,"library":"ut-tools","title":"UT Tools for Build and Release Automation","description":"ut-tools is a suite of command-line interface (CLI) scripts designed for continuous integration, continuous delivery, and general automation tasks within JavaScript projects. It provides a pre-configured set of utilities for common CI/CD workflows, including generating changelogs (`ut-changelog`), running tests (`ut-test`), checking code coverage (`ut-cover`), linting JavaScript and CSS files (`ut-lint`, `ut-lint-js`, `ut-lint-css`), and automating release processes (`ut-release`, `ut-release-lerna`). Currently at version 7.13.2, the package has shifted its primary installation model since version 7, requiring global installation rather than being added to `devDependencies` to optimize `npm install` performance. It is intended for direct use within `package.json` scripts or as standalone CLI commands, not as a library for programmatic import.","status":"active","version":"7.13.2","language":"javascript","source_language":"en","source_url":"ssh://git@github.com/softwaregroup-bg/ut-tools","tags":["javascript","build","release","ci","Continuous Integration","Integration","Continuous"],"install":[{"cmd":"npm install ut-tools","lang":"bash","label":"npm"},{"cmd":"yarn add ut-tools","lang":"bash","label":"yarn"},{"cmd":"pnpm add ut-tools","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Runtime environment requirement","package":"node","optional":false},{"reason":"Package manager requirement for installation and scripts","package":"npm","optional":false}],"imports":[{"note":"This package primarily exposes CLI commands, not library functions for programmatic import. Use directly in package.json scripts or via npx.","wrong":"import { changelog } from 'ut-tools'","symbol":"ut-changelog","correct":"ut-changelog"},{"note":"Invoke ut-lint as a shell command. It's not a JavaScript module to be imported.","wrong":"const lint = require('ut-tools/lint');","symbol":"ut-lint","correct":"ut-lint"},{"note":"Execute ut-release as a command-line utility for managing package versions and publishing.","wrong":"import { release } from 'ut-tools';","symbol":"ut-release","correct":"ut-release"}],"quickstart":{"code":"npm install -g ut-tools\n\n// Add to your project's package.json scripts\n// Example: package.json\n/*\n{\n  \"name\": \"my-project\",\n  \"version\": \"1.0.0\",\n  \"scripts\": {\n    \"lint\": \"ut-lint\",\n    \"test\": \"ut-test\",\n    \"release\": \"ut-release\"\n  }\n}\n*/\n\n// Then run from your project directory\nnpm run lint\n","lang":"javascript","description":"Demonstrates global installation and usage of ut-tools commands within package.json scripts."},"warnings":[{"fix":"Remove `ut-tools` from your `package.json` `devDependencies` and install it globally using `npm install -g ut-tools`.","message":"Since version 7, ut-tools must be installed globally (`npm install -g ut-tools`) rather than as a `devDependencies` entry. Installing it locally will not provide the expected CLI commands and may slow down `npm install` processes.","severity":"breaking","affected_versions":">=7.0.0"},{"fix":"Add the following to your VSCode settings (user or workspace): `\"eslint.options\": { \"overrideConfigFile\": \"/path/to/global/npm/node_modules/ut-tools/eslint/.eslintrc.js\" }, \"eslint.nodePath\": \"/path/to/global/npm/node_modules/ut-tools/node_modules\"`. Replace `/path/to/global/npm/node_modules` with your actual global npm modules path (e.g., `npm root -g`).","message":"Configuring VSCode ESLint to use ut-tools's predefined rules requires specific workspace or user settings. Incorrect paths will result in VSCode not applying the linting rules or reporting errors.","severity":"gotcha","affected_versions":">=7.0.0"},{"fix":"Use the provided scripts as CLI commands in your `package.json` or directly from the terminal. For example, `npm run lint` or `ut-lint`.","message":"ut-tools is designed as a collection of command-line utilities and is not intended for programmatic `import` or `require()` within JavaScript or TypeScript application code. Attempting to import symbols directly will fail.","severity":"gotcha","affected_versions":">=1.0.0"}],"env_vars":null,"last_verified":"2026-04-21T00:00:00.000Z","next_check":"2026-07-20T00:00:00.000Z","problems":[{"fix":"Ensure `ut-tools` is installed globally by running `npm install -g ut-tools`. Verify your system's PATH includes the global npm bin directory.","cause":"The `ut-tools` package was not installed globally, or the global `node_modules` bin directory is not in your system's PATH.","error":"Error: Command 'ut-lint' not found"},{"fix":"Find the correct global installation path of `ut-tools` (e.g., `npm root -g`) and update your VSCode settings with the precise path to the `.eslintrc.js` file.","cause":"The `eslint.options.overrideConfigFile` setting in VSCode uses an incorrect or unresolvable path to the `ut-tools` ESLint configuration.","error":"ESLint: Cannot read config file: '/enter the installation path here/ut-tools/eslint/.eslintrc.js'"},{"fix":"Remove `ut-tools` from your `devDependencies` in `package.json` and ensure it is installed globally (`npm install -g ut-tools`).","cause":"Prior to v7, `ut-tools` was often listed as a `devDependency`. Since v7, it is designed for global installation, and local installation adds unnecessary overhead.","error":"npm install takes a long time, even for small projects."}],"ecosystem":"npm"}