mirror of
https://github.com/sxyazi/yazi.git
synced 2026-07-25 08:41:05 +00:00
Some rewording
This commit is contained in:
parent
4dc21053bf
commit
0a39087852
1 changed files with 63 additions and 32 deletions
|
|
@ -1,7 +1,11 @@
|
||||||
# Contributing to Yazi
|
# Contributing to Yazi
|
||||||
|
|
||||||
Thank you for your interest in contributing to Yazi! We welcome contributions in the form of bug reports, feature requests, documentation improvements, and code changes. This guide will help you understand how to contribute to the project.
|
Thank you for your interest in contributing to Yazi! We welcome contributions in the form of bug reports, feature requests, documentation improvements, and code changes.
|
||||||
|
|
||||||
|
This guide will help you understand how to contribute to the project.
|
||||||
|
|
||||||
## Table of Contents
|
## Table of Contents
|
||||||
|
|
||||||
1. [Getting Started](#getting-started)
|
1. [Getting Started](#getting-started)
|
||||||
2. [Project Structure](#project-structure)
|
2. [Project Structure](#project-structure)
|
||||||
3. [Development Setup](#development-setup)
|
3. [Development Setup](#development-setup)
|
||||||
|
|
@ -10,114 +14,141 @@ Thank you for your interest in contributing to Yazi! We welcome contributions in
|
||||||
6. [Communication](#communication)
|
6. [Communication](#communication)
|
||||||
|
|
||||||
## Getting Started
|
## Getting Started
|
||||||
|
|
||||||
### Prerequisites
|
### Prerequisites
|
||||||
|
|
||||||
Before you begin, ensure you have met the following requirements:
|
Before you begin, ensure you have met the following requirements:
|
||||||
|
|
||||||
- Rust installed on your machine. You can download it from [rustup.rs](https://rustup.rs).
|
- Rust installed on your machine. You can download it from [rustup.rs](https://rustup.rs).
|
||||||
- Familiarity with Git and GitHub.
|
- Familiarity with Git and GitHub.
|
||||||
|
|
||||||
### Fork the Repository
|
### Fork the Repository
|
||||||
1. Fork the [yazi repository](https://github.com/sxyazi/yazi) to your GitHub account.
|
|
||||||
|
1. Fork the [Yazi repository](https://github.com/sxyazi/yazi) to your GitHub account.
|
||||||
2. Clone your fork to your local machine:
|
2. Clone your fork to your local machine:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
git clone https://github.com/<your-username>/yazi.git
|
git clone https://github.com/<your-username>/yazi.git
|
||||||
```
|
```
|
||||||
|
|
||||||
3. Set up the upstream remote:
|
3. Set up the upstream remote:
|
||||||
```sh
|
```sh
|
||||||
git remote add upstream https://github.com/sxyazi/yazi.git
|
git remote add upstream https://github.com/sxyazi/yazi.git
|
||||||
```
|
```
|
||||||
|
|
||||||
## Project Structure
|
## Project Structure
|
||||||
|
|
||||||
A brief overview of the project's structure:
|
A brief overview of the project's structure:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
yazi/
|
yazi/
|
||||||
├── assets/ # Assets like images and fonts
|
├── assets/ # Assets like images and fonts
|
||||||
├── nix/ # Nix-related configurations
|
├── nix/ # Nix-related configurations
|
||||||
├── scripts/ # Helper scripts
|
├── scripts/ # Helper scripts used by CI/CD
|
||||||
├── snap/ # Snapcraft configuration
|
├── snap/ # Snapcraft configuration
|
||||||
├── yazi-adaptor/ # Adaptor module
|
├── yazi-adaptor/ # Yazi image adaptor
|
||||||
├── yazi-boot/ # Boot module
|
├── yazi-boot/ # Yazi bootstrapper
|
||||||
├── yazi-cli/ # CLI module
|
├── yazi-cli/ # Yazi command-line interface
|
||||||
├── yazi-config/ # Configuration module
|
├── yazi-config/ # Yazi configuration file parser
|
||||||
├── yazi-core/ # Core functionalities
|
├── yazi-core/ # Yazi core logic
|
||||||
├── yazi-dds/ # Data distribution service
|
├── yazi-dds/ # Yazi data distribution service
|
||||||
├── yazi-fm/ # File management module
|
├── yazi-fm/ # Yazi File Manager
|
||||||
├── yazi-plugin/ # Plugin system
|
├── yazi-plugin/ # Yazi plugin system
|
||||||
├── yazi-proxy/ # Proxy module
|
├── yazi-proxy/ # Yazi event proxy
|
||||||
├── yazi-scheduler/ # Task scheduler
|
├── yazi-scheduler/ # Yazi task scheduler
|
||||||
├── yazi-shared/ # Shared utilities
|
├── yazi-shared/ # Yazi shared library
|
||||||
├── .github/ # GitHub-specific files and workflows
|
├── .github/ # GitHub-specific files and workflows
|
||||||
├── Cargo.toml # Rust project configuration
|
├── Cargo.toml # Rust workflow configuration
|
||||||
└── README.md # Project overview
|
└── README.md # Project overview
|
||||||
```
|
```
|
||||||
|
|
||||||
## Development Setup
|
## Development Setup
|
||||||
|
|
||||||
1. Ensure Rust is installed:
|
1. Ensure the latest stable Rust is installed:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
rustc --version
|
rustc --version
|
||||||
cargo --version
|
cargo --version
|
||||||
```
|
```
|
||||||
|
|
||||||
2. Build the project:
|
2. Build the project:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
cargo build
|
cargo build
|
||||||
```
|
```
|
||||||
|
|
||||||
3. Run the tests:
|
3. Run the tests:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
cargo test
|
cargo test
|
||||||
```
|
```
|
||||||
4. Format the code (requires the nightly version of `rustfmt`):
|
|
||||||
|
4. Format the code (requires `rustfmt` nightly):
|
||||||
```sh
|
```sh
|
||||||
rustup component add rustfmt --toolchain nightly
|
rustup component add rustfmt --toolchain nightly
|
||||||
rustfmt +nightly **/*.rs
|
rustfmt +nightly **/*.rs
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
## How to Contribute
|
## How to Contribute
|
||||||
|
|
||||||
### Reporting Bugs
|
### Reporting Bugs
|
||||||
If you find a bug, please create an issue
|
|
||||||
|
If you find a bug, please file an issue.
|
||||||
|
|
||||||
### Suggesting Features
|
### Suggesting Features
|
||||||
If you have a feature request, please create an issue
|
|
||||||
|
If you have a feature request, please file an issue.
|
||||||
|
|
||||||
### Improving Documentation
|
### Improving Documentation
|
||||||
Yazi's documentation repository is located at [yazi-rs.github.io](https://github.com/yazi-rs/yazi-rs.github.io). Contributions related to documentation need to be made within this repository.
|
|
||||||
|
Yazi's documentation placed at [yazi-rs/yazi-rs.github.io](https://github.com/yazi-rs/yazi-rs.github.io), contributions related to documentation need to be made within this repository.
|
||||||
|
|
||||||
### Submitting Code Changes
|
### Submitting Code Changes
|
||||||
|
|
||||||
1. Create a new branch for your changes:
|
1. Create a new branch for your changes:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
git checkout -b feature/your-feature-name
|
git checkout -b your-branch-name
|
||||||
```
|
```
|
||||||
2. Make your changes. Ensure that your code follows the project's coding standards and passes all tests.
|
|
||||||
|
2. Make your changes. Ensure that your code follows the project's [coding style](https://github.com/sxyazi/yazi/blob/main/rustfmt.toml) and passes all tests.
|
||||||
3. Commit your changes with a descriptive commit message:
|
3. Commit your changes with a descriptive commit message:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
git commit -m "Add feature: description of the feature"
|
git commit -m "feat: an awesome feature"
|
||||||
```
|
```
|
||||||
|
|
||||||
4. Push your changes to your fork:
|
4. Push your changes to your fork:
|
||||||
```sh
|
```sh
|
||||||
git push origin feature/your-feature-name
|
git push origin your-branch-name
|
||||||
```
|
```
|
||||||
|
|
||||||
## Pull Request Process
|
## Pull Request Process
|
||||||
|
|
||||||
1. Ensure your fork is up-to-date with the upstream repository:
|
1. Ensure your fork is up-to-date with the upstream repository:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
git fetch upstream
|
git fetch upstream
|
||||||
git checkout main
|
git checkout main
|
||||||
git merge upstream/main
|
git merge upstream/main
|
||||||
```
|
```
|
||||||
|
|
||||||
2. Rebase your feature branch onto the main branch:
|
2. Rebase your feature branch onto the main branch:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
git checkout feature/your-feature-name
|
git checkout your-branch-name
|
||||||
git rebase main
|
git rebase main
|
||||||
```
|
```
|
||||||
|
|
||||||
3. Create a pull request to the `main` branch of the upstream repository. Follow the pull request template and ensure that:
|
3. Create a pull request to the `main` branch of the upstream repository. Follow the pull request template and ensure that:
|
||||||
- Your code passes all tests and lints.
|
- Your code passes all tests and lints.
|
||||||
- Your pull request description clearly explains the changes and why they are needed.
|
- Your pull request description clearly explains the changes and why they are needed.
|
||||||
4. Address any review comments. Make sure to push updates to the same branch on your fork.
|
4. Address any review comments. Make sure to push updates to the same branch on your fork.
|
||||||
|
|
||||||
## Communication
|
## Communication
|
||||||
|
|
||||||
- Discord Server (English mainly): https://discord.gg/qfADduSdJu
|
- Discord Server (English mainly): https://discord.gg/qfADduSdJu
|
||||||
- Telegram Group (Chinese mainly): https://t.me/yazi_rs
|
- Telegram Group (Chinese mainly): https://t.me/yazi_rs
|
||||||
- For general discussion, use the [Discussions](https://github.com/sxyazi/yazi/discussions) section.
|
- For general discussion, use the [Discussions](https://github.com/sxyazi/yazi/discussions) section.
|
||||||
|
|
||||||
Thank you for your interest in contributing to Yazi!
|
Thank you for your interest in contributing to Yazi!
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue