From 0de4b4659cc57a6bdbfbc893a5a8936544d04c6b Mon Sep 17 00:00:00 2001 From: Paul Razvan Berg Date: Mon, 6 Feb 2023 14:14:14 +0200 Subject: [PATCH] docs: roll v5.0.0 docs: add "files" allowlist in "package.json" docs: capitalize username in CHANGELOG and other files docs: document v5.0.0 in CHANGELOG docs: move release hyperlinks at the top of the CHANGELOG --- .github/FUNDING.yml | 2 +- .gitmodules | 4 +-- CHANGELOG.md | 66 ++++++++++++++++++++++++++++++++------------- README.md | 14 +++++----- package.json | 12 ++++----- 5 files changed, 64 insertions(+), 34 deletions(-) diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml index 465bf57..1d80a65 100644 --- a/.github/FUNDING.yml +++ b/.github/FUNDING.yml @@ -1 +1 @@ -custom: ["https://gitcoin.co/grants/1657/paulrberg-open-source-engineering"] +custom: ["https://gitcoin.co/grants/1657/PaulRBerg-open-source-engineering"] diff --git a/.gitmodules b/.gitmodules index d8dfaae..404f0cb 100644 --- a/.gitmodules +++ b/.gitmodules @@ -5,8 +5,8 @@ [submodule "lib/prb-math"] branch = "v3" path = "lib/prb-math" - url = "https://github.com/paulrberg/prb-math" + url = "https://github.com/PaulRBerg/prb-math" [submodule "lib/prb-test"] branch = "0.3.1" path = "lib/prb-test" - url = "https://github.com/paulrberg/prb-test" + url = "https://github.com/PaulRBerg/prb-test" diff --git a/CHANGELOG.md b/CHANGELOG.md index 60db1ee..8f97e62 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,57 +5,87 @@ All notable changes to this project will be documented in this file. The format is based on [Common Changelog](https://common-changelog.org/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +[5.0.0]: https://github.com/PaulRBerg/prb-contracts/compare/v4.1.1...v5.0.0 +[4.1.1]: https://github.com/PaulRBerg/prb-contracts/compare/v4.1.0...v4.1.1 +[4.1.0]: https://github.com/PaulRBerg/prb-contracts/compare/v4.0.0...v4.1.0 +[4.0.0]: https://github.com/PaulRBerg/prb-contracts/compare/v3.9.0...v4.0.0 +[3.9.0]: https://github.com/PaulRBerg/prb-contracts/compare/v3.8.1...v3.9.0 +[3.8.1]: https://github.com/PaulRBerg/prb-contracts/compare/v3.8.0...v3.8.1 +[3.8.0]: https://github.com/PaulRBerg/prb-contracts/releases/tag/v3.8.0 + +## [5.0.0] - 2023-02-06 + +### Changed + +- Change license to MIT (@PaulRBerg) +- Delete the "\_" prefix from admin functions (@PaulRBerg) +- Improve custom error and function parameter names (@PaulRBerg) +- Improve documentation (@PaulRBerg) +- Improve formatting by running the latest Prettier plugin (@PaulRBerg) +- Improve wording and grammar in NatSpec comments (@PaulRBerg) +- Move contracts to `src` directory (@PaulRBerg) +- Perform approval before transfer in `transferFrom` (@PaulRBerg) +- Refactor `amount` to `value` in the `approve` function of the `ERC20` contract (@PaulRBerg) +- Refactor the `NonStandardERC20` contract to `NonCompliantERC20` (@PaulRBerg) +- Refactor `nonRecoverableTokens` to `tokenDenylist` in `ERC20Recover` (@PaulRBerg) +- Optimize calculations in the `approve`, `burn`, and `mint` functions of the `ERC20` contract (@PaulRBerg) +- Use named arguments in function calls (@PaulRBerg) + +### Added + +- Add new contract `Adminable`, which supersedes `Ownable` (@PaulRBerg) +- Add new contract `ERC20Normalizer` (@PaulRBerg) + +### Removed + +- Remove PRBMath re-exports (@PaulRBerg) +- Remove `Ownable` contract (@PaulRBerg) +- Remove `GodModeERC20` contract (@PaulRBerg) + ## [4.1.1] - 2022-04-06 ### Fixed -- Implement the constructor in the `NonStandardERC20` contract (@paulrberg) +- Implement the constructor in the `NonStandardERC20` contract (@PaulRBerg) ## [4.1.0] - 2022-04-06 ### Added -- Add `burn` and `mint` methods in the `NonStandardERC20` contract (@paulrberg) -- Add a new contract `ERC20GodMode` that replicates `GodModeERC20` (@paulrberg) +- Add `burn` and `mint` methods in the `NonStandardERC20` contract (@PaulRBerg) +- Add a new contract `ERC20GodMode` that replicates `GodModeERC20` (@PaulRBerg) ## [4.0.0] - 2022-04-04 ### Changed - Refactor the `Erc` prefix into `ERC` in all `ERC-20` references - ([#25](https://github.com/paulrberg/prb-contracts/issues/25)) (@paulrberg) + ([#25](https://github.com/PaulRBerg/prb-contracts/issues/25)) (@PaulRBerg) ### Removed -- The `Admin` and `IAdmin` contracts and their related bindings (@paulrberg) +- The `Admin` and `IAdmin` contracts and their related bindings (@PaulRBerg) ## [3.9.0] - 2022-04-03 ### Changed -- Define the custom errors in the smart contract interface files (@paulrberg) +- Define the custom errors in the smart contract interface files (@PaulRBerg) ## [3.8.1] - 2022-03-11 ### Fixed -- Include `CHANGELOG`, `LICENSE` and `README` in the package shipped to npm (@paulrberg) +- Include `CHANGELOG`, `LICENSE` and `README` in the package shipped to npm (@PaulRBerg) ## [3.8.0] - 2022-03-08 ### Changed -- Change the package name from `@paulrberg/contracts` to `@prb/contracts` (@paulrberg) -- Switch from `prb-math` package to `@prb/math` (@paulrberg) -- Update links in README and `package.json` files (@paulrberg) +- Change the package name from `@PaulRBerg/contracts` to `@prb/contracts` (@PaulRBerg) +- Switch from `prb-math` package to `@prb/math` (@PaulRBerg) +- Update links in README and `package.json` files (@PaulRBerg) ### Fixed -- Fix the EIP-2612 permit typehash ([#24](https://github.com/paulrberg/prb-contracts/pull/24)) (@surbhiaudichya) - -[4.1.1]: https://github.com/paulrberg/prb-contracts/compare/v4.1.0...v4.1.1 -[4.1.0]: https://github.com/paulrberg/prb-contracts/compare/v4.0.0...v4.1.0 -[4.0.0]: https://github.com/paulrberg/prb-contracts/compare/v3.9.0...v4.0.0 -[3.9.0]: https://github.com/paulrberg/prb-contracts/compare/v3.8.1...v3.9.0 -[3.8.1]: https://github.com/paulrberg/prb-contracts/compare/v3.8.0...v3.8.1 -[3.8.0]: https://github.com/paulrberg/prb-contracts/releases/tag/v3.8.0 +- Fix the EIP-2612 permit typehash ([#24](https://github.com/PaulRBerg/prb-contracts/pull/24)) (@surbhiaudichya) diff --git a/README.md b/README.md index 21a289b..068745c 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # PRBContracts [![GitHub Actions][gha-badge]][gha] [![Foundry][foundry-badge]][foundry] [![Styled with Prettier][prettier-badge]][prettier] [![License: MIT][license-badge]][license] -[gha]: https://github.com/paulrberg/prb-contracts/actions -[gha-badge]: https://github.com/paulrberg/prb-contracts/actions/workflows/ci.yml/badge.svg +[gha]: https://github.com/PaulRBerg/prb-contracts/actions +[gha-badge]: https://github.com/PaulRBerg/prb-contracts/actions/workflows/ci.yml/badge.svg [foundry]: https://getfoundry.sh/ [foundry-badge]: https://img.shields.io/badge/Built%20with-Foundry-FFDB1C.svg [prettier]: https://prettier.io @@ -27,7 +27,7 @@ find it useful too, that's a win-win. First, run the install step: ```sh -forge install --no-commit paulrberg/prb-contracts +forge install --no-commit PaulRBerg/prb-contracts ``` Then, add the following line to your `remappings.txt` file: @@ -60,8 +60,8 @@ contract MyToken is ERC20, ERC20Permit { ## Contributing -Feel free to dive in! [Open](https://github.com/paulrberg/prb-proxy/issues/new) an issue, -[start](https://github.com/paulrberg/prb-proxy/discussions/new) a discussion or submit a PR. +Feel free to dive in! [Open](https://github.com/PaulRBerg/prb-proxy/issues/new) an issue, +[start](https://github.com/PaulRBerg/prb-proxy/discussions/new) a discussion or submit a PR. ### Pre Requisites @@ -79,7 +79,7 @@ In addition, familiarity with [Solidity](https://soliditylang.org/) is requisite Clone this repository including submodules: ```sh -$ git clone --recurse-submodules -j8 git@github.com:paulrberg/prb-contracts.git +$ git clone --recurse-submodules -j8 git@github.com:PaulRBerg/prb-contracts.git ``` Then, inside the project's directory, run this to install the Node.js dependencies: @@ -109,7 +109,7 @@ will not be liable for any loss, direct or indirect through continued use of thi ### Contact -If you discover any security issues, please contact me via [Keybase](https://keybase.io/paulrberg). +If you discover any security issues, please contact me via [Keybase](https://keybase.io/PaulRBerg). ## Related Efforts diff --git a/package.json b/package.json index 0463ce8..9091780 100644 --- a/package.json +++ b/package.json @@ -1,13 +1,13 @@ { "name": "@prb/contracts", "description": "Off-the-shelf Solidity smart contracts", - "version": "4.1.1", + "version": "5.0.0", "author": { "name": "Paul Razvan Berg", - "url": "https://github.com/paulrberg" + "url": "https://github.com/PaulRBerg" }, "bugs": { - "url": "https://github.com/paulrberg/prb-contracts/issues" + "url": "https://github.com/PaulRBerg/prb-contracts/issues" }, "devDependencies": { "@commitlint/cli": "^17.4.2", @@ -23,10 +23,10 @@ "solhint-plugin-prettier": "^0.0.5" }, "files": [ - "**/*.sol", + "/src", "CHANGELOG.md" ], - "homepage": "https://github.com/paulrberg/prb-contracts#readme", + "homepage": "https://github.com/PaulRBerg/prb-contracts#readme", "keywords": [ "blockchain", "erc20", @@ -43,7 +43,7 @@ "private": true, "repository": { "type": "git", - "url": "https://github.com/paulrberg/prb-contracts" + "url": "https://github.com/PaulRBerg/prb-contracts" }, "scripts": { "build": "forge build",