11.0.0 • Published 4 months ago

screwdriver-config-parser v11.0.0

Weekly downloads
115
License
BSD-3-Clause
Repository
github
Last release
4 months ago

Screwdriver.yaml Configuration Parser

Version Downloads Build Status Open Issues License

Node module for validating and parsing screwdriver.yaml configurations

  • Validates a screwdriver.yaml for structural and functional specification
  • Outputs the pipeline's workflowGraph configuration
  • Generates a list of jobs to execute, including:
    • build permutations
    • environment variables to set
    • steps to execute
    • container image to use

YAML

shared:
    environment:
        NODE_ENV: test
    settings:
        email: foo@bar.com

jobs:
    main:
        image: node:18
        steps:
            - init: npm install
            - test: npm test
        requires:
            - ~pr
            - ~commit

    publish:
        environment:
            NODE_TAG: latest
        image: node:4
        steps:
            - bump: npm run bump
            - publish: npm publish --tag $NODE_TAG
            - tag: git push origin --tags
        secrets:
            - NPM_TOKEN
            - GIT_KEY
        requires:
            - main

Usage

npm install screwdriver-config-parser

Parse in Node.js:

const parser = require('screwdriver-config-parser');

// Configuration (in YAML form)
parser(fs.readFileSync('screwdriver.yaml')).then((pipeline) => {
    // Workflow for the pipeline
    // pipeline.workflowGraph

    // All the main jobs with the steps to execute and environment variables to set
    // pipeline.jobs.main[].commands
    // pipeline.jobs.main[].environment
    // pipeline.jobs.main[].image

    // All the publish jobs with the steps to execute and environment variables to set
    // pipeline.jobs.publish[].commands
    // pipeline.jobs.publish[].environment
    // pipeline.jobs.publish[].image
});

Testing

npm test

License

Code licensed under the BSD 3-Clause license. See LICENSE file for terms.

11.0.0

4 months ago

10.4.1

6 months ago

10.4.2

5 months ago

10.4.3

5 months ago

10.4.4

5 months ago

10.4.0

6 months ago

10.3.0

6 months ago

10.2.0

6 months ago

10.1.1

7 months ago

10.1.2

7 months ago

10.1.3

7 months ago

10.0.1

7 months ago

10.1.0

7 months ago

10.0.0

8 months ago

9.2.0

9 months ago

9.1.0

10 months ago

9.0.1

10 months ago

9.0.0

10 months ago

8.3.0

10 months ago

8.2.1

10 months ago

8.2.0

10 months ago

8.1.0

10 months ago

8.0.4

10 months ago

8.0.3

1 year ago

8.0.2

1 year ago

8.0.1

2 years ago

8.0.0

2 years ago

7.6.1

2 years ago

7.5.5

3 years ago

7.6.0

3 years ago

7.5.3

3 years ago

7.5.4

3 years ago

7.5.2

3 years ago

7.5.1

3 years ago

7.5.0

3 years ago

7.4.0

3 years ago

7.3.0

3 years ago

7.2.0

3 years ago

7.1.4

4 years ago

7.1.3

4 years ago

7.1.2

4 years ago

7.1.1

4 years ago

7.1.0

4 years ago

7.0.0

4 years ago

6.4.0

4 years ago

6.3.2

4 years ago

6.3.1

4 years ago

6.3.0

4 years ago

6.2.2

4 years ago

6.2.1

4 years ago

6.2.0

4 years ago

6.1.2

4 years ago

6.1.0

4 years ago

6.1.1

4 years ago

6.0.1

4 years ago

6.0.0

4 years ago

5.4.0

4 years ago

5.3.5

4 years ago

5.3.4

5 years ago

5.3.3

5 years ago

5.3.2

5 years ago

5.3.1

5 years ago

5.3.0

5 years ago

5.2.0

5 years ago

5.1.0

5 years ago

5.0.0

5 years ago

4.11.6

5 years ago

4.11.5

5 years ago

4.11.4

5 years ago

4.11.3

5 years ago

4.11.2

6 years ago

4.11.1

6 years ago

4.11.0

6 years ago

4.10.0

6 years ago

4.9.0

6 years ago

4.8.0

6 years ago

4.7.0

6 years ago

4.6.1

6 years ago

4.6.0

6 years ago

4.5.4

6 years ago

4.5.3

6 years ago

4.5.2

6 years ago

4.5.1

6 years ago

4.5.0

6 years ago

4.4.1

6 years ago

4.4.0

6 years ago

4.3.1

7 years ago

4.3.0

7 years ago

4.2.1

7 years ago

4.2.0

7 years ago

4.1.1

7 years ago

4.1.0

7 years ago

4.0.0

7 years ago

3.14.3

7 years ago

3.14.2

7 years ago

3.14.1

7 years ago

3.14.0

7 years ago

3.13.6

7 years ago

3.13.5

7 years ago

3.13.4

7 years ago

3.13.3

7 years ago

3.13.2

7 years ago

3.13.1

7 years ago

3.13.0

7 years ago

3.12.1

7 years ago

3.12.0

7 years ago

3.11.1

7 years ago

3.11.0

7 years ago

3.10.1

7 years ago

3.10.0

7 years ago

3.9.0

7 years ago

3.8.0

7 years ago

3.7.0

8 years ago

3.6.0

8 years ago

3.5.2

8 years ago

3.5.1

8 years ago

3.5.0

8 years ago

3.4.1

8 years ago

3.4.0

8 years ago

3.3.1

8 years ago

3.3.0

8 years ago

3.2.4

8 years ago

3.2.3

8 years ago

3.2.2

8 years ago

3.2.1

8 years ago

3.2.0

8 years ago

3.1.1

8 years ago

3.1.0

8 years ago

3.0.5

8 years ago

3.0.4

8 years ago

3.0.3

8 years ago

3.0.2

8 years ago

3.0.1

8 years ago

3.0.0

8 years ago

2.1.4

8 years ago

2.1.3

8 years ago

2.1.2

8 years ago

2.1.1

8 years ago

2.1.0

8 years ago

2.0.1

8 years ago

2.0.0

8 years ago

1.0.2

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago

0.1.0

8 years ago

0.0.1

8 years ago