salesforce-dcgen 0.0.7 → 0.0.9
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.
- checksums.yaml +4 -4
- data/lib/dcgen/app.rb +26 -1
- data/lib/dcgen/plugins/apexclass.rb +8 -1
- data/lib/dcgen/plugins/apexpage.rb +8 -1
- data/lib/dcgen/plugins/approvalprocess.rb +8 -1
- data/lib/dcgen/plugins/customfield.rb +8 -3
- data/lib/dcgen/plugins/group.rb +8 -1
- data/lib/dcgen/plugins/label.rb +5 -0
- data/lib/dcgen/plugins/permissionset.rb +8 -1
- data/lib/dcgen/plugins/workflowrule.rb +5 -0
- data/lib/dcgen/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: da088337dcf551f0c47363549d94d7fd62d53181
|
4
|
+
data.tar.gz: 8c1953dd72cddbfa402939d4810e0a345366baf8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 948e81efdae419761d32934d8bd9b739755edddb67955704c80343697146777a349b8314137110e9b8572542f1922ded66df89fecf4efc64c5bb7109e0a25fd6
|
7
|
+
data.tar.gz: bc6618b2e576aedda1a027a4ecf910adf25bf150aa1598e0c619213b414b56d8e168392a016a70e8121deae7d1ff9a661ad831db0be29cf5f668aff6de75d1dd
|
data/lib/dcgen/app.rb
CHANGED
@@ -33,7 +33,29 @@ module Dcgen
|
|
33
33
|
file.write renderer.result(binding)
|
34
34
|
end
|
35
35
|
|
36
|
-
puts "
|
36
|
+
puts "
|
37
|
+
File generated:
|
38
|
+
===============
|
39
|
+
|
40
|
+
#{out_file}
|
41
|
+
|
42
|
+
"
|
43
|
+
|
44
|
+
end
|
45
|
+
|
46
|
+
def print_header
|
47
|
+
|
48
|
+
puts "
|
49
|
+
Diff between:
|
50
|
+
=============
|
51
|
+
|
52
|
+
master: #{master}
|
53
|
+
destination: #{destination}:
|
54
|
+
|
55
|
+
Changes detected:
|
56
|
+
=================
|
57
|
+
|
58
|
+
"
|
37
59
|
|
38
60
|
end
|
39
61
|
|
@@ -42,6 +64,9 @@ module Dcgen
|
|
42
64
|
# Validate directories
|
43
65
|
validate_directories
|
44
66
|
|
67
|
+
# header output
|
68
|
+
print_header
|
69
|
+
|
45
70
|
# Load plugins and build metadata variables
|
46
71
|
plugins = Dir.glob(File.dirname(__FILE__) + "/plugins/*" )
|
47
72
|
|
@@ -5,7 +5,14 @@ module Dcgen
|
|
5
5
|
master_classes = Dir.glob(master + '/classes/*cls').map {|c| c.match(/^.*\/(.*).cls$/)[1] }
|
6
6
|
destination_classes = Dir.glob(destination + '/classes/*cls').map {|c| c.match(/^.*\/(.*).cls$/)[1] }
|
7
7
|
|
8
|
-
destination_classes - master_classes
|
8
|
+
remove_classes = destination_classes - master_classes
|
9
|
+
|
10
|
+
puts "ApexClasses:" if not remove_classes.empty?
|
11
|
+
remove_classes.each do |apexclass|
|
12
|
+
puts " #{apexclass}"
|
13
|
+
end
|
14
|
+
|
15
|
+
remove_classes
|
9
16
|
|
10
17
|
end
|
11
18
|
|
@@ -5,7 +5,14 @@ module Dcgen
|
|
5
5
|
master_pages = Dir.glob(master + '/pages/*page').map {|c| c.match(/^.*\/(.*).page$/)[1] }
|
6
6
|
destination_pages = Dir.glob(destination + '/pages/*page').map {|c| c.match(/^.*\/(.*).page$/)[1] }
|
7
7
|
|
8
|
-
destination_pages - master_pages
|
8
|
+
remove_pages = destination_pages - master_pages
|
9
|
+
|
10
|
+
puts "ApexPages:" if not remove_pages.empty?
|
11
|
+
remove_pages.each do |aplexpage|
|
12
|
+
puts " #{aplexpage}"
|
13
|
+
end
|
14
|
+
|
15
|
+
remove_pages
|
9
16
|
|
10
17
|
end
|
11
18
|
|
@@ -5,7 +5,14 @@ module Dcgen
|
|
5
5
|
master_approvalprocess = Dir.glob(master + '/approvalProcesses/*approvalProcess').map {|c| c.match(/^.*\/(.*).approvalProcess$/)[1] }
|
6
6
|
destination_approvalprocess = Dir.glob(destination + '/approvalProcesses/*approvalProcess').map {|c| c.match(/^.*\/(.*).approvalProcess$/)[1] }
|
7
7
|
|
8
|
-
destination_approvalprocess - master_approvalprocess
|
8
|
+
remove_approvalprocess = destination_approvalprocess - master_approvalprocess
|
9
|
+
|
10
|
+
puts "ApprovalProcesses:" if not remove_approvalprocess.empty?
|
11
|
+
remove_approvalprocess.each do |approvalprocess|
|
12
|
+
puts " #{approvalprocess}"
|
13
|
+
end
|
14
|
+
|
15
|
+
remove_approvalprocess
|
9
16
|
|
10
17
|
end
|
11
18
|
|
@@ -4,7 +4,7 @@ module Dcgen
|
|
4
4
|
|
5
5
|
def self.customfield master , destination
|
6
6
|
|
7
|
-
|
7
|
+
remove_customfields = []
|
8
8
|
|
9
9
|
master_objects = Dir.glob(master + '/objects/*object').map {|c| c.match(/^.*\/(.*).object$/)[1] }
|
10
10
|
|
@@ -24,14 +24,19 @@ module Dcgen
|
|
24
24
|
# Find all the customfields that are in destination, if they are not present in
|
25
25
|
# master, then they have to be in the remove list
|
26
26
|
destination_doc.xpath('//fields/fullName').each do |field|
|
27
|
-
|
27
|
+
remove_customfields << "#{obj}.#{field.text}" if master_doc.xpath("//fields[fullName=\"#{field.text}\"]").empty?
|
28
28
|
end
|
29
29
|
|
30
30
|
end
|
31
31
|
|
32
32
|
end
|
33
33
|
|
34
|
-
|
34
|
+
puts "CustomFields:" if not remove_customfields.empty?
|
35
|
+
remove_customfields.each do |customfield|
|
36
|
+
puts " #{customfield}"
|
37
|
+
end
|
38
|
+
|
39
|
+
remove_customfields
|
35
40
|
|
36
41
|
end
|
37
42
|
end
|
data/lib/dcgen/plugins/group.rb
CHANGED
@@ -5,7 +5,14 @@ module Dcgen
|
|
5
5
|
master_groups = Dir.glob(master + '/groups/*group').map {|c| c.match(/^.*\/(.*).group$/)[1] }
|
6
6
|
destination_groups = Dir.glob(destination + '/groups/*group').map {|c| c.match(/^.*\/(.*).group$/)[1] }
|
7
7
|
|
8
|
-
destination_groups - master_groups
|
8
|
+
remove_groups = destination_groups - master_groups
|
9
|
+
|
10
|
+
puts "Groups:" if not remove_groups.empty?
|
11
|
+
remove_groups.each do |group|
|
12
|
+
puts " #{group}"
|
13
|
+
end
|
14
|
+
|
15
|
+
remove_groups
|
9
16
|
|
10
17
|
end
|
11
18
|
|
data/lib/dcgen/plugins/label.rb
CHANGED
@@ -5,7 +5,14 @@ module Dcgen
|
|
5
5
|
master_permissionset = Dir.glob(master + '/permissionsets/*permissionset').map {|c| c.match(/^.*\/(.*).permissionset$/)[1] }
|
6
6
|
destination_permissionset = Dir.glob(destination + '/permissionsets/*permissionset').map {|c| c.match(/^.*\/(.*).permissionset$/)[1] }
|
7
7
|
|
8
|
-
destination_permissionset - master_permissionset
|
8
|
+
remove_permissionset = destination_permissionset - master_permissionset
|
9
|
+
|
10
|
+
puts "PermissionSets:" if not remove_permissionset.empty?
|
11
|
+
remove_permissionset.each do |permissionset|
|
12
|
+
puts " #{permissionset}"
|
13
|
+
end
|
14
|
+
|
15
|
+
remove_permissionset
|
9
16
|
|
10
17
|
end
|
11
18
|
|
data/lib/dcgen/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: salesforce-dcgen
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Juan Breinlinger
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-10-
|
11
|
+
date: 2014-10-31 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|