Releases: pablo-codes/local-git-deploy
Release list
v2.1.0 - Zero-Config SFTP & Native SSH Auth
What's New in v2.1.0 🔑
This release brings a new quality-of-life feature: Zero-Config SFTP Authentication.
local-git-deploy now seamlessly integrates with your system's native SSH configuration!
If you already have SSH keys set up to access your server, you no longer need to specify credentials in your .env or local-git-deploy.yml file.
✨ Highlights
~/.ssh/configSupport: The tool now parses your native SSH config file. You can simply provide aserveralias (e.g.,server: myserver), and it will automatically resolve the trueHostName,User,Port, andIdentityFiledirectly from your SSH config.- SSH Agent Support: Automatically detects keys loaded via
ssh-addusing the SSH Agent (SSH_AUTH_SOCKon Linux/macOS, or the OpenSSH Authentication Agent on Windows). - Default Key Auto-Detection: Automatically probes for default SSH keys (
~/.ssh/id_ed25519,~/.ssh/id_rsa,~/.ssh/id_ecdsa) if no other credentials are provided. - Optional User Field: When using SFTP, the
userfield in your config is now optional. It will gracefully fall back to the User specified in your~/.ssh/config, or default to your local OS username.
Note: This is purely additive and 100% backwards compatible. Any explicit credentials you have in your
.envor.ymlfiles will always take priority over the auto-detected settings.
v2.0.0 — multi-branch deployment and ssh remote script execution
What's New in v2.0.0 🚀
This is a major release that transforms local-git-deploy from a simple file sync tool into a lightweight, powerful deployment pipeline for FTP and SFTP servers.
🌟 Major Features
- Multi-Branch Deployment: You can now configure different servers and directories for different branches in a single
local-git-deploy.ymlfile! It supports exact branch names (likemainandstaging) and glob patterns (likefeature/*). - Per-Branch Credentials: Use the new
password_envconfig key to securely map different branches to different environment variables (e.g.,DEPLOY_PASSWORD_PROD,DEPLOY_PASSWORD_STAGING) loaded from your.envfile. - Remote SSH Hooks (SFTP Only): Automate your post-deploy tasks! You can now define
pre_deployandpost_deploycommands in your config to run database migrations, clear caches, or put your site in maintenance mode directly on the server over SSH. Supports both inline commands and script files.
✨ Enhancements
- Added a
--branchflag to manually override branch detection (perfect for CI/CD environments). - Added a
--forceflag to deploy unmapped branches using base default configurations. - State tracking is now completely branch-isolated. Deploying to
staginggenerates a.deploy-sync-state-stagingfile, meaning you'll never accidentally corrupt yourmainbranch's deployment state. - Enhanced error handling and input validation across the board.
📝 Documentation Updates
- The
README.mdhas been completely rewritten with extensive examples of the new multi-branch and SSH hook features, plus a new "Use Cases" section. - Updated the sample
local-git-deploy.sample.ymlto showcase advanced setups.
Note: Existing flat configurations will continue to work perfectly without any modifications. The new
branches:configuration block is entirely opt-in!
v1.2.1-minor changes
Full Changelog: v1.2.1...v1.2.1
v1.2.0 — OIDC Trusted Publishing & CI improvements
What's changed
CI/CD
- Switched npm publish to OIDC Trusted Publishing (no static token required)
- Fixed FTP pre-cleanup using
lftpwith SSL cert bypass for shared hosting - Fixed stale
.deploy-sync-statecausing "bad object" errors on CI - Added
workflow_dispatchfor manual publish re-runs
v1.1.1 — Security & Reliability Patch
What's changed
Security fixes
- FTPS: Certificate validation is now enabled by default. Self-signed cert support requires explicit
insecure: truein config (previously always disabled) - Config: Warns when password is read from the YAML file instead of .env
Bug fixes
- Deleted files now correctly respect
excludeglob patterns - Filenames with spaces or special characters no longer break uploads (null-terminated git output)
- Private key paths starting with
~are now correctly expanded - Remote sync state hash is validated before use — corrupted state files now give a clear, actionable error
- Temp files moved to
os.tmpdir()with PID suffix to prevent race conditions on parallel runs
Improvements
- Connection timeouts added for both FTP and SFTP
enginesfield added — requires Node.js >=16- Protocol validation: unsupported protocols now fail with a clear error