Skip to content

Commit

Permalink
docs: master -> main
Browse files Browse the repository at this point in the history
  • Loading branch information
evocateur committed Nov 9, 2020
1 parent 0aeb298 commit 5ef6364
Show file tree
Hide file tree
Showing 10 changed files with 42 additions and 42 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2538,7 +2538,7 @@ We've got plenty of room to grow our documentation, PRs welcome!
* [#748](https://github.com/lerna/lerna/pull/748) Reference conventionalcommits.org website in README. ([@bcoe](https://github.com/bcoe))
* [#751](https://github.com/lerna/lerna/pull/751) Update README.md and docs to better explain hoisting. ([@kylecordes](https://github.com/kylecordes))

If you've ever had a question about hoisting, read [@kylecordes](https://github.com/kylecordes)'s brilliant docs [here](https://github.com/lerna/lerna/blob/master/doc/hoist.md)!
If you've ever had a question about hoisting, read [@kylecordes](https://github.com/kylecordes)'s brilliant docs [here](https://github.com/lerna/lerna/blob/main/doc/hoist.md)!

#### :house: Internal

Expand Down
10 changes: 5 additions & 5 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ $ npm ci

## Code Structure

Currently, the [source](https://github.com/lerna/lerna/tree/master) is split up into a few categories:
Currently, the [source](https://github.com/lerna/lerna/tree/main) is split up into a few categories:

* [utils](https://github.com/lerna/lerna/tree/master/utils): shared packages to run git, npm, fs, and more.
* [core](https://github.com/lerna/lerna/tree/master/core): basic building blocks, including Package-related abstractions and the command superclass.
* [commands](https://github.com/lerna/lerna/tree/master/commands): each command has an `initialize` and `execute` function.
* These commands are consumed as yargs subcommands in [core/cli/index.js](https://github.com/lerna/lerna/blob/master/core/cli/index.js), which is required from the executable [`core/lerna/cli.js`](https://github.com/lerna/lerna/blob/master/core/lerna/cli.js).
* [utils](https://github.com/lerna/lerna/tree/main/utils): shared packages to run git, npm, fs, and more.
* [core](https://github.com/lerna/lerna/tree/main/core): basic building blocks, including Package-related abstractions and the command superclass.
* [commands](https://github.com/lerna/lerna/tree/main/commands): each command has an `initialize` and `execute` function.
* These commands are consumed as yargs subcommands in [core/cli/index.js](https://github.com/lerna/lerna/blob/main/core/cli/index.js), which is required from the executable [`core/lerna/cli.js`](https://github.com/lerna/lerna/blob/main/core/lerna/cli.js).

## Commands

Expand Down
8 changes: 4 additions & 4 deletions FAQ.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ into your Lerna repository; this command will preserve the commit history.
[`lerna import <package>`][import] takes a local path rather than a URL. In this
case you will need to have the repo you wish to link to on your file system.

[bootstrap]: https://github.com/lerna/lerna/blob/master/commands/bootstrap/README.md
[import]: https://github.com/lerna/lerna/blob/master/commands/import/README.md
[bootstrap]: https://github.com/lerna/lerna/blob/main/commands/bootstrap/README.md
[import]: https://github.com/lerna/lerna/blob/main/commands/import/README.md

## How do I retry publishing if `publish` fails?

Expand All @@ -41,7 +41,7 @@ You can significantly reduce the time spent in `lerna bootstrap` if you turn
on hoisting, see the [hoisting docs](./doc/hoist.md) for more information.

In combination with that you may increase the bootstrap performance even more by
[using yarn as an npm client](https://github.com/lerna/lerna/blob/master/commands/bootstrap/README.md#usage) instead of `npm`.
[using yarn as an npm client](https://github.com/lerna/lerna/blob/main/commands/bootstrap/README.md#usage) instead of `npm`.

## Root `package.json`

Expand All @@ -50,7 +50,7 @@ You should also put your testing, linting and similar tasks there to run them fr
as running them separately from each package is slower. The root can also hold all the "hoisted" packages,
which speeds up bootstrapping when using the [`--hoist`][hoist] flag.

[hoist]: https://github.com/lerna/lerna/blob/master/doc/hoist.md
[hoist]: https://github.com/lerna/lerna/blob/main/doc/hoist.md

## CI setup

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

<p align="center">
<a href="https://www.npmjs.com/package/lerna"><img alt="NPM Status" src="https://img.shields.io/npm/v/lerna.svg?style=flat"></a>
<a href="https://travis-ci.org/lerna/lerna"><img alt="Travis Status" src="https://img.shields.io/travis/lerna/lerna/master.svg?style=flat&label=travis"></a>
<a href="https://travis-ci.org/lerna/lerna"><img alt="Travis Status" src="https://img.shields.io/travis/lerna/lerna/main.svg?style=flat&label=travis"></a>
</p>

- [About](#about)
Expand Down
2 changes: 1 addition & 1 deletion commands/bootstrap/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ the default is `**` (hoist everything). This option only affects the
$ lerna bootstrap --hoist
```

For background on `--hoist`, see the [hoist documentation](https://github.com/lerna/lerna/blob/master/doc/hoist.md).
For background on `--hoist`, see the [hoist documentation](https://github.com/lerna/lerna/blob/main/doc/hoist.md).

Note: If packages depend on different _versions_ of an external dependency,
the most commonly used version will be hoisted, and a warning will be emitted.
Expand Down
26 changes: 13 additions & 13 deletions commands/changed/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,21 +19,21 @@ package-2

## Options

`lerna changed` supports all of the flags supported by [`lerna ls`](https://github.com/lerna/lerna/tree/master/commands/list#options):
`lerna changed` supports all of the flags supported by [`lerna ls`](https://github.com/lerna/lerna/tree/main/commands/list#options):

- [`--json`](https://github.com/lerna/lerna/tree/master/commands/list#--json)
- [`--ndjson`](https://github.com/lerna/lerna/tree/master/commands/list#--ndjson)
- [`-a`, `--all`](https://github.com/lerna/lerna/tree/master/commands/list#--all)
- [`-l`, `--long`](https://github.com/lerna/lerna/tree/master/commands/list#--long)
- [`-p`, `--parseable`](https://github.com/lerna/lerna/tree/master/commands/list#--parseable)
- [`--toposort`](https://github.com/lerna/lerna/tree/master/commands/list#--toposort)
- [`--graph`](https://github.com/lerna/lerna/tree/master/commands/list#--graph)
- [`--json`](https://github.com/lerna/lerna/tree/main/commands/list#--json)
- [`--ndjson`](https://github.com/lerna/lerna/tree/main/commands/list#--ndjson)
- [`-a`, `--all`](https://github.com/lerna/lerna/tree/main/commands/list#--all)
- [`-l`, `--long`](https://github.com/lerna/lerna/tree/main/commands/list#--long)
- [`-p`, `--parseable`](https://github.com/lerna/lerna/tree/main/commands/list#--parseable)
- [`--toposort`](https://github.com/lerna/lerna/tree/main/commands/list#--toposort)
- [`--graph`](https://github.com/lerna/lerna/tree/main/commands/list#--graph)

Unlike `lerna ls`, however, `lerna changed` **does not** support [filter options](https://www.npmjs.com/package/@lerna/filter-options), as filtering is not supported by `lerna version` or `lerna publish`.

`lerna changed` supports the following options of [`lerna version`](https://github.com/lerna/lerna/tree/master/commands/version#options) (the others are irrelevant):
`lerna changed` supports the following options of [`lerna version`](https://github.com/lerna/lerna/tree/main/commands/version#options) (the others are irrelevant):

- [`--conventional-graduate`](https://github.com/lerna/lerna/tree/master/commands/version#--conventional-graduate).
- [`--force-publish`](https://github.com/lerna/lerna/tree/master/commands/version#--force-publish).
- [`--ignore-changes`](https://github.com/lerna/lerna/tree/master/commands/version#--ignore-changes).
- [`--include-merged-tags`](https://github.com/lerna/lerna/tree/master/commands/version#--include-merged-tags).
- [`--conventional-graduate`](https://github.com/lerna/lerna/tree/main/commands/version#--conventional-graduate).
- [`--force-publish`](https://github.com/lerna/lerna/tree/main/commands/version#--force-publish).
- [`--ignore-changes`](https://github.com/lerna/lerna/tree/main/commands/version#--ignore-changes).
- [`--include-merged-tags`](https://github.com/lerna/lerna/tree/main/commands/version#--include-merged-tags).
16 changes: 8 additions & 8 deletions commands/publish/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ lerna publish from-package # explicitly publish packages where the latest versio

When run, this command does one of the following things:

- Publish packages updated since the last release (calling [`lerna version`](https://github.com/lerna/lerna/tree/master/commands/version#readme) behind the scenes).
- Publish packages updated since the last release (calling [`lerna version`](https://github.com/lerna/lerna/tree/main/commands/version#readme) behind the scenes).
- This is the legacy behavior of lerna 2.x
- Publish packages tagged in the current commit (`from-git`).
- Publish packages in the latest commit where the version is not present in the registry (`from-package`).
Expand All @@ -30,7 +30,7 @@ Check out [Per-Package Configuration](#per-package-configuration) for more detai

### bump `from-git`

In addition to the semver keywords supported by [`lerna version`](https://github.com/lerna/lerna/tree/master/commands/version#positionals),
In addition to the semver keywords supported by [`lerna version`](https://github.com/lerna/lerna/tree/main/commands/version#positionals),
`lerna publish` also supports the `from-git` keyword.
This will identify packages tagged by `lerna version` and publish them to npm.
This is useful in CI scenarios where you wish to manually increment versions,
Expand All @@ -45,7 +45,7 @@ This is useful when a previous `lerna publish` failed to publish all packages to

## Options

`lerna publish` supports all of the options provided by [`lerna version`](https://github.com/lerna/lerna/tree/master/commands/version#options) in addition to the following:
`lerna publish` supports all of the options provided by [`lerna version`](https://github.com/lerna/lerna/tree/main/commands/version#options) in addition to the following:

- [`--canary`](#--canary)
- [`--contents <dir>`](#--contents-dir)
Expand Down Expand Up @@ -195,7 +195,7 @@ This option makes the most sense configured in lerna.json, as you really don't w
}
```

The root-level configuration is intentional, as this also covers the [identically-named option in `lerna version`](https://github.com/lerna/lerna/tree/master/commands/version#--no-granular-pathspec).
The root-level configuration is intentional, as this also covers the [identically-named option in `lerna version`](https://github.com/lerna/lerna/tree/main/commands/version#--no-granular-pathspec).

### `--no-verify-access`

Expand Down Expand Up @@ -295,7 +295,7 @@ Useful in [Continuous integration (CI)](https://en.wikipedia.org/wiki/Continuous

### `--skip-npm`

Call [`lerna version`](https://github.com/lerna/lerna/tree/master/commands/version#readme) directly, instead.
Call [`lerna version`](https://github.com/lerna/lerna/tree/main/commands/version#readme) directly, instead.

## Per-Package Configuration

Expand Down Expand Up @@ -367,7 +367,7 @@ This _non-standard_ field allows you to customize the published subdirectory jus

Lerna will run [npm lifecycle scripts](https://docs.npmjs.com/misc/scripts#description) during `lerna publish` in the following order:

1. If versioning implicitly, run all [version lifecycle scripts](https://github.com/lerna/lerna/tree/master/commands/version#lifecycle-scripts)
1. If versioning implicitly, run all [version lifecycle scripts](https://github.com/lerna/lerna/tree/main/commands/version#lifecycle-scripts)
2. Run `prepublish` lifecycle in root, if [enabled](#--ignore-prepublish)
3. Run `prepare` lifecycle in root
4. Run `prepublishOnly` lifecycle in root
Expand All @@ -377,11 +377,11 @@ Lerna will run [npm lifecycle scripts](https://docs.npmjs.com/misc/scripts#descr
2. Run `prepare` lifecycle
3. Run `prepublishOnly` lifecycle
4. Run `prepack` lifecycle
5. Create package tarball in temp directory via [JS API](https://github.com/lerna/lerna/tree/master/utils/pack-directory#readme)
5. Create package tarball in temp directory via [JS API](https://github.com/lerna/lerna/tree/main/utils/pack-directory#readme)
6. Run `postpack` lifecycle
7. Run `postpack` lifecycle in root
8. For each changed package, in topological order (all dependencies before dependents):
1. Publish package to configured [registry](#--registry-url) via [JS API](https://github.com/lerna/lerna/tree/master/utils/npm-publish#readme)
1. Publish package to configured [registry](#--registry-url) via [JS API](https://github.com/lerna/lerna/tree/main/utils/npm-publish#readme)
2. Run `publish` lifecycle
3. Run `postpublish` lifecycle
9. Run `publish` lifecycle in root
Expand Down
10 changes: 5 additions & 5 deletions commands/version/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,20 +79,20 @@ It is easiest (and recommended) to configure in `lerna.json`, but it is possible
{
"command": {
"version": {
"allowBranch": "master"
"allowBranch": "main"
}
}
}
```

With the configuration above, the `lerna version` will fail when run from any branch other than `master`.
With the configuration above, the `lerna version` will fail when run from any branch other than `main`.
It is considered a best-practice to limit `lerna version` to the primary branch alone.

```json
{
"command": {
"version": {
"allowBranch": ["master", "feature/*"]
"allowBranch": ["main", "feature/*"]
}
}
}
Expand Down Expand Up @@ -354,7 +354,7 @@ This option makes the most sense configured in lerna.json, as you really don't w
}
```

The root-level configuration is intentional, as this also covers the [identically-named option in `lerna publish`](https://github.com/lerna/lerna/tree/master/commands/publish#--no-granular-pathspec).
The root-level configuration is intentional, as this also covers the [identically-named option in `lerna publish`](https://github.com/lerna/lerna/tree/main/commands/publish#--no-granular-pathspec).

### `--no-private`

Expand Down Expand Up @@ -438,7 +438,7 @@ Use [`--no-git-tag-version`](#--no-git-tag-version) and [`--no-push`](#--no-push

### Generating Initial Changelogs

If you start using the [`--conventional-commits`](#--conventional-commits) option _after_ the monorepo has been active for awhile, you can still generate changelogs for previous releases using [`conventional-changelog-cli`](https://github.com/conventional-changelog/conventional-changelog/tree/master/packages/conventional-changelog-cli#readme) and [`lerna exec`](https://github.com/lerna/lerna/tree/master/commands/exec#readme):
If you start using the [`--conventional-commits`](#--conventional-commits) option _after_ the monorepo has been active for awhile, you can still generate changelogs for previous releases using [`conventional-changelog-cli`](https://github.com/conventional-changelog/conventional-changelog/tree/master/packages/conventional-changelog-cli#readme) and [`lerna exec`](https://github.com/lerna/lerna/tree/main/commands/exec#readme):

```bash
# Lerna does not actually use conventional-changelog-cli, so you need to install it temporarily
Expand Down
6 changes: 3 additions & 3 deletions core/filter-options/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,14 @@ Only include packages that have been changed since the specified `ref`. If no re
# List the contents of packages that have changed since the latest tag
$ lerna exec --since -- ls -la

# Run the tests for all packages that have changed since `master`
$ lerna run test --since master
# Run the tests for all packages that have changed since `main`
$ lerna run test --since main

# List all packages that have changed since `some-branch`
$ lerna ls --since some-branch
```

_This can be particularly useful when used in CI, if you can obtain the target branch a PR will be going into, because you can use that as the `ref` to the `--since` option. This works well for PRs going into master as well as feature branches._
_This can be particularly useful when used in CI, if you can obtain the target branch a PR will be going into, because you can use that as the `ref` to the `--since` option. This works well for PRs going into the default branch as well as feature branches._

### `--exclude-dependents`

Expand Down
2 changes: 1 addition & 1 deletion core/lerna/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<p align="center">
<a href="https://www.npmjs.com/package/lerna"><img alt="NPM Status" src="https://img.shields.io/npm/v/lerna.svg?style=flat"></a>
<a href="https://travis-ci.org/lerna/lerna"><img alt="Travis Status" src="https://img.shields.io/travis/lerna/lerna/master.svg?style=flat&label=travis"></a>
<a href="https://travis-ci.org/lerna/lerna"><img alt="Travis Status" src="https://img.shields.io/travis/lerna/lerna/main.svg?style=flat&label=travis"></a>
</p>

## Usage
Expand Down

0 comments on commit 5ef6364

Please sign in to comment.