Home > @microsoft/rush-lib > LockStepVersionPolicy
LockStepVersionPolicy class
This policy indicates all related projects should use the same version.
Signature:
export declare class LockStepVersionPolicy extends VersionPolicy
Extends: VersionPolicy
Remarks
The constructor for this class is marked as internal. Third-party code should not call the constructor directly or create subclasses that extend the LockStepVersionPolicy
class.
Properties
Property | Modifiers | Type | Description |
---|---|---|---|
mainProject | readonly | string | undefined | The main project for the version policy. If the value is provided, change logs will only be generated in that project. If the value is not provided, change logs will be hosted in each project associated with the policy. |
nextBump | readonly | BumpType | undefined | The type of bump for next bump. |
version | readonly | string | The value of the lockstep version |
Methods
Method | Modifiers | Description |
---|---|---|
bump(bumpType, identifier) | Bumps the version of the lockstep policy | |
ensure(project, force) | Returns an updated package json that satisfies the version policy. | |
update(newVersionString) | Updates the version of the policy directly with a new value | |
validate(versionString, packageName) | Validates the specified version and throws if the version does not satisfy lockstep version. |