Registry / devops / grunt-jsforce-deploy

grunt-jsforce-deploy

JSON →
library1.1.1jsnpmunverified

A Grunt task for deploying Salesforce Metadata API packages using JSforce (no Force.com Migration Tool / Ant / Java required). The current stable version is 1.1.1. Release cadence is low; last update was in 2017. Key differentiators: pure Node.js implementation, no external Java dependencies, uses JSforce's Metadata API, supports polling timeout/interval configuration. Works with Grunt >=0.4.0 and requires Salesforce credentials (username + password).

npm install grunt-jsforce-deploy
INSTALL
IMPORT
SIG · GRUNT-JSFORCE-DEPL
G
grunt-jsforce-deploy
devopsjavascriptv1.1.1
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

module.exports
grunt.loadNpmTasks('grunt-jsforce-deploy'); grunt.initConfig({jsforce_deploy: ...})
require('grunt-jsforce-deploy')
Grunt tasks are loaded via grunt.loadNpmTasks, not require. Config is set in Gruntfile under jsforce_deploy key.
jsforce_deploy
grunt.initConfig({ jsforce_deploy: { options: { username: '...', password: '...' } } })
grunt.loadTasks('grunt-jsforce-deploy')
Task name is jsforce_deploy (underscore, not hyphen). Options are set under the task target.
default export (not applicable)
N/A
N/A
No JavaScript import needed; just install and configure in Gruntfile.

Shows how to load the Grunt task, configure Salesforce credentials via environment variables, and register a deploy task.

module.exports = function(grunt) { grunt.loadNpmTasks('grunt-jsforce-deploy'); grunt.initConfig({ jsforce_deploy: { options: { username: process.env.SF_USERNAME, password: process.env.SF_PASSWORD }, src: ['pkg/**'] } }); grunt.registerTask('deploy', ['jsforce_deploy']); };
Debug
Known issues
gotchaPassword must include security token appended (e.g., password + security token). The task does not automatically append token.
fix
Use 'password': process.env.SF_PASSWORD + process.env.SF_TOKEN or set SF_PASSWORD to 'password+token'.
affects: <=1.1.1
gotchaThe task uses 'pollTimeout' and 'pollInterval' in milliseconds, not seconds. Default pollTimeout is 60000 (60s), pollInterval is 5000 (5s).
fix
Set options.pollTimeout to 120000 for 120 seconds.
affects: <=1.1.1
gotchaLogin URL defaults to https://login.salesforce.com. For sandbox, set loginUrl: 'https://test.salesforce.com'.
fix
Add options.loginUrl: 'https://test.salesforce.com' in config.
affects: <=1.1.1
deprecatedThe package is unmaintained since 2017 and may not work with recent Salesforce API versions.
fix
Consider alternatives like sfdx or jsforce directly with custom scripts.
affects: >=1.0.0
Errors
Common errors & fixes
Warning: Task "jsforce_deploy" not found. Use --force to continue.
Task name referenced incorrectly (e.g., 'jsforce-deploy' with hyphen instead of underscore).
fix
In Gruntfile, use jsforce_deploy (underscore) in both initConfig and grunt.registerTask.
Error: Login failure error: INVALID_LOGIN: Invalid username, password, security token; or user locked out.
Password missing security token or incorrect credentials.
fix
Set password to 'actualPassword' + 'securityToken' (e.g., process.env.SF_PASSWORD = 'mypasswordmytoken').
Error: connect ETIMEDOUT
Network timeout or wrong loginUrl (e.g., using production URL for sandbox).
fix
Ensure loginUrl matches your org type (production: https://login.salesforce.com, sandbox: https://test.salesforce.com).
Upgrade
Version history
1.1.1latest on npm
Audit
Dependencies
gruntrequiredpeer dependency for task registration
Agent activity
6 hits · last 30 days
node
6
Resources
grunt-jsforce-deploy — npm install grunt-jsforce-deploy · libregistry