First off, thanks for taking the time to contribute! 🎉
- Visit https://github.com/loggipop/lpop
- Click the "Fork" button in the top right
- Clone your fork locally:
git clone https://github.com/YOUR-USERNAME/lpop.git cd lpop
# Install dependencies
bun install
# Run in development mode
bun dev
# Or build and test the binary
bun run build:binaries
./lpop --helpgit checkout -b feature/your-feature-name
# or
git checkout -b fix/your-bug-fixlpop/
├── src/
│ ├── index.ts # Entry point
│ ├── cli.ts # CLI command handling
│ ├── keychain-manager.ts # Keychain operations
│ ├── git-path-resolver.ts # Git repository detection
│ └── env-file-parser.ts # .env file parsing
├── scripts/
│ └── build-binary.sh # Binary build script
└── package.json
bun dev # Run in development mode
bun run build:binaries # Build binary executables for all platforms
bun run prepare-packages # Copy binaries to platform packages and sync versions
bun run clean # Clean build artifacts- We use TypeScript with ESNext features
- Follow existing code patterns
- Keep functions small and focused
- Add comments for complex logic
Before submitting:
-
Test the CLI commands:
# Test basic operations bun dev add TEST_VAR=value bun dev get TEST_VAR bun dev remove TEST_VAR -
Build and test the binary:
bun run build:binaries ./lpop --help
-
Test on different environments (if possible):
- Different git repositories
- Non-git directories
- Multiple environment names
- Features: New commands or options
- Bug fixes: Found something broken? Fix it!
- Documentation: Improve README, add examples
- Performance: Make lpop faster
- Cross-platform: Improve Windows/Linux support
- Security: Enhance secure storage methods
- Check if the issue already exists
- Create a new issue with:
- Clear title and description
- Steps to reproduce
- Expected vs actual behavior
- Your environment (OS, Node version)
lpop uses a Sentry-style binary distribution strategy with automated CI/CD that builds and signs binaries for all platforms when a GitHub release is created.
- Manual Release Creation: Create a GitHub release (e.g.,
v0.1.1) - CI Trigger: Workflow triggers on release creation
- Certificate Check: Verifies if signing certificates are available for each platform
- Platform Builds: Separate jobs for macOS, Windows, and Linux with conditional execution
- Code Signing:
- macOS: Developer ID Application signing + Apple notarization
- Windows: Authenticode signing with timestamping
- Linux: GPG detached signatures
- Binary Upload: Uploads signed binaries to the GitHub release
- Platform Package Publishing: Publishes platform-specific npm packages (
lpop-linux-x64, etc.) - Main Package Publishing: Publishes main package with correct optionalDependencies
- Platform-specific packages: Each platform gets its own npm package with just the signed binary
- Optional dependencies: Main package references platform packages as optional dependencies
- Binary replacement: Postinstall replaces Node.js wrapper with native binary for zero startup overhead
- Fallback download: Downloads from GitHub releases if optional dependencies fail
Key secrets include:
- macOS:
MACOS_CERTIFICATE,MACOS_CERTIFICATE_PASSWORD,APPLE_ID,APPLE_APP_PASSWORD,APPLE_TEAM_ID - Windows:
WINDOWS_CERTIFICATE,WINDOWS_CERTIFICATE_PASSWORD - Linux:
LINUX_CERTIFICATE(GPG private key) - NPM:
NPM_TOKEN
| Platform | With Certificates | Without Certificates |
|---|---|---|
| macOS | ✅ Signed + Notarized + npm package | ❌ Not distributed |
| Windows | ✅ Authenticode signed + npm package | ❌ Not distributed |
| Linux | ✅ GPG signed + npm package | ❌ Not distributed |
Note: Only signed binaries are distributed to ensure keychain access works reliably.
- Update version in
package.json(e.g.,0.1.0→0.1.1) - Create GitHub release manually with matching tag (e.g.,
v0.1.1) - CI runs automatically:
- Builds and signs binaries for platforms with certificates
- Uploads binaries to the release
- Publishes platform-specific npm packages
- Publishes main npm package
All platform packages automatically sync to the main package version during CI, ensuring consistency across the distribution.
git add .
git commit -m "feat: add amazing new feature"
# or
git commit -m "fix: resolve issue with env parsing"Commit Message Format:
feat:New featurefix:Bug fixdocs:Documentation changesstyle:Code style changesrefactor:Code refactoringtest:Test additions/changeschore:Build process or auxiliary tool changes
git push origin feature/your-feature-name- Go to your fork on GitHub
- Click "Pull Request"
- Provide a clear description:
- What does this PR do?
- Why is it needed?
- How did you test it?
- Keep PRs focused: One feature/fix per PR
- Update documentation: If you change functionality
- Be responsive: Reply to feedback promptly
- Be patient: Maintainers review PRs as time permits
Contributors will be:
- Listed in our Contributors section
- Thanked in release notes
- Given credit in commit messages
- Open an issue for questions
- Tag it with the
questionlabel - Be clear and specific
- Development uses Bun for speed
- Binary builds use Bun's compilation
- Make sure changes work with both
bun devand the built binary
- macOS: Test with Keychain Access app
- Windows: Check Credential Manager
- Linux: Varies by distribution
- Test in various git configurations
- Handle edge cases (no remotes, multiple remotes)
- Fallback gracefully for non-git directories
- Be respectful and inclusive
- Welcome newcomers
- Focus on constructive feedback
- Help make lpop better for everyone
Thank you for contributing to lpop! 🍭