Skip to content

Commit 4a07c15

Browse files
authored
Refactoring of dir struct (#3819)
* remove test-only data * move cli * consolidate contracts * try to fix ci * fix * update * update * refactoring * more refactoring * update * fix clippy * simplify cargo toml
1 parent a8c44ca commit 4a07c15

File tree

400 files changed

+1661
-2500
lines changed

Some content is hidden

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

400 files changed

+1661
-2500
lines changed

.github/dependabot.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ updates:
4848
- "/tee-worker/omni-executor/client-sdk"
4949
- "/tee-worker/omni-executor/ts-tests"
5050
- "/tee-worker/omni-executor/ts-tests/integration-tests"
51-
- "/tee-worker/omni-executor/accounting-contract/solana"
51+
- "/tee-worker/omni-executor/contracts/accounting/solana"
5252
labels: ["automated-pr"]
5353
groups:
5454
typescript-dependencies:

.github/file-filter.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,5 +47,5 @@ omni_executor_test: &omni_executor_test
4747
- "tee-worker/omni-executor/ts-tests/**"
4848

4949
contract_src:
50-
- "tee-worker/omni-executor/accounting-contract/**"
51-
- "tee-worker/omni-executor/aa-contracts/**"
50+
- "tee-worker/omni-executor/contracts/accounting/**"
51+
- "tee-worker/omni-executor/contracts/aa/**"

.github/workflows/ci.yml

Lines changed: 5 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -59,11 +59,6 @@ on:
5959
description: rebuild-contract
6060
required: true
6161
default: false
62-
rebuild-identity:
63-
type: boolean
64-
description: rebuild-identity
65-
required: true
66-
default: false
6762
push-docker:
6863
type: boolean
6964
description: push-docker
@@ -92,12 +87,10 @@ jobs:
9287
if: ${{ github.event_name == 'push' || !github.event.pull_request.draft }}
9388
outputs:
9489
rebuild_parachain: ${{ steps.env.outputs.rebuild_parachain }}
95-
rebuild_identity: ${{ steps.env.outputs.rebuild_identity }}
9690
rebuild_omni_executor: ${{ steps.env.outputs.rebuild_omni_executor }}
9791
rebuild_contract: ${{ steps.env.outputs.rebuild_contract }}
9892
push_docker: ${{ steps.env.outputs.push_docker }}
9993
run_parachain_test: ${{ steps.env.outputs.run_parachain_test }}
100-
run_identity_test: ${{ steps.env.outputs.run_identity_test }}
10194
run_omni_executor_test: ${{ steps.env.outputs.run_omni_executor_test }}
10295
steps:
10396
- uses: actions/checkout@v5
@@ -116,19 +109,14 @@ jobs:
116109
id: env
117110
run: |
118111
rebuild_parachain=false
119-
rebuild_identity=false
120112
rebuild_omni_executor=false
121113
rebuild_contract=false
122114
push_docker=false
123115
run_parachain_test=false
124-
run_identity_test=false
125116
run_omni_executor_test=false
126117
if [ "${{ github.event.inputs.rebuild-parachain }}" = "true" ] || [ "${{ steps.filter.outputs.parachain_src }}" = "true" ]; then
127118
rebuild_parachain=true
128119
fi
129-
if [ "${{ github.event.inputs.rebuild-identity }}" = "true" ] || [ "${{ steps.filter.outputs.identity_src }}" = "true" ]; then
130-
rebuild_identity=true
131-
fi
132120
if [ "${{ github.event.inputs.rebuild-omni-executor }}" = "true" ] || [ "${{ steps.filter.outputs.omni_executor_src }}" = "true" ]; then
133121
rebuild_omni_executor=true
134122
fi
@@ -143,20 +131,15 @@ jobs:
143131
if [ "${{ steps.filter.outputs.parachain_test }}" = "true" ] || [ "$rebuild_parachain" = "true" ]; then
144132
run_parachain_test=true
145133
fi
146-
if [ "${{ steps.filter.outputs.identity_test }}" = "true" ] || [ "$rebuild_parachain" = "true" ] || [ "$rebuild_identity" = "true" ]; then
147-
run_identity_test=true
148-
fi
149134
if [ "${{ steps.filter.outputs.omni_executor_test }}" = "true" ] || [ "$rebuild_parachain" = "true" ] || [ "$rebuild_omni_executor" = "true" ]; then
150135
run_omni_executor_test=true
151136
fi
152137
153138
echo "rebuild_parachain=$rebuild_parachain" | tee -a $GITHUB_OUTPUT
154-
echo "rebuild_identity=$rebuild_identity" | tee -a $GITHUB_OUTPUT
155139
echo "rebuild_omni_executor=$rebuild_omni_executor" | tee -a $GITHUB_OUTPUT
156140
echo "rebuild_contract=$rebuild_contract" | tee -a $GITHUB_OUTPUT
157141
echo "push_docker=$push_docker" | tee -a $GITHUB_OUTPUT
158142
echo "run_parachain_test=$run_parachain_test" | tee -a $GITHUB_OUTPUT
159-
echo "run_identity_test=$run_identity_test" | tee -a $GITHUB_OUTPUT
160143
echo "run_omni_executor_test=$run_omni_executor_test" | tee -a $GITHUB_OUTPUT
161144
162145
fmt:
@@ -362,14 +345,14 @@ jobs:
362345
uses: foundry-rs/foundry-toolchain@v1
363346

364347
- name: Show Forge version
365-
working-directory: ./tee-worker/omni-executor/aa-contracts
348+
working-directory: ./tee-worker/omni-executor/contracts/aa
366349
run: forge --version
367350

368351
- name: Check AA contracts
369-
working-directory: ./tee-worker/omni-executor/aa-contracts
352+
working-directory: ./tee-worker/omni-executor/contracts/aa
370353
run: |
371354
forge b
372-
forge t --gas-report > ./../../../gasreport.ansi
355+
forge t --gas-report > ./../../../../gasreport.ansi
373356
env:
374357
FOUNDRY_FUZZ_SEED: 0x${{ github.event.pull_request.base.sha || github.sha }}
375358

@@ -399,13 +382,13 @@ jobs:
399382
solana -V
400383
401384
- name: Check bsc accounting contracts
402-
working-directory: ./tee-worker/omni-executor/accounting-contract/bsc
385+
working-directory: ./tee-worker/omni-executor/contracts/accounting/bsc
403386
run: |
404387
forge b
405388
forge t
406389
407390
- name: Check solana accounting contracts
408-
working-directory: ./tee-worker/omni-executor/accounting-contract/solana
391+
working-directory: ./tee-worker/omni-executor/contracts/accounting/solana
409392
run: |
410393
anchor b
411394
# TODO: P-1575 tests fail randomly in CI

.gitmodules

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
[submodule "tee-worker/omni-executor/forge-libs/forge-std"]
2-
path = tee-worker/omni-executor/forge-libs/forge-std
1+
[submodule "tee-worker/omni-executor/contracts/lib/forge-libs/forge-std"]
2+
path = tee-worker/omni-executor/contracts/lib/forge-libs/forge-std
33
url = https://github.com/foundry-rs/forge-std
4-
[submodule "tee-worker/omni-executor/forge-libs/openzeppelin-contracts"]
5-
path = tee-worker/omni-executor/forge-libs/openzeppelin-contracts
4+
[submodule "tee-worker/omni-executor/contracts/lib/forge-libs/openzeppelin-contracts"]
5+
path = tee-worker/omni-executor/contracts/lib/forge-libs/openzeppelin-contracts
66
url = https://github.com/OpenZeppelin/openzeppelin-contracts

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ fmt: fmt-cargo fmt-taplo fmt-ts
104104
fmt-cargo:
105105
@cd parachain && cargo fmt
106106
@cd tee-worker/omni-executor && cargo fmt
107-
@cd tee-worker/omni-executor/accounting-contract/solana && cargo fmt
107+
@cd tee-worker/omni-executor/contracts/accounting/solana && cargo fmt
108108

109109
.PHONY: fmt-taplo ## taplo fmt
110110
fmt-taplo:

0 commit comments

Comments
 (0)