Skip to content
This repository has been archived by the owner on Sep 18, 2017. It is now read-only.

Add [release skip] command #2

Closed
wants to merge 6 commits into from

Conversation

ariporad
Copy link

Title basically says it all.

If [release skip] or [skip release] are in the commit message.

Note that it only works if it is the most recent commit that contains the command.

Fixes semantic-release/semantic-release#41

Change to the new version of the commit analyzer API. Now the parser is called
multiple times with only a single commit each time, and semantic-release takes
care of keeping track of the version. This drastically simplifies the code.

BREAKING CHANGE:
	Instead of accepting an array of commits with the `commits` option, we now
	accept a single commit with the `commit` option. Use that instead, and call
	the plugin multiple times.
Add [release skip] command. It will (shockingly,) skip the release for that commit.
Also add [skip release] as an alias of that.

Fixes semantic-release/semantic-release#41
@ariporad
Copy link
Author

Github appears to be getting a little confused about this PR and the other one (#1), as this one is based off that one.

@ariporad
Copy link
Author

This doesn't completely fix semantic-release/semantic-release#41, It outputs a release type of 'rskip', which semantic-release will (at least with the new commit-analyzer system that is almost done), simply ignore until I get support added. I'll work on it.

@ariporad
Copy link
Author

Also, some how I broke npm test. The tests pass, but npm exists non-zero.

ariporad referenced this pull request in ariporad/semantic-release Aug 18, 2015
Add support for rskip release type, and skipping releases.
Skipping releases is supported by semantic-release/commit-analyzer#2.

Fixes semantic-release#41
ariporad referenced this pull request in ariporad/semantic-release Aug 19, 2015
Support the new commit-analyzer API. With the new API, we call the plugin once
for each commit, and keep track of the changes ourselfs.
This also adds support for the 'rskip' release type, which skips the release.
This revealed a major problem with the pre.js unit tests (test/specs/pre.js),
child process was not actually being mocked, and was simply returning an empty
array. With the old system, the mocked commit-analyzer was still called and
could still trigger a release (this is actually a flaw with the whole system.
With the new system, this is no longer true, so the unit tests fail. I did not
fix this both because it's not related to this branch/pull request, and because
it would mean a major revamp, which I would need to think about more.

Fixes semantic-release#41
Refs semantic-release/commit-analyzer#1, semantic-release/commit-analyzer#2
BREAKING CHANGE:
	The commit-analyzer is now called multiple times, and with a single commit
	(passed in as `commit`, vs `commits` as an array). The plugin also no longer
	has to deal with keeping track of the release type between commits.
@boennemann
Copy link
Member

As I mentioned before these commands to semantic-release should be part of the core, so plugins authors do not have to reimplement them every time. This is part of the semantic-release API and not of individual conventions.

@boennemann boennemann closed this Aug 20, 2015
@ariporad
Copy link
Author

@boennemann: I respectfully disagree. It is the commit analyzers concern to parse the commit, not semantic-release's. Plus, this allows for diffrent commit formats to skip commits differently.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants