Contributing to AccMan

Thank you for your interest in contributing to AccMan! This guide will help you get started.

Table of Contents

Code of Conduct

By participating in this project, you agree to abide by our Code of Conduct:

Our Pledge

We pledge to make participation in our project a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.

Our Standards

Positive behavior includes:

Unacceptable behavior includes:

How Can I Contribute?

Reporting Bugs

Before creating bug reports, please check existing issues to avoid duplicates.

When submitting a bug report, include:

Suggesting Features

Feature suggestions are welcome! Please:

Contributing Code

We welcome code contributions! Areas where help is needed:

Documentation

Help improve our documentation:

Translation

Help make AccMan available in more languages:

Development Setup

Prerequisites

Getting Started

  1. Fork the repository on GitHub

  2. Clone your fork:
    git clone https://github.com/YOUR_USERNAME/AccMan.git
    cd AccMan
    
  3. Add upstream remote:
    git remote add upstream https://github.com/romirom11/AccMan.git
    
  4. Install dependencies:
    pnpm install
    
  5. Start development:
    pnpm tauri dev
    

Development Workflow

  1. Create a feature branch:
    git checkout -b feature/amazing-feature
    
  2. Start development:
    pnpm tauri dev
    
  3. Make your changes

  4. Test your changes:
    pnpm test
    cargo test
    
  5. Commit your changes:
    git commit -m "feat: add amazing feature"
    
  6. Push to your fork:
    git push origin feature/amazing-feature
    
  7. Create a Pull Request

Contribution Guidelines

Before You Start

Code Quality

Security Considerations

Pull Request Process

Before Submitting

  1. Update your branch with latest upstream changes:
    git fetch upstream
    git rebase upstream/main
    
  2. Run all tests:
    pnpm test
    cargo test
    
  3. Check code formatting:
    pnpm lint
    cargo fmt --check
    cargo clippy
    
  4. Update documentation if needed

Pull Request Template

When creating a PR, include:

## Description
Brief description of changes

## Type of Change
- [ ] Bug fix
- [ ] New feature
- [ ] Breaking change
- [ ] Documentation update

## Testing
- [ ] Tests pass locally
- [ ] Added tests for new functionality
- [ ] Manual testing completed

## Checklist
- [ ] Code follows style guidelines
- [ ] Self-review completed
- [ ] Documentation updated
- [ ] No breaking changes (or documented)

Review Process

  1. Automated checks must pass
  2. Code review by maintainers
  3. Testing on multiple platforms
  4. Security review for sensitive changes
  5. Merge after approval

Style Guidelines

TypeScript/React

// Good
interface UserProps {
  user: User;
  onUpdate: (user: User) => void;
}

const UserCard: React.FC<UserProps> = ({ user, onUpdate }) => {
  const handleEdit = useCallback(() => {
    onUpdate({ ...user, lastModified: new Date() });
  }, [user, onUpdate]);

  return (
    <div className="user-card">
      <h3>{user.name}</h3>
      <button onClick={handleEdit}>Edit</button>
    </div>
  );
};

Rust

/// Encrypts data using AES-256-GCM
/// 
/// # Arguments
/// * `data` - The data to encrypt
/// * `key` - The encryption key
/// 
/// # Returns
/// * `Ok(Vec<u8>)` - Encrypted data with nonce prepended
/// * `Err(CryptoError)` - If encryption fails
pub fn encrypt_data(data: &[u8], key: &[u8]) -> Result<Vec<u8>, CryptoError> {
    let cipher = Aes256Gcm::new_from_slice(key)
        .map_err(|_| CryptoError::InvalidKey)?;
    
    let nonce = Aes256Gcm::generate_nonce(&mut OsRng);
    let ciphertext = cipher.encrypt(&nonce, data)
        .map_err(|_| CryptoError::EncryptionFailed)?;
    
    let mut result = nonce.to_vec();
    result.extend_from_slice(&ciphertext);
    Ok(result)
}

Commit Messages

Use Conventional Commits format:

type(scope): description

[optional body]

[optional footer]

Types:

Examples:

feat(auth): add 2FA support for accounts
fix(ui): resolve button alignment issue
docs(api): update encryption documentation

Documentation

Community

Communication Channels

Getting Help

If you need help:

  1. Check existing documentation
  2. Search GitHub issues and discussions
  3. Ask questions in GitHub Discussions
  4. Tag maintainers if urgent

Recognition

Contributors are recognized through:

Development Tips

Debugging

# Standard development
pnpm tauri dev

# Backend debugging with logs
RUST_LOG=debug pnpm tauri dev

# Specific module debugging
RUST_LOG=accman::storage=debug pnpm tauri dev

Testing

# Run all tests
pnpm test
cargo test

# Watch mode for frontend
pnpm test:watch

# Coverage report
pnpm test:coverage

Building

# Development build with hot reload
pnpm tauri dev

# Production build
pnpm tauri build

# Platform-specific build
pnpm tauri build --target x86_64-pc-windows-msvc

Questions?

Don’t hesitate to ask questions! We’re here to help:

Thank you for contributing to AccMan! 🎉