mirror of
https://github.com/kyantech/Palmr.git
synced 2025-10-22 22:02:00 +00:00
fix: update license from BSD-2-Clause to Apache-2.0 in package.json files
This commit is contained in:
27
.github/copilot-instructions.md
vendored
27
.github/copilot-instructions.md
vendored
@@ -5,6 +5,7 @@ This file contains instructions for GitHub Copilot to help contributors work eff
|
|||||||
## Project Overview
|
## Project Overview
|
||||||
|
|
||||||
Palmr is a flexible and open-source alternative to file transfer services like WeTransfer and SendGB. It's built with:
|
Palmr is a flexible and open-source alternative to file transfer services like WeTransfer and SendGB. It's built with:
|
||||||
|
|
||||||
- **Backend**: Fastify (Node.js) with TypeScript, SQLite database, and filesystem/S3 storage
|
- **Backend**: Fastify (Node.js) with TypeScript, SQLite database, and filesystem/S3 storage
|
||||||
- **Frontend**: Next.js 15 + React + TypeScript + Shadcn/ui
|
- **Frontend**: Next.js 15 + React + TypeScript + Shadcn/ui
|
||||||
- **Documentation**: Next.js + Fumadocs + MDX
|
- **Documentation**: Next.js + Fumadocs + MDX
|
||||||
@@ -14,6 +15,7 @@ Palmr is a flexible and open-source alternative to file transfer services like W
|
|||||||
## Architecture and Structure
|
## Architecture and Structure
|
||||||
|
|
||||||
### Monorepo Layout
|
### Monorepo Layout
|
||||||
|
|
||||||
```
|
```
|
||||||
apps/
|
apps/
|
||||||
├── docs/ # Documentation site (Next.js + Fumadocs)
|
├── docs/ # Documentation site (Next.js + Fumadocs)
|
||||||
@@ -22,6 +24,7 @@ apps/
|
|||||||
```
|
```
|
||||||
|
|
||||||
### Key Technologies
|
### Key Technologies
|
||||||
|
|
||||||
- **TypeScript**: Primary language for all applications
|
- **TypeScript**: Primary language for all applications
|
||||||
- **Database**: Prisma ORM with SQLite (optional S3-compatible storage)
|
- **Database**: Prisma ORM with SQLite (optional S3-compatible storage)
|
||||||
- **Authentication**: Multiple OAuth providers (Google, GitHub, Discord, etc.)
|
- **Authentication**: Multiple OAuth providers (Google, GitHub, Discord, etc.)
|
||||||
@@ -31,10 +34,13 @@ apps/
|
|||||||
## Development Workflow
|
## Development Workflow
|
||||||
|
|
||||||
### Base Branch
|
### Base Branch
|
||||||
|
|
||||||
Always create new branches from and submit PRs to the `next` branch, not `main`.
|
Always create new branches from and submit PRs to the `next` branch, not `main`.
|
||||||
|
|
||||||
### Commit Convention
|
### Commit Convention
|
||||||
|
|
||||||
Use Conventional Commits format for all commits:
|
Use Conventional Commits format for all commits:
|
||||||
|
|
||||||
```
|
```
|
||||||
<type>(<scope>): <description>
|
<type>(<scope>): <description>
|
||||||
|
|
||||||
@@ -49,12 +55,14 @@ Types:
|
|||||||
```
|
```
|
||||||
|
|
||||||
Examples:
|
Examples:
|
||||||
|
|
||||||
- `feat(web): add user authentication system`
|
- `feat(web): add user authentication system`
|
||||||
- `fix(api): resolve null pointer exception in user service`
|
- `fix(api): resolve null pointer exception in user service`
|
||||||
- `docs: update installation instructions in README`
|
- `docs: update installation instructions in README`
|
||||||
- `test(server): add unit tests for user validation`
|
- `test(server): add unit tests for user validation`
|
||||||
|
|
||||||
### Code Quality Standards
|
### Code Quality Standards
|
||||||
|
|
||||||
1. **Linting**: All apps use ESLint. Run `pnpm lint` before committing
|
1. **Linting**: All apps use ESLint. Run `pnpm lint` before committing
|
||||||
2. **Formatting**: Use Prettier for code formatting. Run `pnpm format`
|
2. **Formatting**: Use Prettier for code formatting. Run `pnpm format`
|
||||||
3. **Type Checking**: Run `pnpm type-check` to validate TypeScript
|
3. **Type Checking**: Run `pnpm type-check` to validate TypeScript
|
||||||
@@ -62,6 +70,7 @@ Examples:
|
|||||||
5. **Pre-push Hook**: Automatically validates all apps before pushing
|
5. **Pre-push Hook**: Automatically validates all apps before pushing
|
||||||
|
|
||||||
### Testing Changes
|
### Testing Changes
|
||||||
|
|
||||||
- Test incrementally during development
|
- Test incrementally during development
|
||||||
- Run validation locally before pushing: `pnpm validate` in each app directory
|
- Run validation locally before pushing: `pnpm validate` in each app directory
|
||||||
- Keep changes focused on a single issue or feature
|
- Keep changes focused on a single issue or feature
|
||||||
@@ -70,6 +79,7 @@ Examples:
|
|||||||
## Application-Specific Guidelines
|
## Application-Specific Guidelines
|
||||||
|
|
||||||
### Web App (`apps/web/`)
|
### Web App (`apps/web/`)
|
||||||
|
|
||||||
- Framework: Next.js 15 with App Router
|
- Framework: Next.js 15 with App Router
|
||||||
- Port: 3000 (development)
|
- Port: 3000 (development)
|
||||||
- Scripts:
|
- Scripts:
|
||||||
@@ -81,6 +91,7 @@ Examples:
|
|||||||
- `pnpm translations:sync`: Synchronize translations
|
- `pnpm translations:sync`: Synchronize translations
|
||||||
|
|
||||||
### Server App (`apps/server/`)
|
### Server App (`apps/server/`)
|
||||||
|
|
||||||
- Framework: Fastify with TypeScript
|
- Framework: Fastify with TypeScript
|
||||||
- Port: 3333 (default)
|
- Port: 3333 (default)
|
||||||
- Scripts:
|
- Scripts:
|
||||||
@@ -91,6 +102,7 @@ Examples:
|
|||||||
- Database: Prisma ORM with SQLite
|
- Database: Prisma ORM with SQLite
|
||||||
|
|
||||||
### Docs App (`apps/docs/`)
|
### Docs App (`apps/docs/`)
|
||||||
|
|
||||||
- Framework: Next.js with Fumadocs
|
- Framework: Next.js with Fumadocs
|
||||||
- Port: 3001 (development)
|
- Port: 3001 (development)
|
||||||
- Content: MDX files in `content/docs/`
|
- Content: MDX files in `content/docs/`
|
||||||
@@ -102,6 +114,7 @@ Examples:
|
|||||||
## Code Style and Best Practices
|
## Code Style and Best Practices
|
||||||
|
|
||||||
### General Guidelines
|
### General Guidelines
|
||||||
|
|
||||||
1. **Follow Style Guidelines**: Ensure code adheres to ESLint and Prettier configurations
|
1. **Follow Style Guidelines**: Ensure code adheres to ESLint and Prettier configurations
|
||||||
2. **TypeScript First**: Always use TypeScript, avoid `any` types when possible
|
2. **TypeScript First**: Always use TypeScript, avoid `any` types when possible
|
||||||
3. **Component Organization**: Keep components focused and single-purpose
|
3. **Component Organization**: Keep components focused and single-purpose
|
||||||
@@ -110,6 +123,7 @@ Examples:
|
|||||||
6. **Imports**: Use absolute imports where configured, keep imports organized
|
6. **Imports**: Use absolute imports where configured, keep imports organized
|
||||||
|
|
||||||
### API Development (Server)
|
### API Development (Server)
|
||||||
|
|
||||||
- Use Fastify's schema validation for all routes
|
- Use Fastify's schema validation for all routes
|
||||||
- Follow REST principles for endpoint design
|
- Follow REST principles for endpoint design
|
||||||
- Implement proper authentication and authorization
|
- Implement proper authentication and authorization
|
||||||
@@ -117,6 +131,7 @@ Examples:
|
|||||||
- Document API endpoints in the docs app
|
- Document API endpoints in the docs app
|
||||||
|
|
||||||
### Frontend Development (Web)
|
### Frontend Development (Web)
|
||||||
|
|
||||||
- Use React Server Components where appropriate
|
- Use React Server Components where appropriate
|
||||||
- Implement proper loading and error states
|
- Implement proper loading and error states
|
||||||
- Follow accessibility best practices (WCAG guidelines)
|
- Follow accessibility best practices (WCAG guidelines)
|
||||||
@@ -124,6 +139,7 @@ Examples:
|
|||||||
- Use Shadcn/ui components for consistent UI
|
- Use Shadcn/ui components for consistent UI
|
||||||
|
|
||||||
### Documentation
|
### Documentation
|
||||||
|
|
||||||
- Write clear, concise documentation
|
- Write clear, concise documentation
|
||||||
- Include code examples where helpful
|
- Include code examples where helpful
|
||||||
- Update documentation when changing functionality
|
- Update documentation when changing functionality
|
||||||
@@ -142,17 +158,20 @@ Examples:
|
|||||||
## Common Patterns
|
## Common Patterns
|
||||||
|
|
||||||
### Authentication Providers
|
### Authentication Providers
|
||||||
|
|
||||||
- Provider configurations in `apps/server/src/modules/auth-providers/providers.config.ts`
|
- Provider configurations in `apps/server/src/modules/auth-providers/providers.config.ts`
|
||||||
- Support for OAuth2 and OIDC protocols
|
- Support for OAuth2 and OIDC protocols
|
||||||
- Field mappings for user data normalization
|
- Field mappings for user data normalization
|
||||||
- Special handling for providers like GitHub that require additional API calls
|
- Special handling for providers like GitHub that require additional API calls
|
||||||
|
|
||||||
### File Storage
|
### File Storage
|
||||||
|
|
||||||
- Default: Filesystem storage
|
- Default: Filesystem storage
|
||||||
- Optional: S3-compatible object storage
|
- Optional: S3-compatible object storage
|
||||||
- File metadata stored in SQLite database
|
- File metadata stored in SQLite database
|
||||||
|
|
||||||
### Environment Variables
|
### Environment Variables
|
||||||
|
|
||||||
- Configure via `.env` files (not committed to repository)
|
- Configure via `.env` files (not committed to repository)
|
||||||
- Required variables documented in README or docs
|
- Required variables documented in README or docs
|
||||||
- Use environment-specific configurations
|
- Use environment-specific configurations
|
||||||
@@ -160,6 +179,7 @@ Examples:
|
|||||||
## Contributing Guidelines
|
## Contributing Guidelines
|
||||||
|
|
||||||
### Pull Request Process
|
### Pull Request Process
|
||||||
|
|
||||||
1. Fork the repository
|
1. Fork the repository
|
||||||
2. Create a branch from `next`: `git checkout -b feature/your-feature upstream/next`
|
2. Create a branch from `next`: `git checkout -b feature/your-feature upstream/next`
|
||||||
3. Make focused changes addressing a single issue/feature
|
3. Make focused changes addressing a single issue/feature
|
||||||
@@ -171,12 +191,14 @@ Examples:
|
|||||||
9. Create Pull Request targeting the `next` branch
|
9. Create Pull Request targeting the `next` branch
|
||||||
|
|
||||||
### Code Review
|
### Code Review
|
||||||
|
|
||||||
- Be responsive to feedback
|
- Be responsive to feedback
|
||||||
- Keep discussions constructive and professional
|
- Keep discussions constructive and professional
|
||||||
- Make requested changes promptly
|
- Make requested changes promptly
|
||||||
- Ask questions if requirements are unclear
|
- Ask questions if requirements are unclear
|
||||||
|
|
||||||
### What to Avoid
|
### What to Avoid
|
||||||
|
|
||||||
- Don't mix unrelated changes in a single PR
|
- Don't mix unrelated changes in a single PR
|
||||||
- Don't skip linting or type checking
|
- Don't skip linting or type checking
|
||||||
- Don't commit directly to `main` or `next` branches
|
- Don't commit directly to `main` or `next` branches
|
||||||
@@ -187,12 +209,14 @@ Examples:
|
|||||||
## Helpful Commands
|
## Helpful Commands
|
||||||
|
|
||||||
### Root Level
|
### Root Level
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
pnpm install # Install all dependencies
|
pnpm install # Install all dependencies
|
||||||
git config core.hooksPath .husky # Configure Git hooks
|
git config core.hooksPath .husky # Configure Git hooks
|
||||||
```
|
```
|
||||||
|
|
||||||
### Per App (web/server/docs)
|
### Per App (web/server/docs)
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
pnpm dev # Start development server
|
pnpm dev # Start development server
|
||||||
pnpm build # Build for production
|
pnpm build # Build for production
|
||||||
@@ -205,6 +229,7 @@ pnpm validate # Run lint + type-check
|
|||||||
```
|
```
|
||||||
|
|
||||||
### Docker
|
### Docker
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker-compose up # Start all services
|
docker-compose up # Start all services
|
||||||
docker-compose down # Stop all services
|
docker-compose down # Stop all services
|
||||||
@@ -215,7 +240,7 @@ docker-compose down # Stop all services
|
|||||||
- **Documentation**: [https://palmr.kyantech.com.br](https://palmr.kyantech.com.br)
|
- **Documentation**: [https://palmr.kyantech.com.br](https://palmr.kyantech.com.br)
|
||||||
- **Contributing Guide**: [CONTRIBUTING.md](../CONTRIBUTING.md)
|
- **Contributing Guide**: [CONTRIBUTING.md](../CONTRIBUTING.md)
|
||||||
- **Issue Tracker**: GitHub Issues
|
- **Issue Tracker**: GitHub Issues
|
||||||
- **License**: BSD-2-Clause
|
- **License**: Apache-2.0
|
||||||
|
|
||||||
## Getting Help
|
## Getting Help
|
||||||
|
|
||||||
|
@@ -13,7 +13,7 @@
|
|||||||
"react",
|
"react",
|
||||||
"typescript"
|
"typescript"
|
||||||
],
|
],
|
||||||
"license": "BSD-2-Clause",
|
"license": "Apache-2.0",
|
||||||
"packageManager": "pnpm@10.6.0",
|
"packageManager": "pnpm@10.6.0",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "next build",
|
"build": "next build",
|
||||||
|
@@ -12,7 +12,7 @@
|
|||||||
"nodejs",
|
"nodejs",
|
||||||
"typescript"
|
"typescript"
|
||||||
],
|
],
|
||||||
"license": "BSD-2-Clause",
|
"license": "Apache-2.0",
|
||||||
"packageManager": "pnpm@10.6.0",
|
"packageManager": "pnpm@10.6.0",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
@@ -79,4 +79,4 @@
|
|||||||
"tsx": "^4.19.2",
|
"tsx": "^4.19.2",
|
||||||
"typescript": "^5.7.3"
|
"typescript": "^5.7.3"
|
||||||
}
|
}
|
||||||
}
|
}
|
@@ -11,7 +11,7 @@
|
|||||||
"react",
|
"react",
|
||||||
"typescript"
|
"typescript"
|
||||||
],
|
],
|
||||||
"license": "BSD-2-Clause Copyright 2023 Kyantech",
|
"license": "Apache-2.0",
|
||||||
"packageManager": "pnpm@10.6.0",
|
"packageManager": "pnpm@10.6.0",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "next dev -p 3000",
|
"dev": "next dev -p 3000",
|
||||||
|
Reference in New Issue
Block a user