Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
annotate
Project
Overview
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
open-source
annotate
Commits
d54e772a
Commit
d54e772a
authored
May 26, 2014
by
cuong.tran
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Display an error message if not run from the root of the project, #186
parent
d84a9736
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
annotate
bin/annotate
+6
-2
No files found.
bin/annotate
View file @
d54e772a
#!/usr/bin/env ruby
#!/usr/bin/env ruby
unless
File
.
exists?
(
'./Rakefile'
)
||
File
.
exists?
(
'./Gemfile'
)
abort
"Please run annotate from the root of the project."
end
require
'rubygems'
require
'rubygems'
begin
begin
require
'bundler'
require
'bundler'
...
@@ -146,7 +151,6 @@ OptionParser.new do |opts|
...
@@ -146,7 +151,6 @@ OptionParser.new do |opts|
end
.
parse!
end
.
parse!
options
=
Annotate
.
setup_options
({
:is_rake
=>
ENV
[
'is_rake'
]
&&
!
ENV
[
'is_rake'
].
empty?
})
options
=
Annotate
.
setup_options
({
:is_rake
=>
!
ENV
[
'is_rake'
].
blank?
})
Annotate
.
eager_load
(
options
)
Annotate
.
eager_load
(
options
)
target
[
:klass
].
send
(
target
[
:task
],
options
)
target
[
:klass
].
send
(
target
[
:task
],
options
)
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