Skip to content

Instantly share code, notes, and snippets.

@matschaffer
Created August 6, 2010 18:46
Show Gist options
  • Save matschaffer/511771 to your computer and use it in GitHub Desktop.
Save matschaffer/511771 to your computer and use it in GitHub Desktop.
require 'hoopla_salesforce/rake'
# You'll need to download your own WSDLs from the salesforce develop page
HooplaSalesforce.enterprise_wsdl = "lib/enterprise.xml"
HooplaSalesforce.metadata_wsdl = "lib/metadata.xml"
namespace :deploy do
HooplaSalesforce::Rake::DeployTask.new(:dev) do |t|
t.username = "dev username"
t.password = "dev password"
t.token = "dev token"
end
# Any instance of __NAMESPACE__ in your src will get replaced with
# your_namespace__ (or your_namespace in package.xml)
HooplaSalesforce::Rake::DeployTask.new(:production) do |t|
t.username = "prod username"
t.password = "prod password"
t.token = "prod token"
t.namespace = "your_namespace"
end
end
HooplaSalesforce::Rake::RetrieveTask.new do |t|
t.username = "prod username"
t.password = "prod password"
t.token = "prod token"
# This will retrieve a complete package
t.request = { "wsdl:apiVersion" => 18.0, "wsdl:packageNames" => ["Your package name"] }
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment