synx 0.1.1 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -0
- data/bin/synx +2 -1
- data/lib/synx/project.rb +3 -2
- data/lib/synx/version.rb +1 -1
- data/lib/synx/xcodeproj_ext/project/object/pbx_group.rb +2 -2
- 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: f274857ea258f15c41e4cd795ee132e10c65aab2
|
4
|
+
data.tar.gz: 540ffdcc6752f0e5a1fe417e94b06ce53fba489f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ca501f7cf96443618567cbd3a36dfcb47db0f5b06e103729cb1546fb5b481d4339966be684a86ac954861339c300ad64f13e6b339cf2ed6a4a61a53f56f182d6
|
7
|
+
data.tar.gz: 50865879aae17780b10c70b100d656074c7ea4d5796be5d2d73fd9559b95a0624a01ff653896de104c5fd086c7b522b8f7540393174e41a59150237321f59d05
|
data/README.md
CHANGED
@@ -42,6 +42,7 @@ Synx supports the following options:
|
|
42
42
|
--prune, -p remove source files and image resources that are not referenced by the the Xcode project
|
43
43
|
--no-color removes all color from the output
|
44
44
|
--no-default-exclusions doesn't use the default exclusions of /Libraries, /Frameworks, and /Products
|
45
|
+
--no-sort-by-name disable sorting groups by name
|
45
46
|
--quiet, -q silence all output
|
46
47
|
--exclusion, -e EXCLUSION ignore an Xcode group while syncing
|
47
48
|
```
|
data/bin/synx
CHANGED
@@ -9,6 +9,7 @@ Clamp do
|
|
9
9
|
option ["--prune", "-p"], :flag, "remove source files and image resources that are not referenced by the the xcode project"
|
10
10
|
option "--no-color", :flag, "removes all color from the output"
|
11
11
|
option "--no-default-exclusions", :flag, "doesn't use the default exclusions of /Libraries, /Frameworks, and /Products"
|
12
|
+
option "--no-sort-by-name", :flag, "disable sorting groups by name"
|
12
13
|
option ["--quiet", "-q"], :flag, "silence all output"
|
13
14
|
option ["--exclusion", "-e"], "EXCLUSION", "ignore an Xcode group while syncing", :multivalued => true
|
14
15
|
option ["--version", "-v"], :flag, "shows synx version" do
|
@@ -21,7 +22,7 @@ Clamp do
|
|
21
22
|
puts "You cannot run Synx as root.".red
|
22
23
|
else
|
23
24
|
project = Synx::Project.open(xcodeproj_path)
|
24
|
-
project.sync(:prune => prune?, :quiet => quiet?, :no_color => no_color?, :no_default_exclusions => no_default_exclusions?, :group_exclusions => exclusion_list)
|
25
|
+
project.sync(:prune => prune?, :quiet => quiet?, :no_color => no_color?, :no_default_exclusions => no_default_exclusions?, :no_sort_by_name => no_sort_by_name?, :group_exclusions => exclusion_list)
|
25
26
|
end
|
26
27
|
end
|
27
28
|
|
data/lib/synx/project.rb
CHANGED
@@ -10,7 +10,7 @@ module Synx
|
|
10
10
|
DEFAULT_EXCLUSIONS = %W(/Libraries /Frameworks /Products /Pods)
|
11
11
|
private_constant :DEFAULT_EXCLUSIONS
|
12
12
|
|
13
|
-
attr_accessor :delayed_groups_set_path, :group_exclusions, :prune
|
13
|
+
attr_accessor :delayed_groups_set_path, :group_exclusions, :prune, :sort_by_name
|
14
14
|
|
15
15
|
def sync(options={})
|
16
16
|
set_options(options)
|
@@ -21,7 +21,7 @@ module Synx
|
|
21
21
|
Synx::Tabber.puts "\n\n"
|
22
22
|
Synx::Tabber.puts "Syncing files that are not included in Xcode project..".bold.white
|
23
23
|
main_group.all_groups.each(&:move_entries_not_in_xcodeproj)
|
24
|
-
main_group.sort_by_name
|
24
|
+
main_group.sort_by_name if self.sort_by_name
|
25
25
|
transplant_work_project
|
26
26
|
Synx::Tabber.decrease
|
27
27
|
save
|
@@ -49,6 +49,7 @@ module Synx
|
|
49
49
|
end
|
50
50
|
|
51
51
|
self.group_exclusions |= options[:group_exclusions] if options[:group_exclusions]
|
52
|
+
self.sort_by_name = !options[:no_sort_by_name]
|
52
53
|
|
53
54
|
Synx::Tabber.options = options
|
54
55
|
end
|
data/lib/synx/version.rb
CHANGED
@@ -24,7 +24,7 @@ module Xcodeproj
|
|
24
24
|
group.sync(self)
|
25
25
|
end
|
26
26
|
sync_path
|
27
|
-
sort_by_name
|
27
|
+
sort_by_name if project.sort_by_name
|
28
28
|
|
29
29
|
Synx::Tabber.decrease
|
30
30
|
end
|
@@ -93,7 +93,7 @@ module Xcodeproj
|
|
93
93
|
private :handle_unused_entry
|
94
94
|
|
95
95
|
def handle_unused_file(file_pathname)
|
96
|
-
prune_file_extensions = %W(.h .m .
|
96
|
+
prune_file_extensions = %W(.h .m .swift .mm .c .xib .png .jpg .jpeg)
|
97
97
|
is_file_to_prune = prune_file_extensions.include?(file_pathname.extname.downcase)
|
98
98
|
|
99
99
|
if is_file_to_prune && project.prune
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: synx
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mark Larsen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-02-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|