Sha256: ff814250ca9620ad45bcc9364b1346cf11024a9e2453eede738a7a28cfe06388

Contents?: true

Size: 735 Bytes

Versions: 6

Compression:

Stored size: 735 Bytes

Contents

# encoding: utf-8
require 'formatafacil/tarefa'


module Formatafacil
  class Template
  
    attr_accessor 'modelos'
    # Derectory of templates
    attr_accessor 'directory'
    
    def initialize()
      @modelos = {}

      # ler os templates do projeto formatafacil-templates
      $LOAD_PATH.each { |dir|  
        files = Dir["#{dir}/formatafacil/templates/*.latex"]
        files.each { |file| 
          if file
            @modelos[File.basename(file, '.tex')] = file
            @directory = "#{dir}/formatafacil"
          end
        }
      }

    end
    
    def executa
    end
      
    # $LOAD_PATH.each { |dir|  ... look for resources relative to dir ... }
    def list
      modelos.keys
    end
  end
    
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
formatafacil-0.1.6 lib/formatafacil/template.rb
formatafacil-0.1.5 lib/formatafacil/template.rb
formatafacil-0.1.4 lib/formatafacil/template.rb
formatafacil-0.1.3 lib/formatafacil/template.rb
formatafacil-0.1.2 lib/formatafacil/template.rb
formatafacil-0.1.1 lib/formatafacil/template.rb