sfdx-easy-sources 0.7.6 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (291) hide show
  1. package/README.md +76 -36
  2. package/lib/api/applications.d.ts +73 -0
  3. package/lib/api/applications.js +78 -0
  4. package/lib/api/applications.js.map +1 -0
  5. package/lib/api/globalvaluesets.d.ts +73 -0
  6. package/lib/api/globalvaluesets.js +78 -0
  7. package/lib/api/globalvaluesets.js.map +1 -0
  8. package/lib/api/globalvaluesettranslations.d.ts +73 -0
  9. package/lib/api/globalvaluesettranslations.js +78 -0
  10. package/lib/api/globalvaluesettranslations.js.map +1 -0
  11. package/lib/api/labels.d.ts +71 -0
  12. package/lib/api/labels.js +79 -0
  13. package/lib/api/labels.js.map +1 -0
  14. package/lib/api/objecttranslations.d.ts +81 -0
  15. package/lib/api/objecttranslations.js +89 -0
  16. package/lib/api/objecttranslations.js.map +1 -0
  17. package/lib/api/paths.d.ts +56 -0
  18. package/lib/api/paths.js +61 -0
  19. package/lib/api/paths.js.map +1 -0
  20. package/lib/api/permissionsets.d.ts +118 -0
  21. package/lib/api/permissionsets.js +119 -0
  22. package/lib/api/permissionsets.js.map +1 -0
  23. package/lib/api/profiles.d.ts +120 -0
  24. package/lib/api/profiles.js +119 -0
  25. package/lib/api/profiles.js.map +1 -0
  26. package/lib/api/recordtypes.d.ts +102 -0
  27. package/lib/api/recordtypes.js +99 -0
  28. package/lib/api/recordtypes.js.map +1 -0
  29. package/lib/api/translations.d.ts +80 -0
  30. package/lib/api/translations.js +89 -0
  31. package/lib/api/translations.js.map +1 -0
  32. package/lib/commands/easysources/applications/arealigned.d.ts +1 -0
  33. package/lib/commands/easysources/applications/arealigned.js +7 -7
  34. package/lib/commands/easysources/applications/arealigned.js.map +1 -1
  35. package/lib/commands/easysources/applications/merge.d.ts +1 -0
  36. package/lib/commands/easysources/applications/merge.js +7 -1
  37. package/lib/commands/easysources/applications/merge.js.map +1 -1
  38. package/lib/commands/easysources/applications/split.d.ts +1 -0
  39. package/lib/commands/easysources/applications/split.js +7 -1
  40. package/lib/commands/easysources/applications/split.js.map +1 -1
  41. package/lib/commands/easysources/applications/updatekey.d.ts +1 -0
  42. package/lib/commands/easysources/applications/updatekey.js +6 -0
  43. package/lib/commands/easysources/applications/updatekey.js.map +1 -1
  44. package/lib/commands/easysources/applications/upsert.d.ts +1 -0
  45. package/lib/commands/easysources/applications/upsert.js +7 -1
  46. package/lib/commands/easysources/applications/upsert.js.map +1 -1
  47. package/lib/commands/easysources/globalvaluesets/arealigned.d.ts +1 -0
  48. package/lib/commands/easysources/globalvaluesets/arealigned.js +7 -7
  49. package/lib/commands/easysources/globalvaluesets/arealigned.js.map +1 -1
  50. package/lib/commands/easysources/globalvaluesets/merge.d.ts +1 -0
  51. package/lib/commands/easysources/globalvaluesets/merge.js +7 -1
  52. package/lib/commands/easysources/globalvaluesets/merge.js.map +1 -1
  53. package/lib/commands/easysources/globalvaluesets/split.d.ts +1 -0
  54. package/lib/commands/easysources/globalvaluesets/split.js +6 -0
  55. package/lib/commands/easysources/globalvaluesets/split.js.map +1 -1
  56. package/lib/commands/easysources/globalvaluesets/updatekey.d.ts +1 -0
  57. package/lib/commands/easysources/globalvaluesets/updatekey.js +6 -0
  58. package/lib/commands/easysources/globalvaluesets/updatekey.js.map +1 -1
  59. package/lib/commands/easysources/globalvaluesets/upsert.d.ts +1 -0
  60. package/lib/commands/easysources/globalvaluesets/upsert.js +6 -0
  61. package/lib/commands/easysources/globalvaluesets/upsert.js.map +1 -1
  62. package/lib/commands/easysources/globalvaluesettranslations/arealigned.d.ts +1 -0
  63. package/lib/commands/easysources/globalvaluesettranslations/arealigned.js +7 -7
  64. package/lib/commands/easysources/globalvaluesettranslations/arealigned.js.map +1 -1
  65. package/lib/commands/easysources/globalvaluesettranslations/merge.d.ts +1 -0
  66. package/lib/commands/easysources/globalvaluesettranslations/merge.js +6 -0
  67. package/lib/commands/easysources/globalvaluesettranslations/merge.js.map +1 -1
  68. package/lib/commands/easysources/globalvaluesettranslations/split.d.ts +1 -0
  69. package/lib/commands/easysources/globalvaluesettranslations/split.js +6 -0
  70. package/lib/commands/easysources/globalvaluesettranslations/split.js.map +1 -1
  71. package/lib/commands/easysources/globalvaluesettranslations/updatekey.d.ts +1 -0
  72. package/lib/commands/easysources/globalvaluesettranslations/updatekey.js +6 -0
  73. package/lib/commands/easysources/globalvaluesettranslations/updatekey.js.map +1 -1
  74. package/lib/commands/easysources/globalvaluesettranslations/upsert.d.ts +1 -0
  75. package/lib/commands/easysources/globalvaluesettranslations/upsert.js +7 -1
  76. package/lib/commands/easysources/globalvaluesettranslations/upsert.js.map +1 -1
  77. package/lib/commands/easysources/labels/arealigned.d.ts +8 -1
  78. package/lib/commands/easysources/labels/arealigned.js +13 -11
  79. package/lib/commands/easysources/labels/arealigned.js.map +1 -1
  80. package/lib/commands/easysources/labels/merge.d.ts +8 -0
  81. package/lib/commands/easysources/labels/merge.js +13 -1
  82. package/lib/commands/easysources/labels/merge.js.map +1 -1
  83. package/lib/commands/easysources/labels/split.d.ts +8 -0
  84. package/lib/commands/easysources/labels/split.js +13 -1
  85. package/lib/commands/easysources/labels/split.js.map +1 -1
  86. package/lib/commands/easysources/labels/updatekey.d.ts +8 -0
  87. package/lib/commands/easysources/labels/updatekey.js +13 -1
  88. package/lib/commands/easysources/labels/updatekey.js.map +1 -1
  89. package/lib/commands/easysources/labels/upsert.d.ts +8 -0
  90. package/lib/commands/easysources/labels/upsert.js +13 -1
  91. package/lib/commands/easysources/labels/upsert.js.map +1 -1
  92. package/lib/commands/easysources/objecttranslations/arealigned.d.ts +16 -6
  93. package/lib/commands/easysources/objecttranslations/arealigned.js +328 -331
  94. package/lib/commands/easysources/objecttranslations/arealigned.js.map +1 -1
  95. package/lib/commands/easysources/objecttranslations/clearempty.d.ts +5 -0
  96. package/lib/commands/easysources/objecttranslations/clearempty.js +74 -65
  97. package/lib/commands/easysources/objecttranslations/clearempty.js.map +1 -1
  98. package/lib/commands/easysources/objecttranslations/merge.d.ts +3 -0
  99. package/lib/commands/easysources/objecttranslations/merge.js +47 -42
  100. package/lib/commands/easysources/objecttranslations/merge.js.map +1 -1
  101. package/lib/commands/easysources/objecttranslations/minify.d.ts +3 -0
  102. package/lib/commands/easysources/objecttranslations/minify.js +59 -53
  103. package/lib/commands/easysources/objecttranslations/minify.js.map +1 -1
  104. package/lib/commands/easysources/objecttranslations/split.d.ts +1 -0
  105. package/lib/commands/easysources/objecttranslations/split.js +87 -81
  106. package/lib/commands/easysources/objecttranslations/split.js.map +1 -1
  107. package/lib/commands/easysources/objecttranslations/upsert.d.ts +3 -0
  108. package/lib/commands/easysources/objecttranslations/upsert.js +111 -105
  109. package/lib/commands/easysources/objecttranslations/upsert.js.map +1 -1
  110. package/lib/commands/easysources/permissionsets/arealigned.d.ts +8 -0
  111. package/lib/commands/easysources/permissionsets/arealigned.js +13 -7
  112. package/lib/commands/easysources/permissionsets/arealigned.js.map +1 -1
  113. package/lib/commands/easysources/permissionsets/clean.d.ts +9 -0
  114. package/lib/commands/easysources/permissionsets/clean.js +149 -132
  115. package/lib/commands/easysources/permissionsets/clean.js.map +1 -1
  116. package/lib/commands/easysources/permissionsets/clearempty.d.ts +8 -0
  117. package/lib/commands/easysources/permissionsets/clearempty.js +13 -1
  118. package/lib/commands/easysources/permissionsets/clearempty.js.map +1 -1
  119. package/lib/commands/easysources/permissionsets/delete.d.ts +8 -0
  120. package/lib/commands/easysources/permissionsets/delete.js +64 -52
  121. package/lib/commands/easysources/permissionsets/delete.js.map +1 -1
  122. package/lib/commands/easysources/permissionsets/merge.d.ts +8 -0
  123. package/lib/commands/easysources/permissionsets/merge.js +13 -1
  124. package/lib/commands/easysources/permissionsets/merge.js.map +1 -1
  125. package/lib/commands/easysources/permissionsets/minify.d.ts +8 -0
  126. package/lib/commands/easysources/permissionsets/minify.js +65 -53
  127. package/lib/commands/easysources/permissionsets/minify.js.map +1 -1
  128. package/lib/commands/easysources/permissionsets/split.d.ts +8 -0
  129. package/lib/commands/easysources/permissionsets/split.js +13 -1
  130. package/lib/commands/easysources/permissionsets/split.js.map +1 -1
  131. package/lib/commands/easysources/permissionsets/updatekey.d.ts +8 -0
  132. package/lib/commands/easysources/permissionsets/updatekey.js +13 -1
  133. package/lib/commands/easysources/permissionsets/updatekey.js.map +1 -1
  134. package/lib/commands/easysources/permissionsets/upsert.d.ts +8 -0
  135. package/lib/commands/easysources/permissionsets/upsert.js +13 -1
  136. package/lib/commands/easysources/permissionsets/upsert.js.map +1 -1
  137. package/lib/commands/easysources/profiles/arealigned.d.ts +1 -0
  138. package/lib/commands/easysources/profiles/arealigned.js +7 -7
  139. package/lib/commands/easysources/profiles/arealigned.js.map +1 -1
  140. package/lib/commands/easysources/profiles/clean.d.ts +2 -0
  141. package/lib/commands/easysources/profiles/clean.js +142 -129
  142. package/lib/commands/easysources/profiles/clean.js.map +1 -1
  143. package/lib/commands/easysources/profiles/clearempty.d.ts +1 -0
  144. package/lib/commands/easysources/profiles/clearempty.js +7 -1
  145. package/lib/commands/easysources/profiles/clearempty.js.map +1 -1
  146. package/lib/commands/easysources/profiles/delete.d.ts +1 -0
  147. package/lib/commands/easysources/profiles/delete.js +57 -52
  148. package/lib/commands/easysources/profiles/delete.js.map +1 -1
  149. package/lib/commands/easysources/profiles/merge.d.ts +1 -0
  150. package/lib/commands/easysources/profiles/merge.js +7 -1
  151. package/lib/commands/easysources/profiles/merge.js.map +1 -1
  152. package/lib/commands/easysources/profiles/minify.d.ts +1 -0
  153. package/lib/commands/easysources/profiles/minify.js +59 -53
  154. package/lib/commands/easysources/profiles/minify.js.map +1 -1
  155. package/lib/commands/easysources/profiles/split.d.ts +8 -0
  156. package/lib/commands/easysources/profiles/split.js +13 -1
  157. package/lib/commands/easysources/profiles/split.js.map +1 -1
  158. package/lib/commands/easysources/profiles/updatekey.d.ts +1 -0
  159. package/lib/commands/easysources/profiles/updatekey.js +7 -1
  160. package/lib/commands/easysources/profiles/updatekey.js.map +1 -1
  161. package/lib/commands/easysources/profiles/upsert.d.ts +1 -0
  162. package/lib/commands/easysources/profiles/upsert.js +7 -1
  163. package/lib/commands/easysources/profiles/upsert.js.map +1 -1
  164. package/lib/commands/easysources/recordtypes/arealigned.d.ts +1 -4
  165. package/lib/commands/easysources/recordtypes/arealigned.js +214 -311
  166. package/lib/commands/easysources/recordtypes/arealigned.js.map +1 -1
  167. package/lib/commands/easysources/recordtypes/clean.d.ts +1 -0
  168. package/lib/commands/easysources/recordtypes/clean.js +122 -137
  169. package/lib/commands/easysources/recordtypes/clean.js.map +1 -1
  170. package/lib/commands/easysources/recordtypes/delete.d.ts +1 -0
  171. package/lib/commands/easysources/recordtypes/delete.js +76 -71
  172. package/lib/commands/easysources/recordtypes/delete.js.map +1 -1
  173. package/lib/commands/easysources/recordtypes/merge.d.ts +1 -0
  174. package/lib/commands/easysources/recordtypes/merge.js +48 -45
  175. package/lib/commands/easysources/recordtypes/merge.js.map +1 -1
  176. package/lib/commands/easysources/recordtypes/split.d.ts +1 -0
  177. package/lib/commands/easysources/recordtypes/split.js +82 -77
  178. package/lib/commands/easysources/recordtypes/split.js.map +1 -1
  179. package/lib/commands/easysources/recordtypes/updatekey.d.ts +1 -0
  180. package/lib/commands/easysources/recordtypes/updatekey.js +62 -57
  181. package/lib/commands/easysources/recordtypes/updatekey.js.map +1 -1
  182. package/lib/commands/easysources/recordtypes/upsert.d.ts +1 -0
  183. package/lib/commands/easysources/recordtypes/upsert.js +109 -104
  184. package/lib/commands/easysources/recordtypes/upsert.js.map +1 -1
  185. package/lib/commands/easysources/settings/init.js +1 -2
  186. package/lib/commands/easysources/settings/init.js.map +1 -1
  187. package/lib/commands/easysources/translations/arealigned.d.ts +1 -0
  188. package/lib/commands/easysources/translations/arealigned.js +7 -7
  189. package/lib/commands/easysources/translations/arealigned.js.map +1 -1
  190. package/lib/commands/easysources/translations/clearempty.d.ts +1 -0
  191. package/lib/commands/easysources/translations/clearempty.js +11 -0
  192. package/lib/commands/easysources/translations/clearempty.js.map +1 -1
  193. package/lib/commands/easysources/translations/merge.d.ts +1 -0
  194. package/lib/commands/easysources/translations/merge.js +6 -0
  195. package/lib/commands/easysources/translations/merge.js.map +1 -1
  196. package/lib/commands/easysources/translations/minify.d.ts +1 -0
  197. package/lib/commands/easysources/translations/minify.js +60 -53
  198. package/lib/commands/easysources/translations/minify.js.map +1 -1
  199. package/lib/commands/easysources/translations/split.d.ts +1 -0
  200. package/lib/commands/easysources/translations/split.js +7 -66
  201. package/lib/commands/easysources/translations/split.js.map +1 -1
  202. package/lib/commands/easysources/translations/upsert.d.ts +1 -0
  203. package/lib/commands/easysources/translations/upsert.js +6 -0
  204. package/lib/commands/easysources/translations/upsert.js.map +1 -1
  205. package/lib/index.d.ts +27 -1
  206. package/lib/index.js +48 -1
  207. package/lib/index.js.map +1 -1
  208. package/lib/utils/commands/alignmentChecker.d.ts +2 -5
  209. package/lib/utils/commands/alignmentChecker.js +57 -98
  210. package/lib/utils/commands/alignmentChecker.js.map +1 -1
  211. package/lib/utils/commands/keyupdater.js +1 -2
  212. package/lib/utils/commands/keyupdater.js.map +1 -1
  213. package/lib/utils/commands/splitter.js +1 -2
  214. package/lib/utils/commands/splitter.js.map +1 -1
  215. package/lib/utils/commands/upserter.js +1 -2
  216. package/lib/utils/commands/upserter.js.map +1 -1
  217. package/lib/utils/commands/utils.js +64 -46
  218. package/lib/utils/commands/utils.js.map +1 -1
  219. package/lib/utils/constants/constants.d.ts +1 -1
  220. package/lib/utils/constants/constants.js +2 -2
  221. package/lib/utils/constants/constants.js.map +1 -1
  222. package/lib/utils/constants/constants_permissionsets.d.ts +42 -0
  223. package/lib/utils/constants/constants_permissionsets.js +15 -1
  224. package/lib/utils/constants/constants_permissionsets.js.map +1 -1
  225. package/lib/utils/constants/constants_sourcesdownload.d.ts +3 -2
  226. package/lib/utils/constants/constants_sourcesdownload.js +4 -3
  227. package/lib/utils/constants/constants_sourcesdownload.js.map +1 -1
  228. package/messages/all_merge.json +2 -2
  229. package/messages/all_minify.json +3 -3
  230. package/messages/all_split.json +3 -3
  231. package/messages/all_upsert.json +2 -2
  232. package/messages/allmeta_retrieve.json +6 -6
  233. package/messages/applications_arealigned.json +5 -5
  234. package/messages/applications_merge.json +4 -4
  235. package/messages/applications_split.json +4 -4
  236. package/messages/applications_updatekey.json +2 -2
  237. package/messages/applications_upsert.json +3 -3
  238. package/messages/globalvaluesets_arealigned.json +5 -5
  239. package/messages/globalvaluesets_merge.json +3 -3
  240. package/messages/globalvaluesets_split.json +3 -3
  241. package/messages/globalvaluesets_updatekey.json +2 -2
  242. package/messages/globalvaluesets_upsert.json +2 -2
  243. package/messages/globalvaluesettranslations_arealigned.json +5 -5
  244. package/messages/globalvaluesettranslations_merge.json +2 -2
  245. package/messages/globalvaluesettranslations_split.json +4 -4
  246. package/messages/globalvaluesettranslations_updatekey.json +2 -2
  247. package/messages/globalvaluesettranslations_upsert.json +2 -2
  248. package/messages/labels_arealigned.json +5 -5
  249. package/messages/labels_merge.json +2 -2
  250. package/messages/labels_split.json +3 -3
  251. package/messages/labels_updatekey.json +2 -2
  252. package/messages/labels_upsert.json +2 -2
  253. package/messages/objtransl_arealigned.json +6 -6
  254. package/messages/objtransl_clearempty.json +3 -3
  255. package/messages/objtransl_merge.json +3 -3
  256. package/messages/objtransl_minify.json +2 -2
  257. package/messages/objtransl_split.json +4 -4
  258. package/messages/objtransl_upsert.json +4 -4
  259. package/messages/permissionsets_arealigned.json +6 -6
  260. package/messages/permissionsets_clean.json +22 -0
  261. package/messages/permissionsets_clearempty.json +3 -3
  262. package/messages/permissionsets_delete.json +11 -11
  263. package/messages/permissionsets_merge.json +2 -2
  264. package/messages/permissionsets_split.json +5 -5
  265. package/messages/permissionsets_updatekey.json +2 -2
  266. package/messages/permissionsets_upsert.json +2 -2
  267. package/messages/profiles_arealigned.json +6 -6
  268. package/messages/profiles_clean.json +6 -5
  269. package/messages/profiles_clearempty.json +3 -3
  270. package/messages/profiles_delete.json +11 -11
  271. package/messages/profiles_merge.json +3 -3
  272. package/messages/profiles_minify.json +2 -2
  273. package/messages/profiles_split.json +4 -4
  274. package/messages/profiles_updatekey.json +2 -2
  275. package/messages/profiles_upsert.json +4 -4
  276. package/messages/recordtypes_arealigned.json +7 -7
  277. package/messages/recordtypes_clean.json +5 -5
  278. package/messages/recordtypes_delete.json +3 -3
  279. package/messages/recordtypes_merge.json +4 -4
  280. package/messages/recordtypes_split.json +5 -5
  281. package/messages/recordtypes_updatekey.json +3 -3
  282. package/messages/recordtypes_upsert.json +4 -4
  283. package/messages/settings_init.json +1 -1
  284. package/messages/translations_arealigned.json +6 -6
  285. package/messages/translations_clearempty.json +3 -3
  286. package/messages/translations_merge.json +3 -3
  287. package/messages/translations_minify.json +2 -2
  288. package/messages/translations_split.json +4 -4
  289. package/messages/translations_upsert.json +4 -4
  290. package/oclif.manifest.json +1 -1
  291. package/package.json +4 -2
