Skip to content

Commit

Permalink
chore: cleanup and add ci
Browse files Browse the repository at this point in the history
  • Loading branch information
kopy-kat committed May 21, 2024
1 parent e686369 commit 42d4161
Show file tree
Hide file tree
Showing 8 changed files with 2,636 additions and 123 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
on:
workflow_dispatch:
push:
branches:
- "main"
pull_request:

jobs:
lint:
uses: "rhinestonewtf/reusable-workflows/.github/workflows/forge-lint.yaml@main"

build:
uses: "rhinestonewtf/reusable-workflows/.github/workflows/forge-build.yaml@main"

test:
needs: ["lint", "build"]
uses: "rhinestonewtf/reusable-workflows/.github/workflows/forge-test.yaml@main"
with:
foundry-fuzz-runs: 5000
foundry-profile: "test"
match-path: "test/**/*.sol"
34 changes: 0 additions & 34 deletions .github/workflows/test.yml

This file was deleted.

9 changes: 0 additions & 9 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,3 @@ docs/
# Dotenv file
.env
node_modules

# Samples
/src/validators/SimpleValidator.sol
/src/executors/SimpleExecutor.sol
/src/hooks/SimpleHook.sol

/test/validators/SimpleValidator.t.sol
/test/executors/SimpleExecutor.t.sol
/test/hooks/SimpleHook.t.sol
18 changes: 18 additions & 0 deletions .solhint.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"extends": "solhint:recommended",
"rules": {
"avoid-low-level-calls": "off",
"code-complexity": ["error", 9],
"compiler-version": ["error", ">=0.8.0"],
"contract-name-camelcase": "off",
"const-name-snakecase": "off",
"func-name-mixedcase": "off",
"func-visibility": ["error", { "ignoreConstructors": true }],
"max-line-length": ["error", 123],
"named-parameters-mapping": "warn",
"no-empty-blocks": "off",
"not-rely-on-time": "off",
"one-contract-per-file": "off",
"var-name-mixedcase": "off"
}
}
3 changes: 3 additions & 0 deletions .solhintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
node_modules/
test/
script/
26 changes: 25 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

**A template for building smart account modules using the [ModuleKit](https://github.com/rhinestonewtf/modulekit)**

## Usage
## Using the template

### Install dependencies

Expand Down Expand Up @@ -55,3 +55,27 @@ source .env && forge verify-contract --chain-id [YOUR_CHAIN_ID] --watch --ethers
## Tutorials

For general explainers and guided walkthroughs of building a module, check out our [documentation](https://docs.rhinestone.wtf/modulekit).

## Using this repo

To install the dependencies, run:

```bash
pnpm install
```

To build the project, run:

```bash
forge build
```

To run the tests, run:

```bash
forge test
```

## Contributing

For feature or change requests, feel free to open a PR, start a discussion or get in touch with us.
5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@
"remappings.txt"
],
"homepage": "https://docs.rhinestone.wtf/module-template",
"repository": "github:rhinestonewtf/module-template",
"repository": {
"type": "git",
"url": "https://github.com/rhinestonewtf/module-template.git"
},
"bugs": {
"url": "https://github.com/rhinestonewtf/module-template/issues"
},
Expand Down
Loading

0 comments on commit 42d4161

Please sign in to comment.