0.2.0 • Published 4 years ago

grunt-publish-github-drafts v0.2.0

Weekly downloads
5
License
MIT
Repository
github
Last release
4 years ago

grunt-publish-github-drafts NPM Test

A Grunt task to publish release drafts on GitHub.

This task searches for a release draft with a given tag name. If the draft is found, the task attaches the tag (if it exists) to this release, then publishes the release.

Usage

You can install grunt-publish-github-drafts by a following way:

> npm install --save-dev grunt-publish-github-drafts

Then you can add a configuration section for publish_github_drafts task in your Gruntfile.js:

// If you don't use a `load-grunt-tasks` module,
// you should load `grunt-publish-github-drafts` directly.
grunt.loadNpmTasks('grunt-publish-github-drafts');

grunt.initConfig({
	publish_github_drafts: {
		owner: 'username/organization',
		repo: 'repository name',
		token: 'GitHub token',
		tag: 'Tag to search',
	}
});

Workflow

  1. Create a new draft reserved for a new version, and name it in a semver format, e.g. v0.1.0.
  2. Update a description of the draft during development, if neccessary.
  3. When a new version is ready, push the tag to repository (v0.1.0 in this case).
  4. Then run this task, and it will apply the v0.1.0 tag to the draft, and will publish it.

License

Licensed under the MIT License.