Skip to content
This repository was archived by the owner on Apr 26, 2025. It is now read-only.

Commit d0bc192

Browse files
authored
Merge pull request #159 from EjembiEmmanuel/main
feat: remove kakarot support
2 parents 47b5876 + ef7db91 commit d0bc192

File tree

5 files changed

+15
-81
lines changed

5 files changed

+15
-81
lines changed

.github/workflows/build_contract.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,13 @@ jobs:
99
runs-on: ubuntu-latest
1010
steps:
1111
- uses: actions/checkout@v3
12+
1213
- uses: software-mansion/setup-scarb@v1
14+
with:
15+
scarb-version: "2.8.2"
16+
1317
- name: Check cairo format
1418
run: cd contracts && scarb fmt --check
19+
1520
- name: Build cairo programs
16-
run: cd contracts && scarb build
21+
run: cd contracts && scarb build

.github/workflows/test_contract.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,14 @@ jobs:
88
runs-on: ubuntu-latest
99
steps:
1010
- uses: actions/checkout@v3
11+
1112
- uses: software-mansion/setup-scarb@v1
13+
with:
14+
scarb-version: "2.8.2"
15+
1216
- uses: foundry-rs/setup-snfoundry@v3
1317
with:
1418
starknet-foundry-version: 0.31.0
19+
1520
- name: Run cairo tests
1621
run: cd contracts && snforge test

bin/cli.mjs

