JSPM

@salesforce/source-tracking

0.0.2
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 320607
  • Score
    100M100P100Q178339F
  • License BSD-3-Clause

API for tracking local and remote Salesforce metadata changes

Package Exports

  • @salesforce/source-tracking

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@salesforce/source-tracking) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

source-tracking

JavaScript library for tracking local and remote Salesforce metadata changes.

_ UNDER DEVELOPMENT _

You should use the class named sourceTracking.

Use cases:

  1. push => deployLocalChanges()
  2. pull => retrieveRemoteChanges()
  3. push,pull,status: getConflicts()
  4. retrieve/retrieve: updateLocalTracking(),updateRemoteTracking

TODO

NUT for compatibility checks pollSourceMembers should better handle aggregated types. ex:

DEBUG Could not find 2 SourceMembers: AuraDefinition__pageTemplate_2_7_3/pageTemplate_2_7_3.cmp-meta.xml,[object Object],CustomObject__Account,[object Object]

push/pull throw on conflict, but don't provide errors for --json

  • SDR sets all retrieve FileResponse as Changed even if it didn't exist locally. That's going to yield slightly different json output on a pull than toolbelt did. See remoteChanges.nut.ts > remote changes:add > can pull the add. Fixing in pull is less optimal than fixing in SDR (because source:retrieve is also currently reporting those as Changed instead of Created) work around our gitignore stash trick...sometimes it gets in the incomplete state. What if there is no gitignore? All kinds of error handling issues around that

Enhancements

  • status can "mark ignores"
  • why does push take so long?
  • for updating ST after deploy/retrieve, we need a quick way for those commands to ask, "is this an ST org?" OR a graceful "ifSupported" wrapper for those methods.
  • ensureRemoteTracking could have 2 options in an object
    1. ensureQueryHasReturned which will make sure the query has run at least once
    2. forceQuery will re-query even if the query already ran (cache-buster typically)

Cleanup

  • review commented code
  • review public methods for whether they should be public
  • organize any shared types
  • export top-level stuff