62 Commits

Author SHA1 Message Date
Pierre Vanduynslager
1edae67326 fix: display erroring git commands properly 2019-11-01 16:58:55 -04:00
Pierre Vanduynslager
0629f3cd8a
revert: feat: create annotated tags
This reverts commit 4d581fc140dda99065542872d125cf27fb24798f.
2019-09-13 14:46:47 -04:00
Pierre Vanduynslager
3e4bb40990 style: fix prettier style 2019-06-07 16:03:30 -04:00
Pierre Vanduynslager
4d581fc140 feat: create annotated tags 2019-06-07 16:03:30 -04:00
jmodjeski75
3610422959 fix(repositoryUrl): on beta repositoryUrl needs auth for pre-release flows (#1186) 2019-06-05 11:33:54 -07:00
greenkeeper[bot]
d10268a8fa chore(package): update xo to version 0.24.0 2019-01-30 19:54:29 -05:00
Pierre Vanduynslager
f96c660c1b fix: harmonize parameters passed to getError 2018-12-18 18:02:02 -05:00
Pierre Vanduynslager
9a023b4088 fix: call success plugin only once for releases added to a channel 2018-12-17 15:23:04 -05:00
Pierre Vanduynslager
162b4b9e3b fix: remove confusing logs when searching for releases to add to a channel 2018-12-17 15:23:04 -05:00
Pierre Vanduynslager
968b9968a1 fix: remove unnecessary branch parameter from push function 2018-11-29 20:44:31 -05:00
Pierre Vanduynslager
b729183b4a fix: fetch all release branches on CI 2018-11-29 20:03:51 -05:00
Pierre Vanduynslager
7b4052470b feat: support multiple branches and distribution channels
- Allow to configure multiple branches to release from
- Allow to define a distribution channel associated with each branch
- Manage the availability on distribution channels based on git merges
- Support regular releases, maintenance releases and pre-releases
- Add the `addChannel` plugin step to make an existing release available on a different distribution channel

BREAKING CHANGE: the `branch` option has been removed in favor of `branches`

The new `branches` option expect either an Array or a single branch definition. To migrate your configuration:
- If you want to publish package from multiple branches, please the configuration documentation
- If you use the default configuration and want to publish only from `master`: nothing to change
- If you use the `branch` configuration and want to publish only from one branch: replace `branch` by `branches` (`"branch": "my-release-branch"` => `"branches": "my-release-branch"`)
2018-11-29 14:13:03 -05:00
Pierre Vanduynslager
9f5645cfa0 refactor: harmonize git utils function names 2018-11-19 18:34:16 -05:00
Pierre Vanduynslager
90da6a0bc1 feat: add logs about prepare, publish, success and fail plugins skipped in dry-run mode 2018-11-14 11:27:06 -05:00
Pierre Vanduynslager
e92c84ec08 fix: indicate in logs if running in dry-run mode 2018-11-14 11:27:06 -05:00
Lucas Correia
3411520ea7 fix: include release notes in JS API result for dry mode 2018-10-20 12:37:11 -04:00
Pierre Vanduynslager
3d5db1f8b0 fix: remove debugging console.error 2018-10-20 04:24:21 -04:00
Pierre Vanduynslager
0578c8b91c fix: do not log outated branch error for missing permission cases 2018-10-17 15:33:16 -04:00
Pierre Vanduynslager
540d4fa764 fix: pass custom env and cwd to env-ci 2018-09-07 17:21:21 -04:00
greenkeeper[bot]
fa62d427b6 chore(package): update xo to version 0.23.0 2018-09-03 16:54:31 -04:00
Pierre Vanduynslager
63d422ed5c fix: do not clone stdout/stderr passed to pugins 2018-08-04 20:33:26 -04:00
Pierre Vanduynslager
417779e221 feat: return lastRelease, commits, nextRelease, releases from JS API 2018-07-29 21:56:21 -04:00
Pierre Vanduynslager
0626d57116 feat: log with signale and allow to customize stdin and stdout 2018-07-29 21:56:21 -04:00
Pierre Vanduynslager
3fb3fa8378 fix: do not override env variable with default if defined 2018-07-18 19:37:11 -04:00
Pierre Vanduynslager
a94e08de9a feat: pass cwd and env context to plugins
- Allow to run semantic-release (via API) from anywhere passing the current working directory.
- Allows to simplify the tests and to run them in parallel in both the core and plugins.
2018-07-17 00:42:04 -04:00
Pierre Vanduynslager
24ce560065 refactor: build plugin pipeline parameters at initialization
In addition, factorize the pipeline config function to avoid code duplication.
2018-07-10 13:18:58 -04:00
Pierre Vanduynslager
5989989452 feat: allow to define multiple generateNotes plugins
Each `generateNotes` plugin will be called in the order defined and will receive the concatenation of the previous one in `nextRelease.notes`.
That gives each plugin the ability to test if there is a notes part that will precede it's own.
Each plugin is expected to return it's own part of the release notes only. **semantic-release** will take care of concatenating all the notes parts.
2018-07-10 13:18:58 -04:00
Pierre Vanduynslager
f7f4aabe9e refactor: use the lastInput arg to compute the prepare pipeline next input
Use the `getNextInput`'s provided argument rather than relying on the closure.
2018-07-10 13:18:58 -04:00
Pierre Vanduynslager
ed9c456f5e refactor: always return an Array of results/errors from a plugin pipeline
Always return an `Array` from a pipeline simplify the function utilization as it's more deterministic. Previously, it would return/throw a single value/error when called with a single input and an `Array` of results/errors when called with an `Array` of input.
2018-07-10 13:18:58 -04:00
Pierre Vanduynslager
071dccea4b fix: use unauthenticated URL to check if branch is up to date
In case the authentication token provided is unauthorized the call to `isBranchUpToDate` will fail due to lack of read permission if that URL is used. As a result the error about outdated local branch will be reported instead of the one about missing permission.
By using the original (unauthenticated) URL `isBranchUpToDate` shouldn't fail due to permission as it requires only read permissions, that are necessarly present as the CI wass able to clone the repo.
2018-07-10 13:07:00 -04:00
Pierre Vanduynslager
5847514fcc fix: allow empty release notes in dry-run mode 2018-07-10 11:42:22 -04:00
Pierre Vanduynslager
45eee4acdd fix: fetch all tags even if the repo is not shallow 2018-07-02 18:38:24 -04:00
Pierre Vanduynslager
2b6378f26f fix: use git ls-remote to verify if the remote branch is ahead 2018-06-15 16:16:55 -04:00
Pierre Vanduynslager
24a8052038 refactor: simply EGITNOPERMISSION error parameters 2018-06-15 16:16:55 -04:00
greenkeeper[bot]
29e7ebfe0b fix(package): update hook-std to version 1.0.0 2018-06-11 11:21:16 -04:00
Pierre Vanduynslager
a72d8f52af fix: add clarification in EGITNOPERMISSION error message
Clarify that the error might be due to an invalid `repositoryUrl` configuration.
2018-05-20 23:14:44 +03:00
Pierre Vanduynslager
61d7d38ec2 feat: set tag author and committer name/email
Use [Git Environment Variables](https://git-scm.com/book/en/v2/Git-Internals-Environment-Variables#Committing). Set default values if environement variables are not set.
2018-05-08 14:25:23 -04:00
greenkeeper[bot]
f3e4991819 chore(package): update xo to version 0.21.0 2018-05-04 16:06:24 -04:00
pvdlg
cd9f2bdd44 feat: log git error message when authentication verification fails 2018-05-04 12:19:24 -07:00
pvdlg
d15905c0d5 fix: verify the local branch is up to date with the remote one 2018-05-01 09:59:57 -04:00
Anshuk Kumar
45d7e6f25f fix: unshallow repository with credentials 2018-05-01 09:47:15 -04:00
Pierre Vanduynslager
30ee231116 fix: prevent git prompt before permissions verification 2018-03-20 11:24:08 -04:00
Pierre Vanduynslager
7c48afad47 fix: prevent git CLI to prompt user/password on CI 2018-03-16 14:33:18 -04:00
Pierre Vanduynslager
e5a73d8628 fix: remove unecessary console.log 2018-03-07 23:01:08 +00:00
Pierre Vanduynslager
c2beb643fa feat: add the prepare plugin hook
BREAKING CHANGE: Committing or creating files in the `publish` plugin hook is not supported anymore and now must be done in the `prepare` hook

Plugins with a `publish` hook that makes a commit or create a file that can be committed must use the `prepare` hook.
2018-02-19 00:28:50 -05:00
Pierre Vanduynslager
1966f0e3e2 fix: verify branch first 2018-02-15 18:35:37 +00:00
Pierre Vanduynslager
f92677b092 fix: log current version of semantic-release 2018-02-12 11:01:09 -08:00
Pierre Vanduynslager
49f5e704ba feat: add success and fail notification plugins
- Allow `publish` plugins to return an `Object` with information related to the releases
- Add the `success` plugin hook, called when all `publish` are successful, receiving a list of release
- Add the `fail` plugin hook, called when an error happens at any point, receiving a list of errors
- Add detailed message for each error
2018-02-11 19:53:41 -05:00
Pierre Vanduynslager
9b2f6bfed2 feat: allow plugins to throw an iterable list of errors 2018-02-11 19:53:41 -05:00
Pierre Vanduynslager
39536fa34e feat: add tagFormat option to customize Git tag name 2018-01-29 00:55:32 -05:00