New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

yandex-domain-configs

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

yandex-domain-configs

Yandex Domain Configs

  • 0.0.4
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
decreased by-100%
Maintainers
1
Weekly downloads
 
Created
Source

yandex-domain-configs

Tool for generating static domain configs.

Benefits

  1. Simple config inheritance.
  2. Simple domain config inheritance.
  3. Config validation against JSON-schema.
  4. Customizing domain list for different environments.

Installation

npm:

npm install --save-dev yandex-domain-configs

yarn:

yarn add -D yandex-domain-configs

Usage

npm:

node_modules/.bin/yandex-domain-configs [options]

yarn:

yarn yandex-domain-configs -- [options]

Options

    -i, --input <filename>      Input file
    -o, --output-dir <dirname>  Output directory
    -s, --schema <filename>     JSON Schema
    -h, --help                  output usage information

Example

config.base.yaml:

# default settings
foo: 0
# objects are merged recursively when overriden
bar:
  baz: 1
# domain settings override the default ones
$domains:
  yandex.ru
    foo: 2
  yandex.com
    # yandex.com will inherit settings from yandex.ru
    $extends: yandex.ru
    bar:
      baz: 3

config.production.yaml:

$extends: config.base.yaml
# these settings override the default ones in the base config
bar:
  baz: 5
# domains not listed here will be ignored
$domainList:
  - yandex.ru
  - yandex.com
# these settings override domain settings in the base config
$domains:
  yandex.ru
    foo: 6

config.schema.yaml:

title: Project configuration
type: object
required:
  - foo
  - bar
properties:
  foo:
    title: Foo description
    type: integer
  bar:
    title: Bar description
    type: object
    required:
      - baz
    properties:
      baz:
        title: Baz description
        type: integer

Command

yarn yandex-domain-configs -- -i config.production.xml -o production -s config.schema.yaml

Result

production/yandex.ru.json:

{
    "foo": 6,
    "bar": {
        "baz": 5
    }
}

production/yandex.com.json:

{
    "foo": 6,
    "bar": {
        "baz": 3
    }
}

FAQs

Package last updated on 31 Jan 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc