Local Development Setup¶
This guide covers setting up nsyte for local development and testing your sites before deployment.
Prerequisites¶
- Deno 2.0 or later
- Git
- A bunker-compatible signer (Amber, Alby, etc.)
Development Installation¶
Option 1: Install from Source¶
Option 2: Install from JSR¶
Option 3: Development Build from Source¶
git clone https://github.com/sandwichfarm/nsyte.git
cd nsyte
deno install -A -f -g -n nsyte src/cli.ts
Testing Your Setup¶
Initialize a Test Project¶
During initialization:
- Connect your bunker signer when prompted
- Configure at least one relay for testing
- Optionally configure blossom servers
Create Test Content¶
Test Upload¶
Verify Deployment¶
Local Development Workflow¶
Building Your Site¶
Build your static site using your preferred tools:
# React/Next.js
npm run build
# Jekyll
bundle exec jekyll build
# Hugo
hugo
# Or any other static site generator
Testing Before Deploy¶
Test locally before uploading:
Deploy to Test Environment¶
Development Commands¶
Build Commands¶
# Build for current platform
deno task compile
# Build for all platforms
deno task compile:all
# Run tests
deno task test
Debug Mode¶
Use verbose output for debugging:
Configuration Tips¶
Multiple Environments¶
Create different configurations for different environments:
Ignore Files¶
Create .nsyteignore
to exclude development files:
Troubleshooting¶
Common Issues¶
Permission Errors
- Ensure Deno has necessary permissions
- Check file system permissions
- Verify bunker connection
Connection Issues
- Test relay connectivity manually
- Check network/firewall settings
- Verify relay URLs are correct
Authentication Problems
- Reconnect bunker signer
- Check bunker permissions
- Generate new CI token if needed