Skip to content

Commit 2e0a17c

Browse files
SyedAsadKazmiaelmanaa
authored andcommitted
Hardhat -> Foundry, update contracts,ccip & oz pkg
1 parent a7b583a commit 2e0a17c

File tree

110 files changed

+8574
-7725
lines changed

Some content is hidden

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

110 files changed

+8574
-7725
lines changed

.github/workflows/test.yml

Lines changed: 9 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -50,21 +50,25 @@ jobs:
5050
steps:
5151
- name: Checkout Repo
5252
uses: actions/checkout@v5
53-
53+
5454
- name: Setup Node.js
5555
uses: actions/setup-node@v5
5656
with:
5757
node-version: '20'
5858
cache: 'npm'
5959
cache-dependency-path: '**/package-lock.json'
6060

61-
# Restore node_modules from setup job
61+
# Install Foundry
62+
- uses: foundry-rs/foundry-toolchain@82dee4ba654bd2146511f85f0d013af94670c4de # v1.4.0
63+
with:
64+
version: stable # or nightly
65+
66+
# Restore node_modules
6267
- name: Restore node_modules
6368
uses: actions/cache@v4
6469
continue-on-error: true
6570
with:
66-
path: |
67-
node_modules
71+
path: node_modules
6872
key: ${{ runner.os }}-node-modules-${{ hashFiles('**/package-lock.json') }}
6973
restore-keys: |
7074
${{ runner.os }}-node-modules-
@@ -76,21 +80,6 @@ jobs:
7680
npm ci --prefer-offline --no-audit
7781
fi
7882
79-
# Cache Solidity compilation artifacts
80-
- name: Restore compilation caches
81-
id: cache-solidity
82-
uses: actions/cache@v4
83-
continue-on-error: true
84-
with:
85-
path: |
86-
.test/artifacts
87-
.test/cache
88-
~/.cache/hardhat
89-
typechain-types
90-
key: ${{ runner.os }}-solidity-${{ hashFiles('public/samples/**/*.sol', 'hardhat.config.cts') }}
91-
restore-keys: |
92-
${{ runner.os }}-solidity-
93-
9483
- name: Check Solidity Compilation
9584
run: |
9685
echo "Running Solidity compilation with cache..."
@@ -100,7 +89,7 @@ jobs:
10089
run: |
10190
echo "Running Solhint..."
10291
npm run lint-solc
103-
92+
10493
# Job 2: Check ESLint
10594
eslint:
10695
needs: setup

foundry.toml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# This configuration file sets up the paths and compilers so we can test our solidity samples
2+
[profile.default]
3+
4+
src = "public/samples"
5+
6+
out = ".test/artifacts"
7+
cache_path = ".test/cache"
8+
9+
libs = ["lib", "node_modules"]
10+
11+
# Let Forge download/choose solc per file's pragma automatically
12+
auto_detect_solc = true
13+
14+
[lint]
15+
lint_on_build = false
16+
# If you ever want to pin a single version for all files, uncomment:
17+
# solc_version = "0.8.24"

hardhat.config.cts

Lines changed: 0 additions & 29 deletions
This file was deleted.

0 commit comments

Comments
 (0)