@tapjs/config
Utility loading and managing tap configuration
Last updated a year ago by isaacs .
BlueOak-1.0.0 · Repository · Bugs · Original npm · Tarball · package.json
$ npm install @tapjs/config 
SYNC missed versions from official npm registry.

@tapjs/config

This is the library that tap uses to manage configuration coming from the command line options, environment variables, and config files.

Configuring Node Tap

Tap will look for configuration data first in a .taprc file in the project root, and then in the "tap" object in the project package.json file. ('Project root' means the nearest folder at or above the current working directory containing package.json, .taprc, or .git.)

The config object may set any of the following fields, as well as the special "extends" field, which may specify either a package name or file name, relative to the config file that references it.

If the "extends" field resolves to a file on disk, then that will be read as the base configuration object. (It may also extend yet another config file, and so on.)

If the "extends" field specifies a package name, then it must be resolveable in the node_modules folder of the file extending it. That package must contain either a .taprc file, or a package.json file with a "tap" object.

To see the format used in a .taprc file, run the tap dump-config command with the desired options specified on the command line.

Additionally, all config options that are modified from their defaults will be set in the environment with the TAP_ prefix, and will be read from the environment if so specified. For example, specifying --omit-version on the command line, or omit-version: true in a .taprc file, will set TAP_OMIT_VERSION=1 in the environment.

Environment and CLI options take priority over any config files.

Class TapConfig

This is the main interface for dealing with tap configuration.

The typical way to use this is by calling await TapConfig.load() to get a LoadedConfig object, which is an instance of TapConfig that has been fully loaded with all relevant settings.

The full list of methods and properties are available in the typedocs

Current Tags

  • 5.0.0                                ...           latest (4 months ago)
  • 2.0.0                                ...           pre (a year ago)

73 Versions

  • 5.0.0                                ...           4 months ago
  • 4.0.3                                ...           5 months ago
  • 4.0.2                                ...           5 months ago
  • 4.0.1                                ...           5 months ago
  • 4.0.0                                ...           5 months ago
  • 3.1.6                                ...           5 months ago
  • 3.1.5                                ...           5 months ago
  • 3.1.4                                ...           5 months ago
  • 3.1.3                                ...           5 months ago
  • 3.1.2                                ...           5 months ago
  • 3.1.1                                ...           5 months ago
  • 3.1.0                                ...           5 months ago
  • 3.0.1                                ...           6 months ago
  • 3.0.0                                ...           6 months ago
  • 2.4.19                                ...           6 months ago
  • 2.4.18                                ...           6 months ago
  • 2.4.17                                ...           8 months ago
  • 2.4.16                                ...           8 months ago
  • 2.4.15                                ...           10 months ago
  • 2.4.14                                ...           a year ago
  • 2.4.13                                ...           a year ago
  • 2.4.12                                ...           a year ago
  • 2.4.11                                ...           a year ago
  • 2.4.10                                ...           a year ago
  • 2.4.9                                ...           a year ago
  • 2.4.8                                ...           a year ago
  • 2.4.7                                ...           a year ago
  • 2.4.6                                ...           a year ago
  • 2.4.5                                ...           a year ago
  • 2.4.4                                ...           a year ago
  • 2.4.3                                ...           a year ago
  • 2.4.2                                ...           a year ago
  • 2.4.1                                ...           a year ago
  • 2.4.0                                ...           a year ago
  • 2.3.3                                ...           a year ago
  • 2.3.2                                ...           a year ago
  • 2.3.1                                ...           a year ago
  • 2.3.0                                ...           a year ago
  • 2.2.0                                ...           a year ago
  • 2.1.2                                ...           a year ago
  • 2.1.1                                ...           a year ago
  • 2.1.0                                ...           a year ago
  • 2.0.3                                ...           a year ago
  • 2.0.2                                ...           a year ago
  • 2.0.1                                ...           a year ago
  • 2.0.0                                ...           a year ago
  • 2.0.0-23                                ...           a year ago
  • 2.0.0-22                                ...           a year ago
  • 2.0.0-21                                ...           a year ago
  • 2.0.0-20                                ...           a year ago
  • 2.0.0-19                                ...           a year ago
  • 2.0.0-18                                ...           a year ago
  • 2.0.0-17                                ...           a year ago
  • 2.0.0-16                                ...           a year ago
  • 2.0.0-15                                ...           a year ago
  • 2.0.0-14                                ...           a year ago
  • 2.0.0-13                                ...           a year ago
  • 2.0.0-12                                ...           a year ago
  • 2.0.0-11                                ...           a year ago
  • 2.0.0-10                                ...           a year ago
  • 2.0.0-9                                ...           a year ago
  • 2.0.0-8                                ...           a year ago
  • 2.0.0-7                                ...           a year ago
  • 2.0.0-6                                ...           a year ago
  • 2.0.0-5                                ...           a year ago
  • 2.0.0-4                                ...           a year ago
  • 2.0.0-3                                ...           a year ago
  • 2.0.0-2                                ...           a year ago
  • 2.0.0-1                                ...           a year ago
  • 2.0.0-0                                ...           a year ago
  • 1.0.2                                ...           2 years ago
  • 1.0.1                                ...           2 years ago
  • 1.0.0                                ...           2 years ago
Maintainers (2)
Downloads
Total 4
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 1
Dependencies (4)
Dev Dependencies (0)
None
Dependents (2)

© 2010 - cnpmjs.org x YWFE | Home | YWFE