Skip to content

Commit

Permalink
fix: add missing docs files
Browse files Browse the repository at this point in the history
  • Loading branch information
roderik committed Aug 17, 2024
1 parent 84c9706 commit 454b2ed
Show file tree
Hide file tree
Showing 3 changed files with 77 additions and 3 deletions.
3 changes: 0 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@ out/
/broadcast/*/31337/
/broadcast/**/dry-run/

# Docs
docs/

# Dotenv file
.env

Expand Down
67 changes: 67 additions & 0 deletions docs/basic-usage.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
# Basic Usage

## Build

You can either use Forge:

```shell
btp-scs foundry build
```

or Hardhat:

```shell
btp-scs hardhat build
```

## Test

With Forge:

```shell
btp-scs foundry test
```

or Hardhat:

```shell
btp-scs hardhat test
```

## Format

To format your contracts, run

```shell
btp-scs foundry format
```

## Deploy to local network

You can deploy your contracts to a local network. First, run

```shell
btp-scs hardhat network
```

then:

```shell
btp-scs hardhat deploy local -m ignition/modules/main.ts
```

## Deploy to platform network

You can also deploy your contracts to the network running on the platform by executing the following command:

```shell
btp-scs hardhat deploy remote -m ignition/modules/main.ts
```

## Help

To get info about the tasks, run:

```shell
btp-scs --help
```
10 changes: 10 additions & 0 deletions docs/subgraph.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Subgraph Usage

## Deploy your subgraph

To index your smart contract events, use The Graph middleware.
First, edit `subgraph.config.json` to set the addresses of your smart contracts. You can find them in the deployment folder created under `ignation`. Then, run:

```shell
btp-scs subgraph deploy
```

0 comments on commit 454b2ed

Please sign in to comment.