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

Update dependencies, deployments & flow config #25

Merged
merged 7 commits into from
Nov 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,7 @@ coverage.json

# Foundry directories
cache/
out/
out/

# Misc local files
.DS_Store
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
[submodule "solidity/lib/forge-std"]
path = solidity/lib/forge-std
url = https://github.com/foundry-rs/forge-std
[submodule "solidity/lib/flow-sol-utils"]
path = solidity/lib/flow-sol-utils
url = https://github.com/onflow/flow-sol-utils
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,13 @@ Given that Flow has both Cadence and EVM runtimes, commit-reveal patterns coveri

|Contract|Testnet|Mainnet|
|---|---|---|
|[CoinToss.cdc](./contracts/CoinToss.cdc)|[0xd1299e755e8be5e7](https://contractbrowser.com/A.d1299e755e8be5e7.CoinToss)|N/A|
|[CoinToss.cdc](./contracts/CoinToss.cdc)|[0xb6c99d7ff216a684](https://contractbrowser.com/A.b6c99d7ff216a684.CoinToss)|N/A|
|[Xorshift128plus.cdc](./contracts/Xorshift128plus.cdc)|[0xed24dbe901028c5c](https://contractbrowser.com/A.ed24dbe901028c5c.Xorshift128plus)|[0x45caec600164c9e6](https://contractbrowser.com/A.45caec600164c9e6.Xorshift128plus)|
|[RandomConsumer.cdc](./contracts/RandomConsumer.cdc)|[0xed24dbe901028c5c](https://contractbrowser.com/A.ed24dbe901028c5c.RandomConsumer)|[0x45caec600164c9e6](https://contractbrowser.com/A.45caec600164c9e6.RandomConsumer)|
|[CoinToss.sol](./contracts/CoinToss.sol)|[0x959922bE3CAee4b8Cd9a407cc3ac1C251C2007B1](https://evm-testnet.flowscan.io/address/0x959922bE3CAee4b8Cd9a407cc3ac1C251C2007B1?tab=contract_code)|N/A|

> :information_source: To use the Solidity dependencies demonstrated in the `CoinToss.sol` example, see the [`@onflow/flow-sol-utils` repository](https://github.com/onflow/flow-sol-utils).

## Further Reading


Expand Down
61 changes: 29 additions & 32 deletions flow.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,18 @@
"aliases": {
"emulator": "f8d6e0586b0a20c7",
"testing": "0000000000000007",
"testnet": "d1299e755e8be5e7"
"testnet": "b6c99d7ff216a684"
}
},
"RandomResultStorage": "./contracts/test/RandomResultStorage.cdc",
"RandomConsumer": {
"source": "./contracts/RandomConsumer.cdc",
"aliases": {
"emulator": "f8d6e0586b0a20c7",
"testing": "0000000000000007"
"testing": "0000000000000007",
"testnet": "ed24dbe901028c5c"
}
},
"RandomResultStorage": "./contracts/test/RandomResultStorage.cdc",
"Xorshift128plus": {
"source": "./contracts/Xorshift128plus.cdc",
"aliases": {
Expand All @@ -32,9 +33,8 @@
"hash": "71af18e227984cd434a3ad00bb2f3618b76482842bae920ee55662c37c8bf331",
"aliases": {
"emulator": "f8d6e0586b0a20c7",
"mainnet": "e467b9dd11fa00df",
"previewnet": "b6763b4399a888c8",
"testnet": "8c5303eaa26202d6"
"mainnet": "f233dcee88fe0abe",
"testnet": "9a0766d93b6608b7"
}
},
"EVM": {
Expand All @@ -43,7 +43,6 @@
"aliases": {
"emulator": "f8d6e0586b0a20c7",
"mainnet": "e467b9dd11fa00df",
"previewnet": "b6763b4399a888c8",
"testnet": "8c5303eaa26202d6"
}
},
Expand All @@ -53,7 +52,6 @@
"aliases": {
"emulator": "0ae53cb6e3f42a79",
"mainnet": "1654653399040a61",
"previewnet": "4445e7ad11568276",
"testnet": "7e60df042a9c0868"
}
},
Expand All @@ -63,7 +61,6 @@
"aliases": {
"emulator": "ee82856bf20e2aa6",
"mainnet": "f233dcee88fe0abe",
"previewnet": "a0225e7000ac82a9",
"testnet": "9a0766d93b6608b7"
}
},
Expand All @@ -73,7 +70,6 @@
"aliases": {
"emulator": "ee82856bf20e2aa6",
"mainnet": "f233dcee88fe0abe",
"previewnet": "a0225e7000ac82a9",
"testnet": "9a0766d93b6608b7"
}
},
Expand All @@ -83,7 +79,6 @@
"aliases": {
"emulator": "f8d6e0586b0a20c7",
"mainnet": "1d7e57aa55817448",
"previewnet": "b6763b4399a888c8",
"testnet": "631e88ae7f1d7c20"
}
},
Expand All @@ -93,7 +88,6 @@
"aliases": {
"emulator": "f8d6e0586b0a20c7",
"mainnet": "1d7e57aa55817448",
"previewnet": "b6763b4399a888c8",
"testnet": "631e88ae7f1d7c20"
}
},
Expand All @@ -103,7 +97,6 @@
"aliases": {
"emulator": "f8d6e0586b0a20c7",
"mainnet": "e467b9dd11fa00df",
"previewnet": "b6763b4399a888c8",
"testnet": "8c5303eaa26202d6"
}
},
Expand All @@ -113,40 +106,38 @@
"aliases": {
"emulator": "f8d6e0586b0a20c7",
"mainnet": "1d7e57aa55817448",
"previewnet": "b6763b4399a888c8",
"testnet": "631e88ae7f1d7c20"
}
}
},
"networks": {
"emulator": "127.0.0.1:3569",
"mainnet": "access.mainnet.nodes.onflow.org:9000",
"previewnet": "access.previewnet.nodes.onflow.org:9000",
"testing": "127.0.0.1:3569",
"testnet": "access.devnet.nodes.onflow.org:9000"
},
"accounts": {
"coin-toss-testnet": {
"address": "d1299e755e8be5e7",
"key": {
"type": "google-kms",
"hashAlgorithm": "SHA2_256",
"resourceID": "projects/dl-flow-admin/locations/global/keyRings/flow-tooling-testnet/cryptoKeys/flow-tooling-testnet-key/cryptoKeyVersions/1"
}
},
"emulator-account": {
"address": "f8d6e0586b0a20c7",
"key": "a30efdca0c2198cc4d4e013f62072fc3013f9f44c4e1a2ebad09f642588168ad"
},
"tooling-mainnet": {
"mainnet-tooling": {
"address": "45caec600164c9e6",
"key": {
"type": "google-kms",
"hashAlgorithm": "SHA2_256",
"resourceID": "projects/dl-flow-admin/locations/global/keyRings/flow-tooling-mainnet/cryptoKeys/flow-tooling-mainnet-key/cryptoKeyVersions/1"
}
},
"tooling-testnet": {
"testnet-coin-toss": {
"address": "b6c99d7ff216a684",
"key": {
"type": "google-kms",
"hashAlgorithm": "SHA2_256",
"resourceID": "projects/dl-flow-admin/locations/global/keyRings/flow-tooling-testnet/cryptoKeys/flow-tooling-testnet-key/cryptoKeyVersions/1"
}
},
"testnet-tooling": {
"address": "ed24dbe901028c5c",
"key": {
"type": "google-kms",
Expand All @@ -159,26 +150,32 @@
"emulator": {
"emulator-account": [
"Xorshift128plus",
"RandomConsumer", {
"RandomConsumer",
{
"name": "CoinToss",
"args": [
{ "type": "UFix64","value": "2.0" }
{
"value": "2.00000000",
"type": "UFix64"
}
]
},
"RandomResultStorage"
]
},
"mainnet": {
"tooling-mainnet": [
"Xorshift128plus"
"mainnet-tooling": [
"Xorshift128plus",
"RandomConsumer"
]
},
"testnet": {
"coin-toss-testnet": [
"testnet-coin-toss": [
"CoinToss"
],
"tooling-testnet": [
"Xorshift128plus"
"testnet-tooling": [
"Xorshift128plus",
"RandomConsumer"
]
}
}
Expand Down
1 change: 1 addition & 0 deletions foundry.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,6 @@ out = "./solidity/out"
libs = ["./solidity/lib"]
script = "./solidity/script"
test = "./solidity/test"
cache_path = "./solidity/cache"

# See more config options https://github.com/foundry-rs/foundry/blob/master/crates/config/README.md#all-options
1 change: 1 addition & 0 deletions remappings.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@flow-sol-utils=solidity/lib/flow-sol-utils
1 change: 1 addition & 0 deletions solidity/lib/flow-sol-utils
Submodule flow-sol-utils added at 082dd3
57 changes: 0 additions & 57 deletions solidity/src/CadenceArchUtils.sol

This file was deleted.

Loading
Loading