package/README.md CHANGED
@@ -25,35 +25,75 @@ With this plugin you can:
25
25
 
26
26
  ## Supported metadata types
27
27
 
28
- | Metadata Label| Metadata api | Available commands |
29
- | :---: | :---: | :---: |
30
- | All Meta | allmeta | split, upsert, merge, minify, retrieve |
31
- | Profiles | profiles | split, upsert, merge, minify, updatekey, delete, clean, clearempty, arealigned |
32
- | Permission Sets | permissionsets | split, upsert, merge, minify, updatekey, delete, clean, clearempty, arealigned |
33
- | Record Types | recordtypes | split, upsert, merge, updatekey, delete, clean, arealigned |
34
- | Labels | labels | split, upsert, merge, updatekey, arealigned |
35
- | Global Value Sets | globalvaluesets | split, upsert, merge, updatekey, arealigned |
36
- | Global Value Set Translations | globalvaluesettranslations | split, upsert, merge, updatekey, arealigned |
37
- | Applications | applications | split, upsert, merge, updatekey, arealigned |
38
- | Object Translations | objecttranslations | split, upsert, merge, minify, updatekey, clearempty, arealigned |
39
- | Translations | translations | split, upsert, merge, minify, updatekey, clearempty, arealigned |
28
+ | Metadata Label| Metadata api | Available commands | Programmatic API |
29
+ | :---: | :---: | :---: | :---: |
30
+ | All Meta | allmeta | split, upsert, merge, minify, retrieve | ❌ |
31
+ | Profiles | profiles | split, upsert, merge, minify, updatekey, delete, clean, clearempty, arealigned | ✅ **Complete** |
32
+ | Permission Sets | permissionsets | split, upsert, merge, minify, updatekey, delete, clean, clearempty, arealigned | ✅ **Complete** |
33
+ | Record Types | recordtypes | split, upsert, merge, updatekey, delete, clean, arealigned | ✅ **Complete** |
34
+ | Labels | labels | split, upsert, merge, updatekey, arealigned | ✅ **Complete** |
35
+ | Global Value Sets | globalvaluesets | split, upsert, merge, updatekey, arealigned | ✅ **Complete** |
36
+ | Global Value Set Translations | globalvaluesettranslations | split, upsert, merge, updatekey, arealigned | ✅ **Complete** |
37
+ | Applications | applications | split, upsert, merge, updatekey, arealigned | ✅ **Complete** |
38
+ | Object Translations | objecttranslations | split, upsert, merge, minify, updatekey, clearempty, arealigned | ✅ **Complete** |
39
+ | Translations | translations | split, upsert, merge, minify, updatekey, clearempty, arealigned | ✅ **Complete** |
40
40
 
41
41
 
42
42
 
43
43
  ```sh-session
44
44
  $ npm install -g sfdx-easy-sources
45
45
  or
46
- $ sfdx plugin:install sfdx-easy-sources
46
+ $ sf plugins install sfdx-easy-sources
47
47
 
48
48
  GENERAL USAGE
49
- $ sfdx easysources:<metadataapi>:<command> [...parameters]
50
- $ sfdx easysources:<metadataapi>:<command> --help // to get help, the list of parameters and some examples
49
+ $ sf easysources <metadataapi> <command> [...parameters]
50
+ $ sf easysources <metadataapi> <command> --help // to get help, the list of parameters and some examples
51
51
  Examples
52
- $ sfdx easysources:profiles:split
53
- $ sfdx easysources:labels:upsert
52
+ $ sf easysources profiles split
53
+ $ sf easysources labels upsert
54
54
  ...
55
55
  ```
56
56
 
57
+ ## 🚀 Programmatic API Usage
58
+
59
+ **NEW in v0.8.0**: Complete programmatic API with automatic path resolution! Use all metadata operations in your Node.js scripts with **57 total API operations** across 9 metadata types.
60
+
61
+ ```javascript
62
+ // JavaScript - Basic usage with automatic path resolution
63
+ const { profiles, permissionsets, labels, objectTranslations } = require('sfdx-easy-sources');
64
+
65
+ async function automateMetadata() {
66
+ // Paths auto-resolved from easysources-settings.json
67
+ await profiles.split({ input: 'Admin,Standard User' });
68
+ await profiles.upsert({ input: 'Admin' });
69
+ await profiles.merge({ input: 'Admin' });
70
+
71
+ // Same pattern for all metadata types
72
+ await permissionsets.split();
73
+ await labels.upsert();
74
+ await objectTranslations.minify();
75
+ }
76
+ ```
77
+
78
+ ```typescript
79
+ // TypeScript - Full type safety
80
+ import { profiles, ProfileOptions } from 'sfdx-easy-sources';
81
+
82
+ const options: ProfileOptions = {
83
+ input: 'Admin,Standard User',
84
+ ignoreuserperm: 'true'
85
+ };
86
+ await profiles.split(options);
87
+ ```
88
+
89
+ **📚 Complete Documentation & Examples:** [API.md](./API.md)
90
+
91
+ ### Key Features
92
+ - **🔧 Automatic Path Resolution**: Uses `easysources-settings.json` for defaults
93
+ - **⚙️ Full TypeScript Support**: Complete type definitions for all metadata types
94
+ - **🔄 Consistent API**: Identical patterns across all 9 supported metadata types
95
+ - **🎯 Zero Code Duplication**: CLI commands delegate to API functions
96
+
57
97
 
58
98
  Based on the source type, this plugin provides the following commands:
59
99
  - **Split**: Splits the resources into various CSV files, and creates an XML file containing all the tags that weren't split
@@ -75,10 +115,10 @@ Based on the source type, this plugin provides the following commands:
75
115
  # Let's start!
76
116
  ## Prerequisites
77
117
  ### Prerequisite 1 - Initialize the settings
78
- This should be done once you have your sfdx project (for example after "Creating a new project with manifest").
118
+ This should be done once you have your sf project (for example after "Creating a new project with manifest").
79
119
  To better instruct the plugin with the directories of the project, you can run the command
80
120
  ```sh-session
81
- $ sfdx easysources:settings:init
121
+ $ sf easysources settings init
82
122
  ```
83
123
  and a file _easysources-settings.json_ will appear.
84
124
  This file contains the directory of:
@@ -87,7 +127,7 @@ This file contains the directory of:
87
127
  - the log files.
88
128
 
89
129
  Since I prefer to have the csv files near the xml ones, I left the default directories in my project. Consider that, in this case, you should need to:
90
- - have a .forceignore file to ignore .csv and .part-xml files when running sfdx commands
130
+ - have a .forceignore file to ignore .csv and .part-xml files when running sf commands
91
131
  - have a .pipelineignore file to ignore .csv and .part-xml files when running other plugins, for example when using sfdx-git-delta.
92
132
 
93
133
  Simply put these lines inside those files
@@ -102,7 +142,7 @@ To deal with Salesforce files all the source code from the org must be downloade
102
142
  One can perform this task in various ways, but this plugin also offers a simply way to download everything from the org.
103
143
 
104
144
  ```sh-session
105
- $ sfdx easysources:allmeta:retrieve --orgname="orgname"
145
+ $ sf easysources allmeta retrieve --orgname="orgname"
106
146
  ```
107
147
 
108
148
 
@@ -118,9 +158,9 @@ Once all the metadata have been downloaded, before to start dealing with the csv
118
158
  To do this run these commands (but first, please, understand the meaning of each command reading this guide)
119
159
 
120
160
  ```sh-session
121
- $ sfdx easysources:allmeta:split
122
- $ sfdx easysources:allmeta:minify
123
- $ sfdx easysources:allmeta:merge
161
+ $ sf easysources allmeta split
162
+ $ sf easysources allmeta minify
163
+ $ sf easysources allmeta merge
124
164
  ```
125
165
 
126
166
  ## Description of each command
@@ -134,7 +174,7 @@ This is an example of an xml profile splitted in csv.
134
174
  Once we run the command
135
175
 
136
176
  ```sh-session
137
- $ sfdx easysources:profiles:split
177
+ $ sf easysources profiles split
138
178
  ```
139
179
  the plugin generates a folder with all the csv files.
140
180
  ![profile_split](.images/profile_split.png)
@@ -176,10 +216,10 @@ This command is very useful if you don't want to have in your csv files all the
176
216
  For example, in the following image, the lines in red don't specify any permission so they could be removed.
177
217
 
178
218
  ```sh-session
179
- $ sfdx easysources:profiles:minify
180
- $ sfdx easysources:permissionsets:minify
181
- $ sfdx easysources:objecttranslations:minify
182
- $ sfdx easysources:translations:minify
219
+ $ sf easysources profiles minify
220
+ $ sf easysources permissionsets minify
221
+ $ sf easysources objecttranslations minify
222
+ $ sf easysources translations minify
183
223
  ```
184
224
 
185
225
  ![profile_minify](.images/profile_minify.png)
@@ -193,10 +233,10 @@ This command removes empty CSV files and folders from the generated CSV files, h
193
233
  After splitting metadata into CSV files, you might end up with empty CSV files or empty folders that don't contain any meaningful data. This command identifies and removes these empty files and directories automatically.
194
234
 
195
235
  ```sh-session
196
- $ sfdx easysources:profiles:clearempty
197
- $ sfdx easysources:permissionsets:clearempty
198
- $ sfdx easysources:objecttranslations:clearempty
199
- $ sfdx easysources:translations:clearempty
236
+ $ sf easysources profiles clearempty
237
+ $ sf easysources permissionsets clearempty
238
+ $ sf easysources objecttranslations clearempty
239
+ $ sf easysources translations clearempty
200
240
  ```
201
241
 
202
242
  This is particularly useful for object translations where you might have many empty field translation files, or for translations where some language files might be empty.
@@ -209,15 +249,15 @@ The command supports two validation modes:
209
249
 
210
250
  **String Mode** (`--mode string` - default):
211
251
  ```sh-session
212
- $ sfdx easysources:profiles:arealigned --mode string
252
+ $ sf easysources profiles arealigned --mode string
213
253
  # or simply (uses string mode by default):
214
- $ sfdx easysources:profiles:arealigned
254
+ $ sf easysources profiles arealigned
215
255
  ```
216
256
  Performs an exact string comparison by temporarily merging CSV files back into XML format and comparing the complete file content character by character. This mode detects even minor formatting differences and is the default mode.
217
257
 
218
258
  **Logic Mode** (`--mode logic`):
219
259
  ```sh-session
220
- $ sfdx easysources:profiles:arealigned --mode logic
260
+ $ sf easysources profiles arealigned --mode logic
221
261
  ```
222
262
  Performs a logical comparison by parsing both XML and CSV data structures and comparing the actual values. This mode is faster and focuses on data content rather than formatting differences.
223
263
 
@@ -0,0 +1,73 @@
1
+ import { AnyJson } from '@salesforce/ts-types';
2
+ import { PathOptions } from './paths';
3
+ /**
4
+ * Interface for Application operation options.
5
+ * All properties are optional and will be resolved automatically from easysources-settings.json if not provided.
6
+ */
7
+ export interface ApplicationOptions extends PathOptions {
8
+ /** Input applications (comma-separated) */
9
+ input?: string;
10
+ /** Sort output (default: 'true') */
11
+ sort?: 'true' | 'false';
12
+ /** Mode for areAligned operation (default: 'string') */
13
+ mode?: 'string' | 'logic';
14
+ }
15
+ /**
16
+ * Application namespace containing all programmatic API functions for Salesforce Application metadata operations.
17
+ *
18
+ * All methods automatically resolve paths from easysources-settings.json configuration file.
19
+ * You only need to provide options to override the default behavior.
20
+ *
21
+ * Available operations:
22
+ * - split(): Splits applications into separate files
23
+ * - upsert(): Updates or inserts application records
24
+ * - merge(): Merges application files
25
+ * - areAligned(): Checks if applications are aligned between environments
26
+ * - updateKey(): Updates application keys
27
+ *
28
+ * @example
29
+ * ```javascript
30
+ * const { applications } = require('sfdx-easy-sources');
31
+ *
32
+ * // Using default settings from easysources-settings.json
33
+ * await applications.split();
34
+ *
35
+ * // Override specific paths
36
+ * await applications.upsert({
37
+ * 'sf-xml': './custom-metadata-path',
38
+ * 'es-csv': './custom-csv-path'
39
+ * });
40
+ * ```
41
+ */
42
+ export declare const applications: {
43
+ /**
44
+ * Splits applications into separate files for easier management and version control.
45
+ * @param options Optional configuration, automatically resolved from settings if not provided
46
+ * @returns Promise resolving to operation result
47
+ */
48
+ split: (options?: ApplicationOptions) => Promise<AnyJson>;
49
+ /**
50
+ * Updates or inserts application records from CSV files to Salesforce metadata format.
51
+ * @param options Optional configuration, automatically resolved from settings if not provided
52
+ * @returns Promise resolving to operation result
53
+ */
54
+ upsert: (options?: ApplicationOptions) => Promise<AnyJson>;
55
+ /**
56
+ * Merges application files back into unified metadata files.
57
+ * @param options Optional configuration, automatically resolved from settings if not provided
58
+ * @returns Promise resolving to operation result
59
+ */
60
+ merge: (options?: ApplicationOptions) => Promise<AnyJson>;
61
+ /**
62
+ * Checks if applications are aligned between different environments or sources.
63
+ * @param options Optional configuration, automatically resolved from settings if not provided
64
+ * @returns Promise resolving to alignment check result
65
+ */
66
+ areAligned: (options?: ApplicationOptions) => Promise<AnyJson>;
67
+ /**
68
+ * Updates application keys based on configuration rules.
69
+ * @param options Optional configuration, automatically resolved from settings if not provided
70
+ * @returns Promise resolving to key update result
71
+ */
72
+ updateKey: (options?: ApplicationOptions) => Promise<AnyJson>;
73
+ };
@@ -0,0 +1,78 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.applications = void 0;
4
+ const split_1 = require("../commands/easysources/applications/split");
5
+ const upsert_1 = require("../commands/easysources/applications/upsert");
6
+ const merge_1 = require("../commands/easysources/applications/merge");
7
+ const arealigned_1 = require("../commands/easysources/applications/arealigned");
8
+ const updatekey_1 = require("../commands/easysources/applications/updatekey");
9
+ /**
10
+ * Application namespace containing all programmatic API functions for Salesforce Application metadata operations.
11
+ *
12
+ * All methods automatically resolve paths from easysources-settings.json configuration file.
13
+ * You only need to provide options to override the default behavior.
14
+ *
15
+ * Available operations:
16
+ * - split(): Splits applications into separate files
17
+ * - upsert(): Updates or inserts application records
18
+ * - merge(): Merges application files
19
+ * - areAligned(): Checks if applications are aligned between environments
20
+ * - updateKey(): Updates application keys
21
+ *
22
+ * @example
23
+ * ```javascript
24
+ * const { applications } = require('sfdx-easy-sources');
25
+ *
26
+ * // Using default settings from easysources-settings.json
27
+ * await applications.split();
28
+ *
29
+ * // Override specific paths
30
+ * await applications.upsert({
31
+ * 'sf-xml': './custom-metadata-path',
32
+ * 'es-csv': './custom-csv-path'
33
+ * });
34
+ * ```
35
+ */
36
+ exports.applications = {
37
+ /**
38
+ * Splits applications into separate files for easier management and version control.
39
+ * @param options Optional configuration, automatically resolved from settings if not provided
40
+ * @returns Promise resolving to operation result
41
+ */
42
+ split: async (options = {}) => {
43
+ return (0, split_1.applicationSplit)(options);
44
+ },
45
+ /**
46
+ * Updates or inserts application records from CSV files to Salesforce metadata format.
47
+ * @param options Optional configuration, automatically resolved from settings if not provided
48
+ * @returns Promise resolving to operation result
49
+ */
50
+ upsert: async (options = {}) => {
51
+ return (0, upsert_1.applicationUpsert)(options);
52
+ },
53
+ /**
54
+ * Merges application files back into unified metadata files.
55
+ * @param options Optional configuration, automatically resolved from settings if not provided
56
+ * @returns Promise resolving to operation result
57
+ */
58
+ merge: async (options = {}) => {
59
+ return (0, merge_1.applicationMerge)(options);
60
+ },
61
+ /**
62
+ * Checks if applications are aligned between different environments or sources.
63
+ * @param options Optional configuration, automatically resolved from settings if not provided
64
+ * @returns Promise resolving to alignment check result
65
+ */
66
+ areAligned: async (options = {}) => {
67
+ return (0, arealigned_1.applicationAreAligned)(options);
68
+ },
69
+ /**
70
+ * Updates application keys based on configuration rules.
71
+ * @param options Optional configuration, automatically resolved from settings if not provided
72
+ * @returns Promise resolving to key update result
73
+ */
74
+ updateKey: async (options = {}) => {
75
+ return (0, updatekey_1.applicationUpdateKey)(options);
76
+ }
77
+ };
78
+ //# sourceMappingURL=applications.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"applications.js","sourceRoot":"","sources":["../../src/api/applications.ts"],"names":[],"mappings":";;;AAEA,sEAA8E;AAC9E,wEAAgF;AAChF,sEAA8E;AAC9E,gFAAwF;AACxF,8EAAsF;AAetF;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACU,QAAA,YAAY,GAAG;IAC1B;;;;OAIG;IACH,KAAK,EAAE,KAAK,EAAE,UAA8B,EAAE,EAAoB,EAAE;QAClE,OAAO,IAAA,wBAAgB,EAAC,OAAO,CAAC,CAAC;IACnC,CAAC;IAED;;;;OAIG;IACH,MAAM,EAAE,KAAK,EAAE,UAA8B,EAAE,EAAoB,EAAE;QACnE,OAAO,IAAA,0BAAiB,EAAC,OAAO,CAAC,CAAC;IACpC,CAAC;IAED;;;;OAIG;IACH,KAAK,EAAE,KAAK,EAAE,UAA8B,EAAE,EAAoB,EAAE;QAClE,OAAO,IAAA,wBAAgB,EAAC,OAAO,CAAC,CAAC;IACnC,CAAC;IAED;;;;OAIG;IACH,UAAU,EAAE,KAAK,EAAE,UAA8B,EAAE,EAAoB,EAAE;QACvE,OAAO,IAAA,kCAAqB,EAAC,OAAO,CAAC,CAAC;IACxC,CAAC;IAED;;;;OAIG;IACH,SAAS,EAAE,KAAK,EAAE,UAA8B,EAAE,EAAoB,EAAE;QACtE,OAAO,IAAA,gCAAoB,EAAC,OAAO,CAAC,CAAC;IACvC,CAAC;CACF,CAAC"}
@@ -0,0 +1,73 @@
1
+ import { AnyJson } from '@salesforce/ts-types';
2
+ import { PathOptions } from './paths';
3
+ /**
4
+ * Interface for Global Value Set operation options.
5
+ * All properties are optional and will be resolved automatically from easysources-settings.json if not provided.
6
+ */
7
+ export interface GlobalValueSetOptions extends PathOptions {
8
+ /** Input global value sets (comma-separated) */
9
+ input?: string;
10
+ /** Sort output (default: 'false') */
11
+ sort?: 'true' | 'false';
12
+ /** Mode for areAligned operation (default: 'string') */
13
+ mode?: 'string' | 'logic';
14
+ }
15
+ /**
16
+ * Global Value Sets namespace containing all programmatic API functions for Salesforce Global Value Set metadata operations.
17
+ *
18
+ * All methods automatically resolve paths from easysources-settings.json configuration file.
19
+ * You only need to provide options to override the default behavior.
20
+ *
21
+ * Available operations:
22
+ * - split(): Splits global value sets into separate CSV files
23
+ * - upsert(): Updates or inserts global value set records
24
+ * - merge(): Merges global value set CSV files back to XML
25
+ * - areAligned(): Checks if global value sets are aligned between environments
26
+ * - updateKey(): Updates global value set keys
27
+ *
28
+ * @example
29
+ * ```javascript
30
+ * const { globalValueSets } = require('sfdx-easy-sources');
31
+ *
32
+ * // Using default settings from easysources-settings.json
33
+ * await globalValueSets.split();
34
+ *
35
+ * // Override specific paths
36
+ * await globalValueSets.upsert({
37
+ * 'sf-xml': './custom-metadata-path',
38
+ * 'es-csv': './custom-csv-path'
39
+ * });
40
+ * ```
41
+ */
42
+ export declare const globalValueSets: {
43
+ /**
44
+ * Splits global value sets into separate CSV files for easier management and version control.
45
+ * @param options Optional configuration, automatically resolved from settings if not provided
46
+ * @returns Promise resolving to operation result
47
+ */
48
+ split: (options?: GlobalValueSetOptions) => Promise<AnyJson>;
49
+ /**
50
+ * Updates or inserts global value set records from CSV files to Salesforce metadata format.
51
+ * @param options Optional configuration, automatically resolved from settings if not provided
52
+ * @returns Promise resolving to operation result
53
+ */
54
+ upsert: (options?: GlobalValueSetOptions) => Promise<AnyJson>;
55
+ /**
56
+ * Merges global value set CSV files back into unified metadata files.
57
+ * @param options Optional configuration, automatically resolved from settings if not provided
58
+ * @returns Promise resolving to operation result
59
+ */
60
+ merge: (options?: GlobalValueSetOptions) => Promise<AnyJson>;
61
+ /**
62
+ * Checks if global value sets are aligned between different environments or sources.
63
+ * @param options Optional configuration, automatically resolved from settings if not provided
64
+ * @returns Promise resolving to alignment check result
65
+ */
66
+ areAligned: (options?: GlobalValueSetOptions) => Promise<AnyJson>;
67
+ /**
68
+ * Updates global value set keys based on configuration rules.
69
+ * @param options Optional configuration, automatically resolved from settings if not provided
70
+ * @returns Promise resolving to key update result
71
+ */
72
+ updateKey: (options?: GlobalValueSetOptions) => Promise<AnyJson>;
73
+ };
@@ -0,0 +1,78 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.globalValueSets = void 0;
4
+ const split_1 = require("../commands/easysources/globalvaluesets/split");
5
+ const upsert_1 = require("../commands/easysources/globalvaluesets/upsert");
6
+ const merge_1 = require("../commands/easysources/globalvaluesets/merge");
7
+ const arealigned_1 = require("../commands/easysources/globalvaluesets/arealigned");
8
+ const updatekey_1 = require("../commands/easysources/globalvaluesets/updatekey");
9
+ /**
10
+ * Global Value Sets namespace containing all programmatic API functions for Salesforce Global Value Set metadata operations.
11
+ *
12
+ * All methods automatically resolve paths from easysources-settings.json configuration file.
13
+ * You only need to provide options to override the default behavior.
14
+ *
15
+ * Available operations:
16
+ * - split(): Splits global value sets into separate CSV files
17
+ * - upsert(): Updates or inserts global value set records
18
+ * - merge(): Merges global value set CSV files back to XML
19
+ * - areAligned(): Checks if global value sets are aligned between environments
20
+ * - updateKey(): Updates global value set keys
21
+ *
22
+ * @example
23
+ * ```javascript
24
+ * const { globalValueSets } = require('sfdx-easy-sources');
25
+ *
26
+ * // Using default settings from easysources-settings.json
27
+ * await globalValueSets.split();
28
+ *
29
+ * // Override specific paths
30
+ * await globalValueSets.upsert({
31
+ * 'sf-xml': './custom-metadata-path',
32
+ * 'es-csv': './custom-csv-path'
33
+ * });
34
+ * ```
35
+ */
36
+ exports.globalValueSets = {
37
+ /**
38
+ * Splits global value sets into separate CSV files for easier management and version control.
39
+ * @param options Optional configuration, automatically resolved from settings if not provided
40
+ * @returns Promise resolving to operation result
41
+ */
42
+ split: async (options = {}) => {
43
+ return (0, split_1.globalValueSetSplit)(options);
44
+ },
45
+ /**
46
+ * Updates or inserts global value set records from CSV files to Salesforce metadata format.
47
+ * @param options Optional configuration, automatically resolved from settings if not provided
48
+ * @returns Promise resolving to operation result
49
+ */
50
+ upsert: async (options = {}) => {
51
+ return (0, upsert_1.globalValueSetUpsert)(options);
52
+ },
53
+ /**
54
+ * Merges global value set CSV files back into unified metadata files.
55
+ * @param options Optional configuration, automatically resolved from settings if not provided
56
+ * @returns Promise resolving to operation result
57
+ */
58
+ merge: async (options = {}) => {
59
+ return (0, merge_1.globalValueSetMerge)(options);
60
+ },
61
+ /**
62
+ * Checks if global value sets are aligned between different environments or sources.
63
+ * @param options Optional configuration, automatically resolved from settings if not provided
64
+ * @returns Promise resolving to alignment check result
65
+ */
66
+ areAligned: async (options = {}) => {
67
+ return (0, arealigned_1.globalValueSetAreAligned)(options);
68
+ },
69
+ /**
70
+ * Updates global value set keys based on configuration rules.
71
+ * @param options Optional configuration, automatically resolved from settings if not provided
72
+ * @returns Promise resolving to key update result
73
+ */
74
+ updateKey: async (options = {}) => {
75
+ return (0, updatekey_1.globalValueSetUpdateKey)(options);
76
+ }
77
+ };
78
+ //# sourceMappingURL=globalvaluesets.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"globalvaluesets.js","sourceRoot":"","sources":["../../src/api/globalvaluesets.ts"],"names":[],"mappings":";;;AAEA,yEAAoF;AACpF,2EAAsF;AACtF,yEAAoF;AACpF,mFAA8F;AAC9F,iFAA4F;AAe5F;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACU,QAAA,eAAe,GAAG;IAC7B;;;;OAIG;IACH,KAAK,EAAE,KAAK,EAAE,UAAiC,EAAE,EAAoB,EAAE;QACrE,OAAO,IAAA,2BAAmB,EAAC,OAAO,CAAC,CAAC;IACtC,CAAC;IAED;;;;OAIG;IACH,MAAM,EAAE,KAAK,EAAE,UAAiC,EAAE,EAAoB,EAAE;QACtE,OAAO,IAAA,6BAAoB,EAAC,OAAO,CAAC,CAAC;IACvC,CAAC;IAED;;;;OAIG;IACH,KAAK,EAAE,KAAK,EAAE,UAAiC,EAAE,EAAoB,EAAE;QACrE,OAAO,IAAA,2BAAmB,EAAC,OAAO,CAAC,CAAC;IACtC,CAAC;IAED;;;;OAIG;IACH,UAAU,EAAE,KAAK,EAAE,UAAiC,EAAE,EAAoB,EAAE;QAC1E,OAAO,IAAA,qCAAwB,EAAC,OAAO,CAAC,CAAC;IAC3C,CAAC;IAED;;;;OAIG;IACH,SAAS,EAAE,KAAK,EAAE,UAAiC,EAAE,EAAoB,EAAE;QACzE,OAAO,IAAA,mCAAuB,EAAC,OAAO,CAAC,CAAC;IAC1C,CAAC;CACF,CAAC"}
@@ -0,0 +1,73 @@
1
+ import { AnyJson } from '@salesforce/ts-types';
2
+ import { PathOptions } from './paths';
3
+ /**
4
+ * Interface for Global Value Set Translation operation options.
5
+ * All properties are optional and will be resolved automatically from easysources-settings.json if not provided.
6
+ */
7
+ export interface GlobalValueSetTranslationOptions extends PathOptions {
8
+ /** Input global value set translations (comma-separated) */
9
+ input?: string;
10
+ /** Sort output (default: 'false') */
11
+ sort?: 'true' | 'false';
12
+ /** Mode for areAligned operation (default: 'string') */
13
+ mode?: 'string' | 'logic';
14
+ }
15
+ /**
16
+ * Global Value Set Translations namespace containing all programmatic API functions for Salesforce Global Value Set Translation metadata operations.
17
+ *
18
+ * All methods automatically resolve paths from easysources-settings.json configuration file.
19
+ * You only need to provide options to override the default behavior.
20
+ *
21
+ * Available operations:
22
+ * - split(): Splits global value set translations into separate CSV files
23
+ * - upsert(): Updates or inserts global value set translation records
24
+ * - merge(): Merges global value set translation CSV files back to XML
25
+ * - areAligned(): Checks if global value set translations are aligned between environments
26
+ * - updateKey(): Updates global value set translation keys
27
+ *
28
+ * @example
29
+ * ```javascript
30
+ * const { globalValueSetTranslations } = require('sfdx-easy-sources');
31
+ *
32
+ * // Using default settings from easysources-settings.json
33
+ * await globalValueSetTranslations.split();
34
+ *
35
+ * // Override specific paths
36
+ * await globalValueSetTranslations.upsert({
37
+ * 'sf-xml': './custom-metadata-path',
38
+ * 'es-csv': './custom-csv-path'
39
+ * });
40
+ * ```
41
+ */
42
+ export declare const globalValueSetTranslations: {
43
+ /**
44
+ * Splits global value set translations into separate CSV files for easier management and version control.
45
+ * @param options Optional configuration, automatically resolved from settings if not provided
46
+ * @returns Promise resolving to operation result
47
+ */
48
+ split: (options?: GlobalValueSetTranslationOptions) => Promise<AnyJson>;
49
+ /**
50
+ * Updates or inserts global value set translation records from CSV files to Salesforce metadata format.
51
+ * @param options Optional configuration, automatically resolved from settings if not provided
52
+ * @returns Promise resolving to operation result
53
+ */
54
+ upsert: (options?: GlobalValueSetTranslationOptions) => Promise<AnyJson>;
55
+ /**
56
+ * Merges global value set translation CSV files back into unified metadata files.
57
+ * @param options Optional configuration, automatically resolved from settings if not provided
58
+ * @returns Promise resolving to operation result
59
+ */
60
+ merge: (options?: GlobalValueSetTranslationOptions) => Promise<AnyJson>;
61
+ /**
62
+ * Checks if global value set translations are aligned between different environments or sources.
63
+ * @param options Optional configuration, automatically resolved from settings if not provided
64
+ * @returns Promise resolving to alignment check result
65
+ */
66
+ areAligned: (options?: GlobalValueSetTranslationOptions) => Promise<AnyJson>;
67
+ /**
68
+ * Updates global value set translation keys based on configuration rules.
69
+ * @param options Optional configuration, automatically resolved from settings if not provided
70
+ * @returns Promise resolving to key update result
71
+ */
72
+ updateKey: (options?: GlobalValueSetTranslationOptions) => Promise<AnyJson>;
73
+ };
@@ -0,0 +1,78 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.globalValueSetTranslations = void 0;
4
+ const split_1 = require("../commands/easysources/globalvaluesettranslations/split");
5
+ const upsert_1 = require("../commands/easysources/globalvaluesettranslations/upsert");
6
+ const merge_1 = require("../commands/easysources/globalvaluesettranslations/merge");
7
+ const arealigned_1 = require("../commands/easysources/globalvaluesettranslations/arealigned");
8
+ const updatekey_1 = require("../commands/easysources/globalvaluesettranslations/updatekey");
9
+ /**
10
+ * Global Value Set Translations namespace containing all programmatic API functions for Salesforce Global Value Set Translation metadata operations.
11
+ *
12
+ * All methods automatically resolve paths from easysources-settings.json configuration file.
13
+ * You only need to provide options to override the default behavior.
14
+ *
15
+ * Available operations:
16
+ * - split(): Splits global value set translations into separate CSV files
17
+ * - upsert(): Updates or inserts global value set translation records
18
+ * - merge(): Merges global value set translation CSV files back to XML
19
+ * - areAligned(): Checks if global value set translations are aligned between environments
20
+ * - updateKey(): Updates global value set translation keys
21
+ *
22
+ * @example
23
+ * ```javascript
24
+ * const { globalValueSetTranslations } = require('sfdx-easy-sources');
25
+ *
26
+ * // Using default settings from easysources-settings.json
27
+ * await globalValueSetTranslations.split();
28
+ *
29
+ * // Override specific paths
30
+ * await globalValueSetTranslations.upsert({
31
+ * 'sf-xml': './custom-metadata-path',
32
+ * 'es-csv': './custom-csv-path'
33
+ * });
34
+ * ```
35
+ */
36
+ exports.globalValueSetTranslations = {
37
+ /**
38
+ * Splits global value set translations into separate CSV files for easier management and version control.
39
+ * @param options Optional configuration, automatically resolved from settings if not provided
40
+ * @returns Promise resolving to operation result
41
+ */
42
+ split: async (options = {}) => {
43
+ return (0, split_1.globalValueSetTranslationSplit)(options);
44
+ },
45
+ /**
46
+ * Updates or inserts global value set translation records from CSV files to Salesforce metadata format.
47
+ * @param options Optional configuration, automatically resolved from settings if not provided
48
+ * @returns Promise resolving to operation result
49
+ */
50
+ upsert: async (options = {}) => {
51
+ return (0, upsert_1.globalValueSetTranslationUpsert)(options);
52
+ },
53
+ /**
54
+ * Merges global value set translation CSV files back into unified metadata files.
55
+ * @param options Optional configuration, automatically resolved from settings if not provided
56
+ * @returns Promise resolving to operation result
57
+ */
58
+ merge: async (options = {}) => {
59
+ return (0, merge_1.globalValueSetTranslationMerge)(options);
60
+ },
61
+ /**
62
+ * Checks if global value set translations are aligned between different environments or sources.
63
+ * @param options Optional configuration, automatically resolved from settings if not provided
64
+ * @returns Promise resolving to alignment check result
65
+ */
66
+ areAligned: async (options = {}) => {
67
+ return (0, arealigned_1.globalValueSetTranslationAreAligned)(options);
68
+ },
69
+ /**
70
+ * Updates global value set translation keys based on configuration rules.
71
+ * @param options Optional configuration, automatically resolved from settings if not provided
72
+ * @returns Promise resolving to key update result
73
+ */
74
+ updateKey: async (options = {}) => {
75
+ return (0, updatekey_1.globalValueSetTranslationUpdateKey)(options);
76
+ }
77
+ };
78
+ //# sourceMappingURL=globalvaluesettranslations.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"globalvaluesettranslations.js","sourceRoot":"","sources":["../../src/api/globalvaluesettranslations.ts"],"names":[],"mappings":";;;AAEA,oFAA0G;AAC1G,sFAA4G;AAC5G,oFAA0G;AAC1G,8FAAoH;AACpH,4FAAkH;AAelH;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACU,QAAA,0BAA0B,GAAG;IACxC;;;;OAIG;IACH,KAAK,EAAE,KAAK,EAAE,UAA4C,EAAE,EAAoB,EAAE;QAChF,OAAO,IAAA,sCAA8B,EAAC,OAAO,CAAC,CAAC;IACjD,CAAC;IAED;;;;OAIG;IACH,MAAM,EAAE,KAAK,EAAE,UAA4C,EAAE,EAAoB,EAAE;QACjF,OAAO,IAAA,wCAA+B,EAAC,OAAO,CAAC,CAAC;IAClD,CAAC;IAED;;;;OAIG;IACH,KAAK,EAAE,KAAK,EAAE,UAA4C,EAAE,EAAoB,EAAE;QAChF,OAAO,IAAA,sCAA8B,EAAC,OAAO,CAAC,CAAC;IACjD,CAAC;IAED;;;;OAIG;IACH,UAAU,EAAE,KAAK,EAAE,UAA4C,EAAE,EAAoB,EAAE;QACrF,OAAO,IAAA,gDAAmC,EAAC,OAAO,CAAC,CAAC;IACtD,CAAC;IAED;;;;OAIG;IACH,SAAS,EAAE,KAAK,EAAE,UAA4C,EAAE,EAAoB,EAAE;QACpF,OAAO,IAAA,8CAAkC,EAAC,OAAO,CAAC,CAAC;IACrD,CAAC;CACF,CAAC"}