# ============================================================
# BetterDesk Console — .gitignore
# Organized by category, no duplicate patterns
# ============================================================

# --- Python ---
__pycache__/
*.py[cod]
*$py.class
*.so
.Python
env/
venv/
.venv/
ENV/
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
# Python distutils 'lib/' build output (root-level only — must NOT match
# Tauri/SolidJS client src/lib directories like
# betterdesk-agent-client/src/lib or betterdesk-mgmt/src/lib).
/lib/
/lib64/
parts/
sdist/
var/
wheels/
*.egg-info/
.installed.cfg
*.egg
instance/
.webassets-cache

# --- Rust ---
target/
# Note: Cargo.lock is committed for application crates (reproducible builds + Dependabot)
**/*.rs.bk
*.pdb

# --- Node.js ---
node_modules/
package-lock.json

# --- IDEs & OS ---
.vscode/
.idea/
.playwright-mcp/
*.swp
*.swo
*~
.DS_Store
Thumbs.db
.Spotlight-V100
.Trashes

# --- Logs ---
*.log
logs/

# --- Database files ---
*.sqlite3
*.sqlite3-shm
*.sqlite3-wal
*.db
*.db-shm
*.db-wal

# --- Runtime state (must NEVER be committed; corrupts user installs on update) ---
web-nodejs/data/
!web-nodejs/data/.gitkeep
.session_secret
.update_sha
.api_key
.admin_credentials
.force_password_update

# --- Temporary files & caches ---
*.tmp
*.temp
/tmp/
.cache/

# --- Backups ---
*.bak
*.backup
*backup*/
rustdesk-backup*/
rustdesk-backup-*/

# --- Environment & secrets ---
.env
.env.local
.env.*.local
config.local.*
*_local.sh
*_local.ps1
*credentials*
!docker/show-admin-credentials.sh
*.password
*.passwords
*_password.txt
*_password.log
*secret*.key
*secret*.pem

# --- Cryptographic keys & certificates ---
*.key
*.pem
*.pub
id_*

# --- Sensitive internal documents (security audits, reports) ---
docs/_internal/
*REPORT*.md
.security_scan_report.md

# --- Testing ---
.coverage
htmlcov/
.pytest_cache/
test_*.sh
verify_*.sh
TESTING.local.md
web-nodejs/test-db.js

# --- Test screenshots (moved from root to screenshots/tests/) ---
screenshots/tests/
/test-*.png

#visual_studio
.vs/CopilotSnapshots
.vs/

# --- Temporary test scripts (contain credentials/URLs — moved to dev_modules/) ---
tmp_test_*.py
tmp_test_*.sh

# --- Archive (old files with potential sensitive data) ---
archive/

# --- Legacy binaries ---
hbbs-patch/
hbbs-patch-v2/
hbbs-v[0-7]-patched
hbbr-v[0-7]-patched

# --- Dev scripts (old Flask/Rust-era utilities) ---
dev_modules/
scripts/legacy/
migrations/
templates/
test_api.sh
build_windows.sh
_write_readme.py

# --- Dev scripts with potential sensitive data ---
web-nodejs/_test_*.sh
web-nodejs/_fix_*.sh

# --- BetterDesk desktop clients (TEMPORARY — alpha, not in active use) ---
# Whole trees excluded to avoid GitHub noise (Dependabot, i18n, stale CI). Remove
# these two lines when agent-client / mgmt return to active development.
betterdesk-mgmt/
betterdesk-agent-client/

# --- BetterDesk Agent binaries & config (compiled locally) ---
betterdesk-agent/betterdesk-agent
betterdesk-agent/betterdesk-agent-*
betterdesk-agent/*.exe
betterdesk-agent/deploy-config.json
betterdesk-agent/*.json
betterdesk-agent/create_key.py
betterdesk-agent/fix_devid.py
betterdesk-agent/fix_type.py
betterdesk-agent/update_config.py
!betterdesk-agent/package.json

# --- BetterDesk Go server binaries (compiled locally) ---
betterdesk-server/betterdesk-server
betterdesk-server/betterdesk-server-*
betterdesk-server/*.exe
betterdesk-server/*.key
betterdesk-server/*.pem
betterdesk-server/id_ed25519*
betterdesk-server/test_*.go
betterdesk-server/_test_*

# --- Root-level image duplicates (originals in web-nodejs/public/img/) ---
/betterdesk.png
/betterdesk_icon.png
/betterdesk_wallpaper.png

# --- Screenshots ---
screenshots/*.png
!screenshots/.gitkeep
web-nodejs/uploads/

# --- Deployment temporary files & artifacts ---
_deploy_tmp/
_server_checksums.txt
deploy_console.tar.gz
*.tar.gz

# --- Wallpapers (128MB+ — too large for git, ship separately) ---
web-nodejs/wallpapers/

# --- Internal dev/analysis documents (not for public repo) ---
.github/audyt_bezpieczenstwa.md
.github/RUSTDESK_SZYFROWANIE.md
.github/rustdesk_client_server_data_analysis.md
.github/rustdesk_encryption_analysis.md
.github/new_functions.md
.github/rustdesk_client.md
.github/copilot-instructions.md

# --- Playwright MCP screenshots ---
.playwright-mcp/

# --- Task tracking (local only) ---
tasks/todo.md
t
k-server

docs/security/PROJECT_SECURITY_ANALYSIS_2026-05-19.md
