dorpheus-card-generator
TypeScript icon, indicating that this package has built-in type declarations

0.2.0 • Public • Published

dorpheus-card-generator

Creates a html and pdf file from the tickets in the current active sprint.

Usage as a library

index.js exports a single method called jiraToPdf() which takes a properties object, and responds with a html-pdf CreateResult.

The CreateResult can be converted to a buffer with toBuffer, or to a file with toFile.

For example;

function getJiraPdfAsBuffer(props: IProperties) {
    return jiraToPdf(props)
        .then((createResult) => {
            return new Promise<Buffer>((resolve, reject) =>
                createResult.toBuffer((err, buffer) =>
                    buffer && resolve(buffer) || reject(err);));
        });
}

Running as Standalone

To run as a standalone application;

$ npm i
$ npm run build
$ npm run start
    # Do something with out.pdf/out.html

The standalone application depends on the following properties being defined in your ~/.gradle/gradle.properties

$ cat ~/.gradle/gradle.properties
jiraUrl=https://org.atlassian.net
jiraUsername=user@org.com
jiraPassword=hunter12
jiraBoardId=123

Package Sidebar

Install

npm i dorpheus-card-generator

Weekly Downloads

2

Version

0.2.0

License

MIT

Unpacked Size

119 kB

Total Files

29

Last publish

Collaborators

  • metapack-dorpheus
  • oliver_paraskos_metapack