cocoapods-ack_filter 0.1.1 → 0.2.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.
- checksums.yaml +4 -4
- data/README.md +2 -1
- data/lib/cocoapods/ack_filter/version.rb +1 -1
- data/lib/pod/command/ack_filter.rb +9 -4
- metadata +4 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0d1477e23b10a98d27ce16bf1e8990af7c946f37
|
4
|
+
data.tar.gz: 44e5edfe9d9714af26b0da910629633ffedddfd9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e4a4d0146858da6b5bc150a997d97b80adcd02b072c41ac4acc87f22cf4768c918c202c37cefc0024fa83c6c221001d795765a663bf01c1b7a5f1e5bac01f522
|
7
|
+
data.tar.gz: 3a97fbd6b6c4b652b53f35f2807b78e334f6144f0fb92c390da54c4c2fd9d34c9ff85c85c8a5d6b66fe02336d9481f6ecada92ebd7b10ec425e408031497880f
|
data/README.md
CHANGED
@@ -21,10 +21,11 @@ Or install it yourself as:
|
|
21
21
|
## Usage
|
22
22
|
|
23
23
|
```
|
24
|
-
pod ack-filter PATTERN [--output=FILENAME]
|
24
|
+
pod ack-filter PATTERN [--input=FILENAME] [--output=FILENAME]
|
25
25
|
```
|
26
26
|
|
27
27
|
- PATTERN is regexp pattern string
|
28
|
+
- --input is input acknowledgements.plist filename
|
28
29
|
- --output is output filename
|
29
30
|
|
30
31
|
### Example
|
@@ -4,15 +4,14 @@ require 'CFPropertyList'
|
|
4
4
|
module Pod
|
5
5
|
class Command
|
6
6
|
class AckFilter < Command
|
7
|
-
ACKNOWLEDGEMENTS_FILE = 'Pods/Target Support Files/Pods/Pods-acknowledgements.plist'
|
8
|
-
|
9
7
|
self.summary = 'Filter out licenses with pattern from Pods-acknowledgements.plist'
|
10
8
|
self.arguments = [
|
11
9
|
CLAide::Argument.new("PATTERN", true)
|
12
10
|
]
|
13
11
|
|
14
12
|
def self.options
|
15
|
-
[['--
|
13
|
+
[['--input=FILE_PATH', 'Read acknowledgements file from FILE_PATH'],
|
14
|
+
['--output=FILENAME', 'Output filtered acknowledgements to FILENAME']]
|
16
15
|
end
|
17
16
|
|
18
17
|
def self.filter(args, &block)
|
@@ -22,12 +21,14 @@ module Pod
|
|
22
21
|
def initialize(argv, &block)
|
23
22
|
if argv.kind_of?(CLAide::ARGV)
|
24
23
|
@pattern = Regexp.new(argv.shift_argument) unless argv.empty?
|
24
|
+
@input = argv.option('input')
|
25
25
|
@filename = argv.option('output')
|
26
26
|
super
|
27
27
|
else
|
28
28
|
if argv[:pattern]
|
29
29
|
@pattern = argv[:pattern].kind_of?(Regexp) ? argv[:pattern] : Regexp.new(argv[:pattern])
|
30
30
|
end
|
31
|
+
@input = argv[:input]
|
31
32
|
@filename = argv[:output]
|
32
33
|
@filter_block = block
|
33
34
|
end
|
@@ -38,12 +39,16 @@ module Pod
|
|
38
39
|
help! 'Specify filtering pattern' if !@pattern && !@filter_block
|
39
40
|
end
|
40
41
|
|
42
|
+
def input
|
43
|
+
@input || 'Pods/Target Support Files/Pods/Pods-acknowledgements.plist'
|
44
|
+
end
|
45
|
+
|
41
46
|
def output_filename
|
42
47
|
@filename || 'Acknowledgements.plist'
|
43
48
|
end
|
44
49
|
|
45
50
|
def run
|
46
|
-
plist = CFPropertyList::List.new(file:
|
51
|
+
plist = CFPropertyList::List.new(file: input)
|
47
52
|
specs = plist.value.value['PreferenceSpecifiers']
|
48
53
|
specs.value.reject! do |spec|
|
49
54
|
if @filter_block
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cocoapods-ack_filter
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Yusuke Mito
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2015-02-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: cocoapods
|
@@ -116,8 +116,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
116
116
|
version: '0'
|
117
117
|
requirements: []
|
118
118
|
rubyforge_project:
|
119
|
-
rubygems_version: 2.
|
119
|
+
rubygems_version: 2.2.2
|
120
120
|
signing_key:
|
121
121
|
specification_version: 4
|
122
122
|
summary: Filter out licenses with pattern from Pods-acknowledgements.plist
|
123
123
|
test_files: []
|
124
|
+
has_rdoc:
|