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
4d91b1e0
Commit
4d91b1e0
authored
Feb 21, 2013
by
Fabio Pelosin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Command::IPC] Convert Podfiles to YAML
parent
5efcdee9
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
39 additions
and
0 deletions
+39
-0
inter_process_communication.rb
lib/cocoapods/command/inter_process_communication.rb
+25
-0
inter_process_communication_spec.rb
spec/functional/command/inter_process_communication_spec.rb
+14
-0
No files found.
lib/cocoapods/command/inter_process_communication.rb
View file @
4d91b1e0
...
@@ -32,6 +32,31 @@ module Pod
...
@@ -32,6 +32,31 @@ module Pod
#-----------------------------------------------------------------------#
#-----------------------------------------------------------------------#
class
Podfile
<
IPC
self
.
summary
=
'Converts a Podfile to YAML.'
self
.
description
=
'Converts a Podfile to YAML and prints it to STDOUT.'
self
.
arguments
=
'PATH'
def
initialize
(
argv
)
@path
=
argv
.
shift_argument
super
end
def
validate!
super
help!
"A Podfile path is required."
unless
@path
end
def
run
podfile
=
Pod
::
Podfile
.
from_file
(
@path
)
UI
.
puts
podfile
.
to_yaml
end
end
#-----------------------------------------------------------------------#
class
List
<
IPC
class
List
<
IPC
self
.
summary
=
'Lists the specifications know to CocoaPods.'
self
.
summary
=
'Lists the specifications know to CocoaPods.'
...
...
spec/functional/command/inter_process_communication_spec.rb
View file @
4d91b1e0
...
@@ -17,6 +17,20 @@ module Pod
...
@@ -17,6 +17,20 @@ module Pod
#-------------------------------------------------------------------------#
#-------------------------------------------------------------------------#
describe
Command
::
IPC
::
Podfile
do
it
"converts a Podfile to yaml and prints it to STDOUT"
do
out
=
run_command
(
'ipc'
,
'podfile'
,
fixture
(
'Podfile'
))
out
.
should
.
include
(
'---'
)
out
.
should
.
match
/target_definitions:/
out
.
should
.
match
/platform: :ios/
out
.
should
.
match
/- SSZipArchive:/
end
end
#-------------------------------------------------------------------------#
describe
Command
::
IPC
::
List
do
describe
Command
::
IPC
::
List
do
it
"converts a podspec to yaml and prints it to STDOUT"
do
it
"converts a podspec to yaml and prints it to STDOUT"
do
...
...
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