Sha256: 874ea583284a2f365ff0504dd330c3c2efbe7613593af2f1f07803b2e50348f3

Contents?: true

Size: 423 Bytes

Versions: 39

Compression:

Stored size: 423 Bytes

Contents

module Generator
  class Gogogosu
    
    def initialize
      @basedir = Dir.pwd
    end
    
    # Generates a directory.
    #
    def dir name
      Dir.mkdir name unless File.file?(name) || File.exist?(name)
      if block_given?
        Dir.chdir name
        yield
        Dir.chdir '..'
      end
    end
    
    # Generates a file. Will be rendered with erb.
    #
    def file name
      
    end
    
  end
end

Version data entries

39 entries across 39 versions & 1 rubygems

Version Path
gosu_extensions-0.1.27 generator/gogogosu.rb
gosu_extensions-0.1.26 generator/gogogosu.rb
gosu_extensions-0.1.25 generator/gogogosu.rb
gosu_extensions-0.1.24 generator/gogogosu.rb
gosu_extensions-0.1.23 generator/gogogosu.rb
gosu_extensions-0.1.22 generator/gogogosu.rb
gosu_extensions-0.1.21 generator/gogogosu.rb
gosu_extensions-0.1.20 generator/gogogosu.rb
gosu_extensions-0.1.19 generator/gogogosu.rb
gosu_extensions-0.1.18 generator/gogogosu.rb
gosu_extensions-0.1.17 generator/gogogosu.rb
gosu_extensions-0.1.16 generator/gogogosu.rb
gosu_extensions-0.1.15 generator/gogogosu.rb
gosu_extensions-0.1.14 generator/gogogosu.rb
gosu_extensions-0.1.13 generator/gogogosu.rb
gosu_extensions-0.1.12 generator/gogogosu.rb
gosu_extensions-0.1.11 generator/gogogosu.rb
gosu_extensions-0.1.10 generator/gogogosu.rb
gosu_extensions-0.1.9 generator/gogogosu.rb