Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
cocoapods
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gengmeiios
cocoapods
Commits
b1a5f6e7
Commit
b1a5f6e7
authored
Aug 06, 2012
by
Fabio Pelosin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Repo#lint] Added only-errors option.
parent
84f62600
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
4 deletions
+13
-4
repo.rb
lib/cocoapods/command/repo.rb
+13
-4
No files found.
lib/cocoapods/command/repo.rb
View file @
b1a5f6e7
...
...
@@ -23,6 +23,10 @@ module Pod
lint all the spec-repos known to CocoaPods.}
end
def
self
.
options
[[
"--only-errors"
,
"Lint presents only the errors"
]].
concat
(
super
)
end
extend
Executable
executable
:git
...
...
@@ -33,8 +37,11 @@ module Pod
raise
Informative
,
"
#{
@action
==
'add'
?
'Adding'
:
'Updating the remote of'
}
a repo needs a `name' and a `url'."
end
@branch
=
argv
.
arguments
[
3
]
when
'update'
,
'lint'
when
'update'
@name
=
argv
.
arguments
[
1
]
when
'lint'
@name
=
argv
.
arguments
[
1
]
@only_errors
=
argv
.
option
(
'--only-errors'
)
else
super
end
...
...
@@ -92,7 +99,7 @@ module Pod
linter
.
lint
unless
linter
.
result_type
==
:success
if
(
!
@only_errors
&&
linter
.
result_type
!=
:success
)
||
linter
.
result_type
==
:error
case
linter
.
result_type
when
:error
invalid_count
+=
1
...
...
@@ -102,8 +109,10 @@ module Pod
end
puts
" -> "
.
send
(
color
)
<<
linter
.
spec_name
print_messages
(
'ERROR'
,
linter
.
errors
)
print_messages
(
'WARN'
,
linter
.
warnings
)
print_messages
(
'NOTE'
,
linter
.
notes
)
unless
@only_errors
print_messages
(
'WARN'
,
linter
.
warnings
)
print_messages
(
'NOTE'
,
linter
.
notes
)
end
puts
unless
config
.
silent?
end
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment