Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: register-public-key & CLI update to use options instead of args #1397

Merged
merged 7 commits into from
Aug 4, 2023

Conversation

spypsy
Copy link
Member

@spypsy spypsy commented Aug 3, 2023

Fixes #1297
Fixes #1298
Fixes #1306
Also fix issue with noir-contracts bootstrap on MacOS

Checklist:

Remove the checklist to signal you've completed it. Enable auto-merge if the PR is ready to merge.

  • If the pull request requires a cryptography review (e.g. cryptographic algorithm implementations) I have added the 'crypto' tag.
  • I have reviewed my diff in github, line by line and removed unexpected formatting changes, testing logs, or commented-out code.
  • Every change is related to the PR description.
  • I have linked this pull request to relevant issues (if any exist).

@@ -22,14 +22,27 @@ ROOT=$(pwd)

write_import() {
CONTRACT_NAME=$1
NAME=`echo $CONTRACT_NAME | sed -r 's/(^|_)(.)/\U\2/g'`

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nicely done

@spypsy spypsy changed the title fix: CLI update to use options instead of args feat: register-public-key & CLI update to use options instead of args Aug 3, 2023
NAME=`echo $CONTRACT_NAME | sed -r 's/(^|_)(.)/\U\2/g'`

if [ "$(uname)" = "Darwin" ]; then
# sed \U doesn't work on mac
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't we just always use perl for simplicity?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yep don't know why I didn't think of that 😬

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not supported in CI :(

Copy link
Contributor

@benesjan benesjan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Just a minor nitpick.


- `-a, --address <aztecAddress>`: The account's Aztec address.
- `-p, --public-key <publicKey>`: 'The account public key.'
- `-pa, --partial-address <partialAddress`: 'The partially computed address of the account contract.'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would link here the docs Santiago wrote about partial address etc. I feel like these terms are super confusing and I would have no idea what's going on here.

With an Aztec example contract:

```shell
aztec-cli deploy -c ZkTokenContractAbi -a 333 0x134567890abcdef
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be great to add an additional command example-contracts that simply lists the abi names available. e.g. ZkTokenContractAbi.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good idea 👍

@spypsy spypsy merged commit d142181 into master Aug 4, 2023
@spypsy spypsy deleted the sp/cli-updates branch August 4, 2023 11:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
5 participants