Skip to content

Commit

Permalink
Merge pull request #4722 from microsoft/octogonz/rush-5.124.6
Browse files Browse the repository at this point in the history
Upgrade to Rush 5.124.6
  • Loading branch information
octogonz authored May 18, 2024
2 parents f29305d + c952f8f commit 8a5da07
Show file tree
Hide file tree
Showing 3 changed files with 74 additions and 3 deletions.
6 changes: 4 additions & 2 deletions common/config/rush/custom-tips.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,16 @@
"$schema": "https://developer.microsoft.com/json-schemas/rush/v5/custom-tips.schema.json",

/**
* Specifies the custom tips to be displayed by Rush.
* Custom tips allow you to annotate Rush's console messages with advice tailored for
* your specific monorepo.
*/
"customTips": [
// {
// /**
// * (REQUIRED) An identifier indicating a message that may be printed by Rush.
// * If that message is printed, then this custom tip will be shown.
// * Consult the Rush documentation for the current list of possible identifiers.
// * The list of available tip identifiers can be found on this page:
// * https://rushjs.io/pages/maintainer/custom_tips/
// */
// "tipId": "TIP_RUSH_INCONSISTENT_VERSIONS",
//
Expand Down
62 changes: 62 additions & 0 deletions common/config/rush/pnpm-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,68 @@
*/
"preventManualShrinkwrapChanges": true,

/**
* When a project uses `workspace:` to depend on another Rush project, PNPM normally installs
* it by creating a symlink under `node_modules`. This generally works well, but in certain
* cases such as differing `peerDependencies` versions, symlinking may cause trouble
* such as incorrectly satisfied versions. For such cases, the dependency can be declared
* as "injected", causing PNPM to copy its built output into `node_modules` like a real
* install from a registry. Details here: https://rushjs.io/pages/advanced/injected_deps/
*
* When using Rush subspaces, these sorts of versioning problems are much more likely if
* `workspace:` refers to a project from a different subspace. This is because the symlink
* would point to a separate `node_modules` tree installed by a different PNPM lockfile.
* A comprehensive solution is to enable `alwaysInjectDependenciesFromOtherSubspaces`,
* which automatically treats all projects from other subspaces as injected dependencies
* without having to manually configure them.
*
* NOTE: Use carefully -- excessive file copying can slow down the `rush install` and
* `pnpm-sync` operations if too many dependencies become injected.
*
* The default value is false.
*/
// "alwaysInjectDependenciesFromOtherSubspaces": false,

/**
* Defines the policies to be checked for the `pnpm-lock.yaml` file.
*/
"pnpmLockfilePolicies": {
/**
* This policy will cause "rush update" to report an error if `pnpm-lock.yaml` contains
* any SHA1 integrity hashes.
*
* For each NPM dependency, `pnpm-lock.yaml` normally stores an `integrity` hash. Although
* its main purpose is to detect corrupted or truncated network requests, this hash can also
* serve as a security fingerprint to protect against attacks that would substitute a
* malicious tarball, for example if a misconfigured .npmrc caused a machine to accidentally
* download a matching package name+version from npmjs.com instead of the private NPM registry.
* NPM originally used a SHA1 hash; this was insecure because an attacker can too easily craft
* a tarball with a matching fingerprint. For this reason, NPM later deprecated SHA1 and
* instead adopted a cryptographically strong SHA512 hash. Nonetheless, SHA1 hashes can
* occasionally reappear during "rush update", for example due to missing metadata fallbacks
* (https://github.com/orgs/pnpm/discussions/6194) or an incompletely migrated private registry.
* The `disallowInsecureSha1` policy prevents this, avoiding potential security/compliance alerts.
*/
// "disallowInsecureSha1": {
// /**
// * Enables the "disallowInsecureSha1" policy. The default value is false.
// */
// "enabled": true,
//
// /**
// * In rare cases, a private NPM registry may continue to serve SHA1 hashes for very old
// * package versions, perhaps due to a caching issue or database migration glitch. To avoid
// * having to disable the "disallowInsecureSha1" policy for the entire monorepo, the problematic
// * package versions can be individually ignored. The "exemptPackageVersions" key is the
// * package name, and the array value lists exact version numbers to be ignored.
// */
// "exemptPackageVersions": {
// "example1": ["1.0.0"],
// "example2": ["2.0.0", "2.0.1"]
// }
// }
},

/**
* The "globalOverrides" setting provides a simple mechanism for overriding version selections
* for all dependencies of all projects in the monorepo workspace. The settings are copied
Expand Down
9 changes: 8 additions & 1 deletion rush.json
Original file line number Diff line number Diff line change
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.122.0",
"rushVersion": "5.124.6",

/**
* The next field selects which package manager should be installed and determines its version.
Expand Down Expand Up @@ -319,6 +319,13 @@
// "projectFolder": "apps/my-app",
//
// /**
// * This field is only used if "subspacesEnabled" is true in subspaces.json.
// * It specifies the subspace that this project belongs to. If omitted, then the
// * project belongs to the "default" subspace.
// */
// // "subspaceName": "my-subspace",
//
// /**
// * An optional category for usage in the "browser-approved-packages.json"
// * and "nonbrowser-approved-packages.json" files. The value must be one of the
// * strings from the "reviewCategories" defined above.
Expand Down

0 comments on commit 8a5da07

Please sign in to comment.