Module: Nephos::Bin

Defined in:
lib/nephos-server/bin-helpers.rb

Class Method Summary collapse

Class Method Details

.is_a_valid_application?(dir = ".") ⇒ Boolean

Returns:

  • (Boolean)


4
5
6
7
8
9
10
# File 'lib/nephos-server/bin-helpers.rb', line 4

def self.is_a_valid_application? dir="."
  return false if not Dir.exists? dir
  gfl = File.expand_path "Gemfile.lock", dir
  return false if not File.exists? gfl
  return false if not File.read(gfl).split.index("nephos-server")
  return true
end