Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Apply GitHub checking logic to all GitHub hosted sources
- Loading branch information
Showing
9 changed files
with
63 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,3 +12,4 @@ coverage/ | |
.coveralls.yml | ||
.idea/ | ||
documentation/ | ||
.bundle/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,7 @@ | ||
module Pod | ||
class MasterSource < Source | ||
# @!group Updating the source | ||
#-------------------------------------------------------------------------# | ||
|
||
# Updates the local clone of the source repo. | ||
# | ||
# @param [Bool] show_output | ||
# | ||
# @return [Array<String>] changed_spec_paths | ||
# Returns the list of changed spec paths. | ||
# | ||
def update(show_output) | ||
if requires_update? | ||
super | ||
else | ||
[] | ||
end | ||
end | ||
|
||
private | ||
|
||
# Returns whether a source requires updating. | ||
# | ||
# @param [Source] source | ||
# The source to check. | ||
# | ||
# @return [Bool] Whether the given source should be updated. | ||
# | ||
def requires_update? | ||
commit_hash = git_commit_hash | ||
GitHub.modified_since_commit('CocoaPods/Specs', commit_hash) | ||
end | ||
# For now, the MasterSource behaves exactly the same as any other Source. | ||
# In the future we may apply separate logic to the MasterSource that doesn't | ||
# depend on the file system. | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters