-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
3,533 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: Build for all networks | ||
|
||
on: | ||
push: | ||
branches: | ||
- dev | ||
|
||
# Allow workflow to be manually run from the GitHub UI | ||
workflow_dispatch: | ||
|
||
jobs: | ||
create-all-network-branches: | ||
permissions: write-all | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
network: [acala, astar, bifrost_mainnet, bifrost_testnet, contextfree, kusama, karura, polkadot, shiden, shibuya, westend] | ||
fail-fast: false | ||
|
||
env: | ||
NETWORK: ${{ matrix.network }} | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- run: echo "NETWORK -> ${{ env.NETWORK }}" | ||
|
||
- name: Install node | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: "16.x" | ||
cache: "yarn" | ||
cache-dependency-path: "yarn.lock" | ||
|
||
- name: Install dependencies | ||
run: yarn install | ||
|
||
- name: Patch chain | ||
run: yarn patchchain ${{ env.NETWORK }} | ||
|
||
- name: Print project.yaml | ||
run: cat ./project.yaml | ||
|
||
- name: Build project | ||
run: yarn codegen && yarn build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,121 @@ | ||
{ | ||
"typesBundle": { | ||
"spec": { | ||
"contextfree": { | ||
"types": [ | ||
{ | ||
"minmax": [0, null], | ||
"types": { | ||
"ResourceId": "[u8; 32]", | ||
"DepositNonce": "u64", | ||
"ProposalStatus": { | ||
"_enum": ["Initiated", "Approved", "Rejected"] | ||
}, | ||
"ProposalVotes": { | ||
"votes_for": "Vec<AccountId>", | ||
"votes_against": "Vec<AccountId>", | ||
"status": "ProposalStatus" | ||
}, | ||
"BridgeTokenId": "U256", | ||
"BridgeChainId": "u8", | ||
"VestingPlan": { | ||
"start_time": "u64", | ||
"cliff_duration": "u64", | ||
"total_duration": "u64", | ||
"interval": "u64", | ||
"initial_amount": "Balance", | ||
"total_amount": "Balance", | ||
"vesting_during_cliff": "bool" | ||
}, | ||
"ProposalId": "u32", | ||
"ProjectId": "u32", | ||
"ChainIndex": "u32", | ||
"Protocol": { | ||
"_enum": ["Solidity", "Substrate"] | ||
}, | ||
"Chain": { | ||
"_protocol": "Protocol" | ||
}, | ||
"CrossChainAccount": { | ||
"_enum": { | ||
"Solidity": "H160", | ||
"Substrate": "AccountId" | ||
} | ||
}, | ||
"IpfsHash": "Text", | ||
"SolidityStrategy": { | ||
"_enum": { | ||
"ERC20Balance": "H160" | ||
} | ||
}, | ||
"SubstrateStrategy": { | ||
"_enum": ["NativeBalance"] | ||
}, | ||
"Strategy": { | ||
"_enum": { | ||
"Solidity": "SolidityStrategy", | ||
"Substrate": "SubstrateStrategy" | ||
} | ||
}, | ||
"Workspace": { | ||
"_chain": "ChainIndex", | ||
"strategies": "Vec<Strategy>" | ||
}, | ||
"UserGroup": { | ||
"owner": "CrossChainAccount", | ||
"admins": "Vec<CrossChainAccount>", | ||
"maintainers": "Vec<CrossChainAccount>", | ||
"proposers": "Option<Vec<CrossChainAccount>>" | ||
}, | ||
"Project": { | ||
"usergroup": "UserGroup", | ||
"data": "IpfsHash", | ||
"workspaces": "Vec<Workspace>" | ||
}, | ||
"VotingFormat": { | ||
"_enum": ["SingleChoice", "SplitVote"] | ||
}, | ||
"OptionIndex": "u8", | ||
"PrivacyLevel": { | ||
"_enum": { | ||
"Opaque": "u8", | ||
"Rank": "Null", | ||
"Private": "Null", | ||
"Public": "Null", | ||
"Mixed": "Null" | ||
} | ||
}, | ||
"VotingPower": "U256", | ||
"DAOProposalState": { | ||
"finalized": "bool", | ||
"snapshots": "Vec<Option<U256>>", | ||
"blacklisted": "bool", | ||
"votes": "Vec<VotingPower>", | ||
"pub_voters": "Option<IpfsHash>", | ||
"updates": "u32" | ||
}, | ||
"DAOProposal": { | ||
"_author": "CrossChainAccount", | ||
"_voting_format": "VotingFormat", | ||
"_option_count": "OptionIndex", | ||
"_data": "IpfsHash", | ||
"_privacy": "PrivacyLevel", | ||
"_start": "u64", | ||
"_end": "u64", | ||
"_frequency": "Option<u64>", | ||
"_workspaces": "Vec<Workspace>", | ||
"state": "DAOProposalState" | ||
}, | ||
"VoteUpdate": { | ||
"project": "ProjectId", | ||
"proposal": "ProposalId", | ||
"votes": "Vec<VotingPower>", | ||
"pub_voters": "Option<IpfsHash>" | ||
} | ||
} | ||
} | ||
] | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#!/usr/bin/env bash | ||
|
||
# run loop for all networks | ||
NETWORKS=("acala" "astar" "bifrost_mainnet" "bifrost_testnet" "contextfree" "kusama" "karura" "polkadot" "shiden" "shibuya" "westend") | ||
|
||
for NETWORK in ${NETWORKS[@]}; do | ||
echo "NETWORK: $NETWORK" | ||
yarn patchchain $NETWORK | ||
# cat ./project.yaml | ||
yarn codegen | ||
yarn build | ||
done | ||
|
||
echo "All builds complete" | ||
git restore project.yaml src/constants/network.ts |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.