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

Push the latest contracts #516

Merged
merged 27 commits into from
Jan 10, 2024
Merged
Changes from 1 commit
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
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
Next Next commit
CI: deploy contracts on local ganache chain (#367)
Co-authored-by: raulk <raul@protocol.ai>
snissn and raulk authored Dec 21, 2023
commit bf36dba67ca30de03b5d671374bdb59cf27db6f6
44 changes: 44 additions & 0 deletions .github/workflows/build-and-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Build and Test Workflow

on:
push:
branches:
- main
- dev
pull_request:

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v2

- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: '18' # Adjust this as needed for your project

- name: Install dependencies
run: npm install

- name: Install Foundry
run: |
curl -L https://foundry.paradigm.xyz | bash
export PATH="$PATH:/home/runner/.config/.foundry/bin"
foundryup
forge install

- name: Generate Ethereum Private Key and Create .env File and run make
run: |
PRIVATE_KEY=$(node -e "console.log(require('crypto').randomBytes(32).toString('hex'))")
echo "export PRIVATE_KEY=0x$PRIVATE_KEY" > .env
echo "export RPC_URL=http://127.0.0.1:1337" >> .env
echo "export CHAIN_ID=1337" >> .env
export PATH="$PATH:/home/runner/.config/.foundry/bin"
npx ganache-cli -g0 -p1337 --account 0x$PRIVATE_KEY,1001901919191919191 &
sleep 5
make