1
0
Fork 0
Go to file
Renovate Bot 33bd67509c update: update dependency @microsoft/api-extractor to v7.5.1 2019-10-18 13:20:52 -05:00
.github lint(github): add PR template title 2019-09-23 08:25:00 -05:00
config feat(build): externalize rollup data 2019-09-29 16:06:03 -05:00
docs/api fix(build): move index back to its own chunk 2019-09-18 09:05:16 -05:00
scripts feat: include additional makefiles, add example 2019-09-28 15:24:51 -05:00
src feat(build): externalize rollup data 2019-09-29 16:06:03 -05:00
test fix: rename main app method to main, remove redundant wrapper 2019-09-29 10:03:26 -05:00
vendor/rollup-resources fix: declare resource modules 2019-09-28 10:42:41 -05:00
.codeclimate.yml fix(lint): ignore style code 2019-09-28 15:23:34 -05:00
.dockerignore fix(build): add yarn lock to image before installing, add tmp files to docker ignore 2019-09-17 19:05:46 -05:00
.gitignore feat(build): bundle json and yaml with TS typedefs 2019-09-28 04:37:33 -05:00
.gitlab-ci.yml feat: include additional makefiles, add example 2019-09-28 15:24:51 -05:00
.npmignore fix(build): pick a unique package name 2019-09-18 03:56:31 -05:00
.npmrc feat(config): configure npm to use nexus mirror 2019-09-17 08:18:09 -05:00
CHANGELOG.md chore(release): 0.2.1 2019-09-18 04:41:53 -05:00
Dockerfile fix(build): add packages to image before output 2019-09-17 19:09:24 -05:00
LICENSE.md feat: copy template from other projects 2019-09-17 07:45:15 -05:00
Makefile fix: use index as entry point for run targets 2019-09-29 07:25:16 -05:00
README.md lint(github): add headers to issue template, lint line length 2019-09-23 08:21:25 -05:00
package.json update: update dependency @microsoft/api-extractor to v7.5.1 2019-10-18 13:20:52 -05:00
renovate.json feat: copy template from other projects 2019-09-17 07:45:15 -05:00
run.mk feat: include additional makefiles, add example 2019-09-28 15:24:51 -05:00
tsconfig.json feat: copy template from other projects 2019-09-17 07:45:15 -05:00
yarn.lock update: update dependency @microsoft/api-extractor to v7.5.1 2019-10-18 13:20:52 -05:00

README.md

Rollup Template

This project contains the base configuration and build scripts for most of my Typescript projects, along with scripts to createe a new project.

Pipeline status MIT license

Renovate badge Known vulnerabilities Dependency status Dev dependency status

Maintainability score Test Coverage Technical debt ratio Quality issues

Contents

Features

  • build scripts with make
  • build pipeline with gitlab
    • update github commit status
    • publish docker images from branches & tags
    • publish npm packages from tags
  • bundled with rollup
  • type checked with typescript
  • style checked with tslint (and plugins)
  • tested with mocha (with source map support and helpers for async leak tracking)
  • code coverage measured with nyc
  • changelog generated with standard-release

Intentionally Omitted Features

  • everything frontend: React, CSS, etc
  • heavy backend libraries: ORMs, etc

Usage

To Setup

To create a new repository from this template:

  • create your new repo on Github & Gitlab (your server or Gitlab.com)
  • git clone git@github.com:ssube/rollup-template.git your-project
  • cd your-project
  • git remote add github git@github.com:yourname/your-project.git
  • git remote add gitlab git@gitlab.com:yourname/your-project.git
  • set up repository mirroring in Gitlab
  • set up some maintenance bots
  • make git-push
  • install your dependencies
  • write some code

To Build

Once your project is set up:

  • make to bundle and test
  • commit
  • make git-push

The git-push target pushes to Github first, to avoid conflicts with changes from bots and other contributors.

To Release

When your project is ready to release:

  • make release-dry to make sure your changelog and options look right
  • make release

Additional options can be passed with the RELEASE_OPTS variable. Frequently used options include --release-as minor and --prerelease.

External Services

This template works with or expects a few external services, namely a Gitlab CI server (self-hosted or using Gitlab.com).

Maintenance Bots

Good tests and clever bots can eliminate the most painful parts of project maintenance. This repository is configured to work with:

None of these are required, but Renovate and Snyk can be very helpful when dependencies release a security patch (and even more so when they decline).

External Secrets

This template expects a few secrets to exist in the environment, including tokens for the external services.

Name Description
CC_TEST_REPORTER_ID code climate ID
CODECLIMATE_SECRET code climate token
CODECOV_SECRET codecov token
DOCKER_SECRET docker config, required for publishing images
GITHUB_SECRET github.com token, required for publishing status
NPM_SECRET npmjs.com token, required for publishing npm packages
SONAR_SECRET sonarcloud token

Secrets should be provided as environment variables, with the secret value base64-encoded.