Skip to content

Commit 1c93382

Browse files
committed
feat(oft-main): add Aptos support for multi-VM wiring
Enable Aptos OFT wiring in oft-main example: - Add INCLUDE_APTOS, APTOS_ENFORCED_OPTIONS in layerzero.config.ts - Add aptosContract definition and pathway generation - Update tasks/aptos/index.ts to use real Aptos devtools packages - Remove Aptos filtering from wire.ts graph processing - Add Aptos environment variables to .env.example - Add aptos/deploy.json.example - Add Aptos devtools packages to package.json
1 parent 9fd740c commit 1c93382

140 files changed

Lines changed: 27694 additions & 0 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

examples/oft-main/.env.example

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# .-.-. .-.-. .-.-. .-.-. .-.-. .-.-. .-.-. .-.-
2+
# / / \ \ / / \ \ / / \ \ / / \ \ / / \ \ / / \ \ / / \ \ / / \
3+
# `-' `-`-' `-`-' `-`-' `-`-' `-`-' `-`-' `-`-'
4+
#
5+
# Example environment configuration
6+
#
7+
# .-.-. .-.-. .-.-. .-.-. .-.-. .-.-. .-.-. .-.-
8+
# / / \ \ / / \ \ / / \ \ / / \ \ / / \ \ / / \ \ / / \ \ / / \
9+
# `-' `-`-' `-`-' `-`-' `-`-' `-`-' `-`-' `-`-'
10+
11+
# EVM Variables
12+
# By default, the examples support both mnemonic-based and private key-based authentication
13+
# You don't need to set both of these values, just pick the one that you prefer and set that one
14+
MNEMONIC=
15+
# Private key for EVM contract owner/delegate
16+
PRIVATE_KEY=
17+
18+
# Solana Variables
19+
SOLANA_PRIVATE_KEY=
20+
SOLANA_KEYPAIR_PATH=
21+
# By default, the Solana example will use the default cluster RPC URL if no other value is provided
22+
RPC_URL_SOLANA=
23+
RPC_URL_SOLANA_TESTNET=
24+
25+
# Sui Variables
26+
SUI_PRIVATE_KEY=
27+
RPC_URL_SUI=
28+
RPC_URL_SUI_TESTNET=
29+
30+
# Starknet Variables
31+
# NOTE: Starknet needs the account contract address (not the public key) + private key.
32+
STARKNET_ACCOUNT_ADDRESS=
33+
STARKNET_PRIVATE_KEY=
34+
RPC_URL_STARKNET=
35+
RPC_URL_STARKNET_TESTNET=
36+
37+
# Aptos Variables
38+
APTOS_PRIVATE_KEY=
39+
RPC_URL_APTOS=
40+
RPC_URL_APTOS_TESTNET=

examples/oft-main/.eslintignore

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
.anchor
2+
.turbo
3+
node_modules
4+
target
5+
artifacts
6+
cache
7+
dist
8+
out
9+
*.log
10+
*.sol
11+
*.yaml
12+
*.lock
13+
package-lock.json

examples/oft-main/.eslintrc.js

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
require('@rushstack/eslint-patch/modern-module-resolution');
2+
3+
module.exports = {
4+
root: true,
5+
extends: ['@layerzerolabs/eslint-config-next/recommended'],
6+
rules: {
7+
// @layerzerolabs/eslint-config-next defines rules for turborepo-based projects
8+
// that are not relevant for this particular project
9+
'turbo/no-undeclared-env-vars': 'off',
10+
'import/no-unresolved': 'warn',
11+
},
12+
};

examples/oft-main/.gitignore

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
.anchor
2+
node_modules
3+
.env
4+
coverage
5+
coverage.json
6+
target
7+
typechain
8+
typechain-types
9+
10+
# Hardhat files
11+
cache
12+
artifacts
13+
14+
# LayerZero specific files
15+
.layerzero
16+
17+
# foundry test compilation files
18+
out
19+
20+
# pnpm
21+
pnpm-error.log
22+
23+
# Editor and OS files
24+
.DS_Store
25+
.idea
26+
27+
# Deployment artifacts (user-specific, created during deploy)
28+
deployments/
29+
30+
# Sui build artifacts and deployment info
31+
sui/*/build/
32+
sui/deploy.json
33+
sui/**/oft_deploy.json
34+
sui/**/token_deploy.json
35+
36+
# Starknet deployment info
37+
starknet/deploy.json
38+
39+
# Aptos deployment info
40+
aptos/deploy.json
41+
42+
# Move build artifacts
43+
build/
44+
.aptos/

examples/oft-main/.nvmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
v20.19.5

examples/oft-main/.prettierignore

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
.anchor
2+
.turbo
3+
node_modules/
4+
target
5+
artifacts/
6+
cache/
7+
dist/
8+
out/
9+
*.log
10+
*ignore
11+
*.yaml
12+
*.lock
13+
package-lock.json
14+
package.json

examples/oft-main/.prettierrc.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
module.exports = {
2+
...require('@layerzerolabs/prettier-config-next'),
3+
};

examples/oft-main/.solhintrc.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
module.exports = {
2+
extends: ['solhint:recommended', require.resolve('@layerzerolabs/solhint-config')],
3+
};

examples/oft-main/Anchor.toml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
[toolchain]
2+
anchor_version = "0.31.1"
3+
4+
[features]
5+
seeds = false
6+
resolution = false
7+
skip-lint = false
8+
9+
[programs.localnet]
10+
oft = "G2BYTnfGCMQAErMZkTBCFSapKevzf6QCjizjXi8hFEtJ"
11+
12+
[registry]
13+
url = "https://api.apr.dev"
14+
15+
[provider]
16+
cluster = "Localnet"
17+
wallet = "./junk-id.json"
18+
19+
[scripts]
20+
test = "npx jest test/anchor"

0 commit comments

Comments
 (0)