Class: GitPunch::Project
- Inherits:
-
Object
show all
- Defined in:
- lib/git_punch/project.rb
Constant Summary
collapse
- EXTENSIONS =
{
logic: "*.logic",
live: "*.als"
}
Class Method Summary
collapse
Instance Method Summary
collapse
Constructor Details
#initialize(with_root_directory) ⇒ Project
Returns a new instance of Project.
9
10
11
|
# File 'lib/git_punch/project.rb', line 9
def initialize with_root_directory
@root = with_root_directory
end
|
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(name, *args) ⇒ Object
22
23
24
25
26
27
28
|
# File 'lib/git_punch/project.rb', line 22
def method_missing name, *args
if "#{name}" =~ /\?$/
is_project? "#{name}".gsub(/\?/, '').to_sym
else
super name, args
end
end
|
Class Method Details
.detect! ⇒ Object
13
14
15
|
# File 'lib/git_punch/project.rb', line 13
def self.detect!
new in_current_directory
end
|
Instance Method Details
#has_guard_installed? ⇒ Boolean
17
18
19
|
# File 'lib/git_punch/project.rb', line 17
def has_guard_installed?
not guard_command.nil?
end
|