Thank you so much for considering contributing to the daan project! We welcome contributions of all kinds, whether it's reporting bugs, submitting feature requests, or contributing code directly.
To ensure a smooth process, please take a moment to read the following guidelines.
- Code of Conduct
- Prerequisites
- Setting Up the Development Environment
- Running the Project
- Building the Project
- Running Tests and Checks
- Code Formatting
- Submitting Changes
This project adheres to the Contributor Covenant Code of Conduct. By participating, you are expected to uphold this code. Please make sure to read CODE_OF_CONDUCT.md (if it exists, otherwise consider adding one).
Before you begin, please ensure you have the following tools installed on your development machine:
-
Git: For version control.
-
Node.js: Version
>=22.0.0is required. We recommend using a version manager like nvm or fnm to manage Node.js versions. -
pnpm: Version
>=9.0.0is required. This is the package manager used for the project. If you don't have it installed, you can install it via npm:npm install -g pnpm
Alternatively, refer to the official pnpm installation guide.
-
Rust: Since this project uses Tauri (
@tauri-apps/cliis in devDependencies) to build the desktop application, you need the Rust development environment. The easiest way to install it is via rustup:curl --proto '=https' --tlsv1.2 -sSf [https://sh.rustup.rs](https://sh.rustup.rs) | sh
Depending on your operating system, you might also need to install additional system dependencies (like a C compiler, WebView2, etc.). Please consult the Tauri Guide - Prerequisites and follow the setup instructions for your platform carefully.
-
Clone the repository:
git clone git://[github.com/pluveto/daan.git](https://github.com/pluveto/daan.git) cd daan -
Install dependencies: Use
pnpmto install the project's dependencies.pnpm install
Note: The
preinstallscript attempts to configure the Git hooks path.
The project includes a web version and a desktop version built with Tauri.
This command starts the Vite development server with Hot Module Replacement (HMR).
pnpm run dev:webThen open the local address provided by Vite in your browser (usually something like http://localhost:5173).
This command launches the development version of the desktop application using Tauri.
pnpm run dev:desktopThis will compile the Rust backend (if necessary) and open a native desktop window containing the web frontend.
NOTE: you should have the Rust >= 1.81.0 installed on your machine for the desktop version to work. To install and enable for this project, run the following command:
rustup install 1.81.0
rustup override set 1.81.0This command builds the web frontend for production using Vite.
pnpm run build:webThe build artifacts are typically located in the dist directory.
This command builds the production-ready desktop application installer (e.g., .exe, .dmg, .deb) using Tauri.
pnpm run build:desktopThe build artifacts are usually found in the src-tauri/target/release/bundle/ directory, depending on your operating system.
The project includes type checking (TypeScript), unit/integration tests (Vitest), and code format checks (Prettier). To run all checks:
pnpm testYou can also run them individually:
-
TypeScript Type Check:
pnpm run tsc:check
-
Vitest Tests:
pnpm run vitest:run
-
Format Check:
pnpm run lint:format
The project uses Prettier for code formatting, integrated with a Tailwind CSS plugin.
-
Automatically format all supported files:
pnpm run format
-
Check if files adhere to formatting standards (without modifying them):
pnpm run lint:format
It's recommended to run pnpm run format before committing your changes.
- Create a new feature branch from
mainor the latest development branch (git checkout -b my-feature-branch). - Make your code changes.
- Ensure
pnpm testandpnpm run formatpass successfully. - Commit your changes (
git commit -m "feat: Describe your feature"). Use a meaningful commit message. - Push your branch to GitHub (
git push origin my-feature-branch). - Open a Pull Request on the GitHub repository page, describing your changes.
Thank you for your contribution!
Make sure 5172 is not in the excluded port range
net stop winnat
net start winnat
netsh interface ipv4 show excludedportrange protocol=tcp