Lines changed: 3 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@ const installPackage = async () => {
3737
"fullstack",
3838
"debugger",
3939
"dojo",
40-
"kakarot",
4140
];
4241
console.log("Available package types:");
4342
packageTypeChoices.forEach((type, index) =>
@@ -47,7 +46,7 @@ const installPackage = async () => {
4746
let packageType;
4847
while (!packageType) {
4948
const packageTypeChoice = await askQuestion(
50-
"Select the package type (1-5): "
49+
`Select the package type (1-${packageTypeChoices.length}): `
5150
);
5251
packageType = packageTypeChoices[parseInt(packageTypeChoice) - 1];
5352
if (!packageType) {
@@ -86,11 +85,7 @@ const installPackage = async () => {
8685
"CNAME",
8786
];
8887

89-
if (
90-
packageType === "fullstack" ||
91-
packageType === "dojo" ||
92-
packageType === "kakarot"
93-
) {
88+
if (packageType === "fullstack" || packageType === "dojo") {
9489
const FRONTEND_BASE_PATH = "frontend/src/app";
9590
const componentsToRemove = [
9691
`${FRONTEND_BASE_PATH}/burner`,
@@ -169,18 +164,6 @@ const installPackage = async () => {
169164
recursive: true,
170165
force: true,
171166
});
172-
} else if (packageType == "kakarot") {
173-
await exec("npm run initialize-kakarot");
174-
175-
await exec("npm run setup-kakarot");
176-
177-
const tool_versions = await getVersionsFromToolFile(
178-
path.join(projectPath, "/contracts/.tool-versions")
179-
);
180-
181-
await exec(
182-
`npm run install --scarb-version=${tool_versions.scarb} --legacy-peer-deps`
183-
);
184167
} else if (packageType !== "contract_only") {
185168
await exec("npm run install --legacy-peer-deps");
186169
}
@@ -190,9 +173,7 @@ const installPackage = async () => {
190173
console.log("You can now run the scaffold with:");
191174
console.log(` cd ${packageName}`);
192175

193-
if (packageType == "kakarot") {
194-
console.log(` npm run start-kakarot`);
195-
} else if (packageType == "contract_only") {
176+
if (packageType == "contract_only") {
196177
console.log(` npm run devnet`);
197178
} else {
198179
console.log(` npm run start`);

docs/src/chapter_5.md

Lines changed: 0 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -108,55 +108,6 @@ To migrate your dojo project, from the base repository run:
108108
npm run migrate-dojo --name=<PROJECT_NAME>
109109
```
110110

111-
## Kakarot Scripts
112-
Below are npm scripts provided by `Starknet-Scaffold` for your Kakarot development.
113-
114-
### Setup Kakarot
115-
To setup Kakarot, from the base repository run:
116-
```
117-
npm run setup-kakarot
118-
```
119-
120-
### Start Kakarot
121-
To start Kakarot, from the base repository run:
122-
```
123-
npm run start-kakarot
124-
```
125-
126-
### Deploy Kakarot L1 Messaging Contracts to Local RPC
127-
To deploy Kakarot l1 messaging contracts locally, from the base repository run:
128-
```
129-
npm run deploy-kakarot-l1-messaging-contracts-local
130-
```
131-
132-
### Deploy Kakarot EVM Contract
133-
To deploy a Kakarot EVM contract, from the base repository run:
134-
```
135-
npm run deploy-kakarot-evm-contract --contract-path=<PATH_TO_CONTRACT> --rpc-url=<RPC_URL> --private-key=<PRIVATE_KEY>
136-
```
137-
If you need to specify constructor args, run:
138-
```
139-
npm run deploy-kakarot-evm-contract --contract-path=<PATH_TO_CONTRACT> --constructor-args=<CONSTRUCTOR_ARGS> --rpc-url=<RPC_URL> --private-key=<PRIVATE_KEY>
140-
```
141-
142-
### Declare Cairo Contract Using Keystore
143-
To declare a Cairo contract using keystore, from the base repository run:
144-
```
145-
npm run keystore-declare-contract --keystore=<PATH_TO_KEYSTORE_FILE> --account=<PATH_TO_ACCOUNTS_FILE> --contract-name=<CONTRACT_NAME> --url=<RPC_URL> --fee-token=<FEE_TOKEN>
146-
```
147-
148-
### Deploy Cairo Contract Using Keystore
149-
To deploy a Cairo contract using keystore, from the base repository run:
150-
```
151-
npm run keystore-deploy-contract --keystore=<PATH_TO_KEYSTORE_FILE> --account=<PATH_TO_ACCOUNTS_FILE> --url=<RPC_URL> --fee-token=<FEE_TOKEN> --class-hash=<CLASS_HASH>
152-
```
153-
154-
### Whitelist Contract
155-
To whitelist a contract, from the base repository run:
156-
```
157-
npm run whitelist-contract --contract-address=<CONTRACT_ADDRESS>
158-
```
159-
160111
## User Interface Scripts
161112

162113
The following are scripts from `Starknet-Scaffold` for handling the user interface.

package.json

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,7 @@
2323
"start": "cd frontend && npm run dev",
2424
"install": "cd scripts && bash install_tools.sh $(test -n \"$npm_config_scarb_version\" && echo --scarb $npm_config_scarb_version) $(test -n \"$npm_config_starknet_foundry_version\" && echo --starknet-foundry $npm_config_starknet_foundry_version) $(test -n \"$npm_config_foundry_version\" && echo --foundry $npm_config_foundry_version) $(test -n \"$npm_config_dojo_version\" && echo --dojo $npm_config_dojo_version) && cd ../frontend && npm install --legacy-peer-deps",
2525
"install-tools": "snfoundryup && foundryup",
26-
"build-ui": "cd frontend && npm run build",
27-
"initialize-kakarot": "git clone https://github.com/kkrt-labs/build-on-kakarot.git && rm -rf contracts && mkdir contracts && cp -r build-on-kakarot/cairo_contracts/. ./contracts && cp -r build-on-kakarot/katana.account.json ./contracts && cp -r build-on-kakarot/katana.key.json ./contracts && mkdir kakarot && cp -r build-on-kakarot/. ./kakarot && cd kakarot && rm -rf cairo_contracts && rm -rf .github && rm -rf .trunk && git init && cd .. && rm -rf build-on-kakarot",
28-
"setup-kakarot": "cd kakarot && make setup",
29-
"start-kakarot": "cd kakarot && make start",
30-
"deploy-kakarot-l1-messaging-contracts-local": "cd kakarot && make deploy-l1",
31-
"deploy-kakarot-evm-contract": "cd kakarot && forge create ${npm_config_contract_path} $(test -n \"$npm_config_constructor_args\" && echo --constructor-args $npm_config_constructor_args) --rpc-url ${npm_config_rpc_url} --private-key ${npm_config_private_key}",
32-
"keystore-declare-contract": "cd contracts && sncast --keystore ${npm_config_keystore} --account ${npm_config_account} declare --contract-name ${npm_config_contract_name} --url ${npm_config_url} --fee-token ${npm_config_fee_token}",
33-
"keystore-deploy-contract": "cd contracts && sncast --keystore ${npm_config_keystore} --account ${npm_config_account} deploy --url ${npm_config_url} --fee-token ${npm_config_fee_token} --class-hash ${npm_config_class_hash}",
34-
"whitelist-contract": "cd kakarot && make whitelist-contract CONTRACT_ADDRESS=${npm_config_contract_address}"
26+
"build-ui": "cd frontend && npm run build"
3527
},
3628
"repository": {
3729
"type": "git",

0 commit comments

Comments
 (0)