From c7534895643956c377c25c9d0aa94c156aa59dfb Mon Sep 17 00:00:00 2001 From: Eric Lau Date: Thu, 2 Jan 2025 16:10:03 -0500 Subject: [PATCH 1/2] Update documentation links --- CHANGELOG.md | 4 ++++ README.md | 4 ++-- docs/modules/pages/foundry-upgrades.adoc | 4 ++-- src/Options.sol | 2 +- 4 files changed, 9 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2537dad..faf1872 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## Unreleased + +- Update documentation links. + ## 0.3.6 (2024-09-24) - Add `referenceBuildInfoDir` and `exclude` options. ([#74](https://github.com/OpenZeppelin/openzeppelin-foundry-upgrades/pull/74)) diff --git a/README.md b/README.md index 73074fb..c8366cf 100644 --- a/README.md +++ b/README.md @@ -80,7 +80,7 @@ This library requires [forge-std](https://github.com/foundry-rs/forge-std) versi ## Before Running -This library uses the [OpenZeppelin Upgrades CLI](https://docs.openzeppelin.com/upgrades-plugins/1.x/api-core) for upgrade safety validations, which are run by default during deployments and upgrades. +This library uses the [OpenZeppelin Upgrades CLI](https://docs.openzeppelin.com/upgrades-plugins/api-core) for upgrade safety validations, which are run by default during deployments and upgrades. If you want to be able to run upgrade safety validations, the following are needed: 1. Install [Node.js](https://nodejs.org/). @@ -92,7 +92,7 @@ ast = true build_info = true extra_output = ["storageLayout"] ``` -3. If you are upgrading your contract from a previous version, add the `@custom:oz-upgrades-from ` annotation to the new version of your contract according to [Define Reference Contracts](https://docs.openzeppelin.com/upgrades-plugins/1.x/api-core#define-reference-contracts) or specify the `referenceContract` option when calling the library's functions. +3. If you are upgrading your contract from a previous version, add the `@custom:oz-upgrades-from ` annotation to the new version of your contract according to [Define Reference Contracts](https://docs.openzeppelin.com/upgrades-plugins/api-core#define-reference-contracts) or specify the `referenceContract` option when calling the library's functions. 4. Run `forge clean` before running your Foundry script or tests, or include the `--force` option when running `forge script` or `forge test`. If you do not want to run upgrade safety validations, you can skip the above steps and use the [`unsafeSkipAllChecks` option](src/Options.sol) when calling the `Upgrades` library's functions, or use the `UnsafeUpgrades` library instead. Note that these are dangerous options meant to be used as a last resort. diff --git a/docs/modules/pages/foundry-upgrades.adoc b/docs/modules/pages/foundry-upgrades.adoc index 70c68f5..4df5055 100644 --- a/docs/modules/pages/foundry-upgrades.adoc +++ b/docs/modules/pages/foundry-upgrades.adoc @@ -83,7 +83,7 @@ This library requires https://github.com/foundry-rs/forge-std[forge-std] version == Before Running -This library uses the https://docs.openzeppelin.com/upgrades-plugins/1.x/api-core[OpenZeppelin Upgrades CLI] for upgrade safety validations, which are run by default during deployments and upgrades. +This library uses the https://docs.openzeppelin.com/upgrades-plugins/api-core[OpenZeppelin Upgrades CLI] for upgrade safety validations, which are run by default during deployments and upgrades. If you want to be able to run upgrade safety validations, the following are needed: @@ -101,7 +101,7 @@ extra_output = ["storageLayout"] ---- [start=3] -3. If you are upgrading your contract from a previous version, add the `@custom:oz-upgrades-from ` annotation to the new version of your contract according to https://docs.openzeppelin.com/upgrades-plugins/1.x/api-core#define-reference-contracts[Define Reference Contracts] or specify the `referenceContract` option when calling the library's functions. +3. If you are upgrading your contract from a previous version, add the `@custom:oz-upgrades-from ` annotation to the new version of your contract according to https://docs.openzeppelin.com/upgrades-plugins/api-core#define-reference-contracts[Define Reference Contracts] or specify the `referenceContract` option when calling the library's functions. 4. Run `forge clean` before running your Foundry script or tests, or include the `--force` option when running `forge script` or `forge test`. diff --git a/src/Options.sol b/src/Options.sol index ed4027b..bbaf743 100644 --- a/src/Options.sol +++ b/src/Options.sol @@ -41,7 +41,7 @@ struct Options { string[] exclude; /* * Selectively disable one or more validation errors. Comma-separated list that must be compatible with the - * --unsafeAllow option described in https://docs.openzeppelin.com/upgrades-plugins/1.x/api-core#usage + * --unsafeAllow option described in https://docs.openzeppelin.com/upgrades-plugins/api-core#usage */ string unsafeAllow; /* From 771df59e25c29469c808fa038e6e37eca7bc5853 Mon Sep 17 00:00:00 2001 From: Eric Lau Date: Thu, 2 Jan 2025 16:12:38 -0500 Subject: [PATCH 2/2] Update changelog --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index faf1872..13cf4a0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,7 +2,7 @@ ## Unreleased -- Update documentation links. +- Update documentation links. ([#88](https://github.com/OpenZeppelin/openzeppelin-foundry-upgrades/pull/88)) ## 0.3.6 (2024-09-24)