Skip to content

Commit

Permalink
[wip] fix(forge): fmt write chunk (#1717)
Browse files Browse the repository at this point in the history
* keep tack of emitter of logs (#1669)

* [not compiling] keep tack of emitter of logs

by switching from RawLog to Log

* ugly fix

* cargo +nightly fmt

* Add comment

Co-authored-by: Bjerg <[email protected]>

* fix variable name

Co-authored-by: Bjerg <[email protected]>
Co-authored-by: Matthias Seitz <[email protected]>

* provide default impls for remaining visitor methods (#1706)

* chore(clippy): make clippy happy (#1707)

* chore: bump ethers

* feat(bind): option to skip Cargo.toml from consistency checks (#1702)

* feat(bind): option to skip Cargo.toml from consistency checks

* chore: cargo fmt

* Update cli/src/cmd/forge/bind.rs

Co-authored-by: Matthias Seitz <[email protected]>

* chore: clippy lints

Co-authored-by: Matthias Seitz <[email protected]>
Co-authored-by: Georgios Konstantopoulos <[email protected]>

* fix(verify): encode constructor arguments correctly (#1711)

* fix(verify): encode constructor arguments correctly

* chore: rotate api keys

* Update cli/tests/it/verify.rs

Co-authored-by: Georgios Konstantopoulos <[email protected]>

* feat: use rotating api keys in fork unit tests (#1693)

* feat: use rotating api keys in fork unit tests

* fix: use correct path

Co-authored-by: Georgios Konstantopoulos <[email protected]>

* refactor: spawn backendhandler on background thread (#1704)

* fix(watch): only watch dirs that exists (#1710)

* Switch selector database to sig.eth.samczsun.com (#1674)

* feat(utils): use samczsun selector directory

This commit switches the utils crate to use samczsun's new function
selector over 4byte for an improved interface and better stability

* feat(cast): update cli to use new 4byte interface

The util bindings were changed to use samczsun's selector library in the
previous commit; this commit updates the cast cli to properly use the
slightly changed interface.

Also ran cargo fmt which updated some unrelated formatting

* fix: review comments

- undo unrelated cargo fmt changes
- rename fourbyte_* -> decode_* in utils

* fix: remove fourbyte test helper

No longer necessary with sig.eth.samczsun.com

* Add `forge upload-selectors` command (#1676)

* feat: add upload selectors command to forge

This commit adds a new command to forge to upload a contract's abi to
sig.eth.samczsun.com selector database

* fix: review comments

- added default for CoreBuildArgs
- cleaned up code ordering
- moved url to constant

* fix: derive CoreBuildArgs::Default

* test: rotate rinkeby keys

* fix(forge/install): add git status check before commit (#1696)

* fix(forge/install): add git status check before commit

* move logic to git_status_clean function

Co-authored-by: test <[email protected]>

* write chunk

* restore original

* write chunks w/ paren

* semicolon cleanup

* write_semicolon

* feat: add `cast upload-signature` (#1716)

* feat: add `cast upload-signature`

This commit adds a new cast command to upload a raw function signature
to the https://sig.eth.samczsun.com 4byte database.

It also moves some of the original signature upload logic from `forge
upload-selectors` to a helper in foundry_utils

API looks like:
```
❯ cast upload-signature 'function approve(address,uint256)' 'transfer(uint256)' 'event Transfer(uint256,address)'
Duplicated: Function approve(address,uint256): 0x095ea7b3
Duplicated: Function transfer(uint256): 0x12514bba
Duplicated: Event Transfer(uint256,address): 0xabe1dcf9fcb8e5fb309db76bcab112a217aa5754d0f038921282bfe7907aa516
```

* fix: move selectors utils to separate module

* fix: add examples to cli help

* test(cast): add integration test for `cast upload-signature`

* feat(cast): allow uploading contract artifacts

This commit enables the `cast upload-signatures` tool to take contract
artifact files and upload the entire json to sig.eth.samczsun.com

* test: update failing tests (#1714)

* test: fix flaky timestamp test (#1727)

* fix: expressive value_name in clap annotations (#1700)

* value_name in forge test

* test debug help

* remove help and revert debug value_name to TEST FUNCTION

* forge test value_name

* forge value_name

* forge args add value_name

* all cast value_name

* Update cli/src/cmd/cast/run.rs

Co-authored-by: Matthias Seitz <[email protected]>

* cast FourByteDecode merge conflict

Co-authored-by: Matthias Seitz <[email protected]>

* ClapChain value_name (#1731)

* utils & cleanup

* fix(forge/install): git status check (#1732)

* fix(cli): can_update_libs_section test (#1733)

* write_chunk! where possible

* func def fmt

* fix attrs

* tests

* linter

* anvil value_name (#1743)

* docs

* indented & indented_if

* unused import

* cleanup

* ci: add additional ci jobs for forks (#1728)

* ci: add additional ci jobs for forks

* test: fix flaky anvil test

* ci: setup git config

* ci: setup git config

* ci: setup git config global

* chore: fix flaky snapshot test

* fix: enable tokio time feature (#1750)

* chore(deps): replace colored with yansi (#1722)

* feat(config): add allow paths setting (#1751)

* ci: set git config global in cross platform ci (#1754)

* ci: set git config global in cross platform ci

* fix: flaky tests

* fix: use proper types

* fix(cast): improve cast wallet new (#1713)

* fix(cast): improve cast wallet new

* chore: cleanup imports

Co-authored-by: jole <[email protected]>
Co-authored-by: Bjerg <[email protected]>
Co-authored-by: Matthias Seitz <[email protected]>
Co-authored-by: Georgios Konstantopoulos <[email protected]>
Co-authored-by: Meet Mangukiya <[email protected]>
Co-authored-by: marktoda <[email protected]>
Co-authored-by: 0xYYY <[email protected]>
Co-authored-by: test <[email protected]>
Co-authored-by: Shawn Harmsen <[email protected]>
  • Loading branch information
10 people authored and jpopesculian committed Jun 8, 2022
1 parent 2a90edd commit 880ea82
Show file tree
Hide file tree
Showing 6 changed files with 322 additions and 360 deletions.
2 changes: 1 addition & 1 deletion cli/src/cmd/forge/fmt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ impl Cmd for FmtArgs {
std::env::current_dir().expect("failed to get current directory")
});
if !root.is_dir() {
return Err(eyre::eyre!("Root path should be a directory"));
eyre::bail!("Root path should be a directory")
}

ProjectPathsConfig::find_source_dir(&root)
Expand Down
Loading

0 comments on commit 880ea82

Please sign in to comment.