Skip to content

Instantly share code, notes, and snippets.

@hmil
Created August 31, 2018 14:40

Revisions

  1. hmil created this gist Aug 31, 2018.
    14 changes: 14 additions & 0 deletions makefile.ts
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,14 @@
    import build from 'awesome-build-system'

    compiled = build.createTarget('/dist/app.js', () => {
    build.exec('tsc -p tsconfig.json')
    })

    packaged = build.createTarget('/dist/package.tar.gz', [ compiled ], () => {
    build.exec('npm pack')
    build.exec(`cp artifact.tar.gz ${packaged}`)
    })

    deploy = build.createVirtualTarget([ packaged ], () => {
    build.exec('npm publish')
    })