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
65594c69
Commit
65594c69
authored
Feb 15, 2012
by
Eloy Duran
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cleanup Rakefile and build ext before any type of spec run.
parent
56c1f654
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
44 deletions
+3
-44
Rakefile
Rakefile
+3
-44
No files found.
Rakefile
View file @
65594c69
class
Array
def
move_to_front
(
name
,
by_basename
=
true
)
path
=
find
{
|
f
|
(
by_basename
?
File
.
basename
(
f
)
:
f
)
==
name
}
delete
(
path
)
unshift
(
path
)
end
end
task
:standalone
do
files
=
Dir
.
glob
(
"lib/**/*.rb"
)
files
.
move_to_front
(
'executable.rb'
)
files
.
move_to_front
(
'lib/cocoapods/config.rb'
,
false
)
files
.
move_to_front
(
'cocoapods.rb'
)
File
.
open
(
'concatenated.rb'
,
'w'
)
do
|
f
|
files
.
each
do
|
file
|
File
.
read
(
file
).
split
(
"
\n
"
).
each
do
|
line
|
f
.
puts
(
line
)
unless
line
.
include?
(
'autoload'
)
end
end
f
.
puts
'Pod::Command.run(*ARGV)'
end
sh
"macrubyc concatenated.rb -o pod"
end
####
desc
"Compile the source files (as rbo files)"
task
:compile
do
Dir
.
glob
(
"lib/**/*.rb"
).
each
do
|
file
|
sh
"macrubyc
#{
file
}
-C -o
#{
file
}
o"
end
end
desc
"Remove rbo files"
task
:clean
do
sh
"rm -f lib/**/*.rbo"
sh
"rm -f lib/**/*.o"
sh
"rm -f *.gem"
end
namespace
:gem
do
namespace
:gem
do
def
gem_version
def
gem_version
require
File
.
join
(
File
.
dirname
(
__FILE__
),
*
%w[lib cocoapods]
)
require
File
.
join
(
File
.
dirname
(
__FILE__
),
*
%w[lib cocoapods]
)
...
@@ -56,7 +16,6 @@ namespace :gem do
...
@@ -56,7 +16,6 @@ namespace :gem do
desc
"Install a gem version of the current code"
desc
"Install a gem version of the current code"
task
:install
=>
:build
do
task
:install
=>
:build
do
sh
"sudo gem install
#{
gem_filename
}
"
sh
"sudo gem install
#{
gem_filename
}
"
#sh "sudo gem compile cocoapods"
end
end
desc
"Run all specs, build and install gem, commit version change, tag version change, and push everything"
desc
"Run all specs, build and install gem, commit version change, tag version change, and push everything"
...
@@ -108,16 +67,16 @@ namespace :spec do
...
@@ -108,16 +67,16 @@ namespace :spec do
end
end
desc
"Run the functional specs"
desc
"Run the functional specs"
task
:functional
do
task
:functional
=>
"ext:cleanbuild"
do
sh
"bacon spec/functional/*_spec.rb"
sh
"bacon spec/functional/*_spec.rb"
end
end
desc
"Run the integration spec"
desc
"Run the integration spec"
task
:integration
do
task
:integration
=>
"ext:cleanbuild"
do
sh
"bacon spec/integration_spec.rb"
sh
"bacon spec/integration_spec.rb"
end
end
task
:all
do
task
:all
=>
"ext:cleanbuild"
do
sh
"bacon spec/**/*_spec.rb"
sh
"bacon spec/**/*_spec.rb"
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