Skip to content

Commit

Permalink
Upgrade to rush 5.22.0
Browse files Browse the repository at this point in the history
  • Loading branch information
octogonz committed Mar 18, 2020
1 parent 31acacb commit 1f0e656
Show file tree
Hide file tree
Showing 7 changed files with 147 additions and 54 deletions.
2 changes: 1 addition & 1 deletion .gitattributes
Expand Up @@ -73,6 +73,6 @@ yarn.lock merge=binary
# syntax highlighters such as GitHub's from highlighting these comments as errors. Your text editor
# may also require a special configuration to allow comments in JSON.
#
# For more information, see this issue: https://github.com/Microsoft/web-build-tools/issues/1088
# For more information, see this issue: https://github.com/microsoft/rushstack/issues/1088
#
*.json linguist-language=JSON-with-Comments
14 changes: 7 additions & 7 deletions .gitignore
Expand Up @@ -55,14 +55,14 @@ jspm_packages/
# next.js build output
.next

# Common toolchain intermediate files
temp
# OS X temporary files
.DS_Store

# Rush files
common/temp/**
package-deps.json
.rush/temp/**
# Rush temporary files
common/temp/
**/.rush/temp/

# Common toolchain intermediate files
temp
lib
dist
temp
36 changes: 34 additions & 2 deletions common/config/rush/command-line.json
Expand Up @@ -164,13 +164,40 @@
// * (Required) A list of custom commands and/or built-in Rush commands that this parameter may
// * be used with. The parameter will be appended to the shell command that Rush invokes.
// */
// "associatedCommands": [ "build", "rebuild" ]
// "associatedCommands": [ "build", "rebuild" ]
// },
//
// {
// /**
// * (Required) Determines the type of custom parameter.
// * A "flag" is a custom command-line parameter whose presence acts as an on/off switch.
// * A "string" is a custom command-line parameter whose value is a simple text string.
// */
// "parameterKind": "string",
// "longName": "--my-string",
// "description": "A custom string parameter for the \"my-global-command\" custom command",
//
// "associatedCommands": [ "my-global-command" ],
//
// /**
// * The name of the argument, which will be shown in the command-line help.
// *
// * For example, if the parameter name is '--count" and the argument name is "NUMBER",
// * then the command-line help would display "--count NUMBER". The argument name must
// * be comprised of upper-case letters, numbers, and underscores. It should be kept short.
// */
// "argumentName": "SOME_TEXT",
//
// /**
// * If true, this parameter must be included with the command. The default is false.
// */
// "required": false
// },
//
// {
// /**
// * (Required) Determines the type of custom parameter.
// * A "choice" is a custom command-line parameter whose argument must be chosen from a list of
// * allowable alternatives.
// */
// "parameterKind": "choice",
// "longName": "--my-choice",
Expand All @@ -179,6 +206,11 @@
// "associatedCommands": [ "my-global-command" ],
//
// /**
// * If true, this parameter must be included with the command. The default is false.
// */
// "required": false,
//
// /**
// * Normally if a parameter is omitted from the command line, it will not be passed
// * to the shell command. this value will be inserted by default. Whereas if a "defaultValue"
// * is defined, the parameter will always be passed to the shell command, and will use the
Expand Down
26 changes: 22 additions & 4 deletions common/config/rush/common-versions.json
Expand Up @@ -6,10 +6,14 @@
"$schema": "https://developer.microsoft.com/json-schemas/rush/v5/common-versions.schema.json",

/**
* A table that specifies a "preferred version" for a dependency package. The "preferred version"
* is typically used to hold an indirect dependency back to a specific version, however generally
* it can be any SemVer range specifier (e.g. "~1.2.3"), and it will narrow any (compatible)
* SemVer range specifier. See the Rush documentation for details about this feature.
* A table that specifies a "preferred version" for a given NPM package. This feature is typically used
* to hold back an indirect dependency to a specific older version, or to reduce duplication of indirect dependencies.
*
* The "preferredVersions" value can be any SemVer range specifier (e.g. "~1.2.3"). Rush injects these values into
* the "dependencies" field of the top-level common/temp/package.json, which influences how the package manager
* will calculate versions. The specific effect depends on your package manager. Generally it will have no
* effect on an incompatible or already constrained SemVer range. If you are using PNPM, similar effects can be
* achieved using the pnpmfile.js hook. See the Rush documentation for more details.
*
* After modifying this field, it's recommended to run "rush update --full" so that the package manager
* will recalculate all version selections.
Expand All @@ -24,6 +28,20 @@
"@types/jest-diff": "20.0.1"
},

/**
* When set to true, for all projects in the repo, all dependencies will be automatically added as preferredVersions,
* except in cases where different projects specify different version ranges for a given dependency. For older
* package managers, this tended to reduce duplication of indirect dependencies. However, it can sometimes cause
* trouble for indirect dependencies with incompatible peerDependencies ranges.
*
* The default value is true. If you're encountering installation errors related to peer dependencies,
* it's recommended to set this to false.
*
* After modifying this field, it's recommended to run "rush update --full" so that the package manager
* will recalculate all version selections.
*/
// "implicitlyPreferredVersions": false,

