diff --git a/Gruntfile.js b/Gruntfile.js deleted file mode 100644 index 31c7245d..00000000 --- a/Gruntfile.js +++ /dev/null @@ -1,36 +0,0 @@ -module.exports = function(grunt) { - var pkg = require("./package.json"); - global.jasmineVersion = pkg.version; - var versionString = 'v' + pkg.version; - - grunt.initConfig({ - pkg: pkg - }); - - var shell = require('shelljs'); - function runCommands(commands, done) { - var command = commands.shift(); - - if (command) { - shell.exec(command, function(exitCode) { - if (exitCode !== 0) { - grunt.fail.fatal("Command `" + command + "` failed", exitCode); - done(); - } else { - runCommands(commands, done); - } - }); - } else { - done(); - } - } - - grunt.registerTask('release', - 'Create tag ' + versionString + ' and push jasmine-' + pkg.version + ' to NPM', - function() { - var done = this.async(), - commands = ['git tag ' + versionString, 'git push origin main --tags', 'npm publish']; - - runCommands(commands, done); - }); -}; diff --git a/RELEASE.md b/RELEASE.md new file mode 100644 index 00000000..a7721531 --- /dev/null +++ b/RELEASE.md @@ -0,0 +1,27 @@ +# How to work on a Jasmine Release + +## Prepare the release +When ready to release - specs are all green and the stories are done: + +1. If this is a major or minor release, publish the corresponding release of + `jasmine-core` as described in that repo's `RELEASE.md`. +2. Create release notes using the Anchorman gem. +3. In `package.json`, update both the package version and the `jasmine-core` + dependency version. This package should depend on the same major and minor + version of `jasmine-core`. For instance, 4.1.1 should depend on + `"jasmine-core": "^4.1.0"`. +4. Commit and push. +5. Wait for Circle CI to go green again. + +## Publish the NPM package + +1. Create a tag for the version, e.g. `git tag v4.4.0`. +2. Push the tag: `git push --tags` +3. Publish the NPM package: `npm publish`. + +### Publish the GitHub release + +1. Visit the GitHub releases page and find the tag just published. +2. Paste in a link to the correct release notes for this release. +3. If it is a pre-release, mark it as such. +4. Publish the release. diff --git a/package.json b/package.json index 797ee88a..cabbcec6 100644 --- a/package.json +++ b/package.json @@ -35,8 +35,6 @@ "main": "./lib/jasmine.js", "devDependencies": { "eslint": "^6.8.0", - "grunt": "^1.0.4", - "grunt-cli": "^1.3.2", "shelljs": "^0.8.3", "slash": "^3.0.0", "temp": "^0.9.4"