# File lib/buildr/core/project.rb, line 427
    def base_dir
      if @base_dir.nil?
        if parent
          # For sub-project, a good default is a directory in the parent's base_dir,
          # using the same name as the project.
          @base_dir = File.expand_path(name.split(':').last, parent.base_dir)
        else
          # For top-level project, a good default is the directory where we found the Buildfile.
          @base_dir = Dir.pwd
        end
      end
      @base_dir
    end