/**
* The "rush check" command can be used to enforce that every project in the repo must specify
* the same SemVer range for a given dependency. However, sometimes exceptions are needed.
Expand Down
2 changes: 1 addition & 1 deletion common/config/rush/version-policies.json
Expand Up @@ -5,7 +5,7 @@

/**
* A list of version policy definitions. A "version policy" is a custom package versioning
* strategy that affets "rush change", "rush version", and "rush publish". The strategy applies
* strategy that affects "rush change", "rush version", and "rush publish". The strategy applies
* to a set of projects that are specified using the "versionPolicyName" field in rush.json.
*/
[
Expand Down
85 changes: 50 additions & 35 deletions common/scripts/install-run.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

36 changes: 32 additions & 4 deletions rush.json
Expand Up @@ -16,7 +16,7 @@
* path segment in the "$schema" field for all your Rush config files. This will ensure
* correct error-underlining and tab-completion for editors such as VS Code.
*/
"rushVersion": "5.16.1",
"rushVersion": "5.22.0",

/**
* The next field selects which package manager should be installed and determines its version.
Expand All @@ -26,7 +26,7 @@
* Specify one of: "pnpmVersion", "npmVersion", or "yarnVersion". See the Rush documentation
* for details about these alternatives.
*/
"pnpmVersion": "3.1.1",
"pnpmVersion": "4.11.6",

// "npmVersion": "4.5.0",
// "yarnVersion": "1.9.4",
Expand All @@ -35,6 +35,22 @@
* Options that are only used when the PNPM package manager is selected
*/
"pnpmOptions": {
/**
* Specifies the location of the PNPM store. There are two possible values:
*
* - "local" - use the "pnpm-store" folder in the current configured temp folder:
* "common/temp/pnpm-store" by default.
* - "global" - use PNPM's global store, which has the benefit of being shared
* across multiple repo folders, but the disadvantage of less isolation for builds
* (e.g. bugs or incompatibilities when two repos use different releases of PNPM)
*
* RUSH_PNPM_STORE_PATH will override the directory that will be used as the store
*
* In all cases, the store path will be overridden by the environment variable RUSH_PNPM_STORE_PATH.
*
* The default value is "local".
*/
// "pnpmStore": "local",

/**
* If true, then Rush will add the "--strict-peer-dependencies" option when invoking PNPM.
Expand Down Expand Up @@ -211,12 +227,24 @@
* determined from Git alone, since the "pull request" feature is not a Git concept. Ideally
* Rush would use a vendor-specific protocol to query the information from GitHub, Azure DevOps, etc.
* But to keep things simple, "rush change" simply assumes that your PR is against the "master" branch
* of the Git remote indicated by the respository.url setting in rush.json. If you are working in
* of the Git remote indicated by the repository.url setting in rush.json. If you are working in
* a GitHub "fork" of the real repo, this setting will be different from the repository URL of your
* your PR branch, and in this situation "rush change" will also automatically invoke "git fetch"
* to retrieve the latest activity for the remote master branch.
*/
"url": "https://github.com/microsoft/tsdoc.git"
"url": "https://github.com/microsoft/rush-example",

/**
* The default branch name. This tells "rush change" which remote branch to compare against.
* The default value is "master"
*/
// "defaultBranch": "master",

/**
* The default remote. This tells "rush change" which remote to compare against if the remote URL is
* not set or if a remote matching the provided remote URL is not found.
*/
// "defaultRemote": "origin"
},

/**
Expand Down

0 comments on commit 1f0e656

Please sign in to comment.