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

Pre commit #92

Merged
merged 2 commits into from
Nov 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 4 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"

npm exec lint-staged
25 changes: 25 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,31 @@ npm run tauri build
npm run tauri build -- --bundles app --config "{\"bundle\":{\"macOS\":{\"signingIdentity\":null}}}"
```

### Development Setup

The project uses pre-commit hooks to ensure code consistency. After cloning and installing dependencies, the pre-commit hooks will be automatically installed.

#### Code Formatting

We use Prettier for web code and `cargo fmt` for Rust code. Format your code using:

```bash
# Format all files
npm run format

# Check formatting without making changes
npm run format:check
```

The pre-commit hook will automatically format your code when you commit, but you can run the formatter manually at any time.

#### Pull Requests

Before submitting a PR, please ensure:
1. All code is formatted (`npm run format`)
2. The format check passes (`npm run format:check`)
3. Your commits follow the project's commit message conventions

## Contributing

We welcome contributions from the community! Please see our [contributing guidelines](./.github/CONTRIBUTING.md) for more information.
Expand Down
Loading