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
f5fd3d24
Commit
f5fd3d24
authored
Nov 12, 2016
by
Samuel Giddins
Committed by
GitHub
Nov 12, 2016
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #6141 from CocoaPods/seg-sources-mananger-const-hack
[SourcesManager] Remove const_missing hack
parents
c2aa84f5
0b0d708f
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
31 deletions
+3
-31
CHANGELOG.md
CHANGELOG.md
+3
-0
sources_manager.rb
lib/cocoapods/sources_manager.rb
+0
-31
No files found.
CHANGELOG.md
View file @
f5fd3d24
...
@@ -27,6 +27,9 @@ To install release candidates run `[sudo] gem install cocoapods --pre`
...
@@ -27,6 +27,9 @@ To install release candidates run `[sudo] gem install cocoapods --pre`
*
Fail gracefully when downloading a podspec in
`pod spec lint`
fails.
*
Fail gracefully when downloading a podspec in
`pod spec lint`
fails.
[
Samuel Giddins
](
https://github.com/segiddins
)
[
Samuel Giddins
](
https://github.com/segiddins
)
*
Remove the
`const_missing`
hack for
`Pod::SourcesManager`
.
[
Samuel Giddins
](
https://github.com/segiddins
)
## 1.2.0.beta.1 (2016-10-28)
## 1.2.0.beta.1 (2016-10-28)
...
...
lib/cocoapods/sources_manager.rb
View file @
f5fd3d24
...
@@ -150,35 +150,4 @@ module Pod
...
@@ -150,35 +150,4 @@ module Pod
UI
.
puts
(
message
)
UI
.
puts
(
message
)
end
end
end
end
# @!visibility private
module
SourcesManagerMissingConstant
SOURCES_MANAGER_CONSTANT_WARNINGS
=
Set
.
new
# Warn about deprecated use of `Pod::SourcesManager` and return the config's
# Source::Manager
#
# @param [#to_sym] const the missing constant
#
# @return [Pod::Source::Manager]
#
def
const_missing
(
const
)
unless
const
.
to_sym
==
:SourcesManager
&&
ancestors
.
any?
{
|
a
|
a
==
::
Pod
||
a
.
name
.
start_with?
(
'Pod::'
)
}
return
super
end
calling_line
=
caller
.
first
if
Pod
::
SourcesManagerMissingConstant
::
SOURCES_MANAGER_CONSTANT_WARNINGS
.
add?
(
calling_line
)
warn
'Usage of the constant `Pod::SourcesManager` is deprecated, '
\
'use `Pod::Config.instance.sources_manager` instead '
\
"(called from
#{
calling_line
}
)"
end
Config
.
instance
.
sources_manager
end
end
extend
SourcesManagerMissingConstant
::
Object
.
send
(
:extend
,
SourcesManagerMissingConstant
)
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