Sha256: 8d1274ecc3938994a3efafcbc5557628a7c3ebbf303017d0be344dd22815a0b3

Contents?: true

Size: 434 Bytes

Versions: 17

Compression:

Stored size: 434 Bytes

Contents

# see http://www.robotstxt.org/robotstxt.html

module Mill

  class Resource

    class Robots < Resource

      def build
        info = {}
        info['User-Agent'] = '*'
        info['Disallow'] = '/' unless @site.allow_robots
        info['Sitemap'] = @site.sitemap_resource.absolute_uri if @site.make_sitemap
        @content = info.map { |key, value| "#{key}: #{value}" }.join("\n")
        super
      end

    end

  end

end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
mill-0.16 lib/mill/resources/robots.rb
mill-0.11 lib/mill/resources/robots.rb
mill-0.10 lib/mill/resources/robots.rb
mill-0.9.1 lib/mill/resources/robots.rb
mill-0.9 lib/mill/resources/robots.rb
mill-0.8.4 lib/mill/resources/robots.rb
mill-0.8.3 lib/mill/resources/robots.rb
mill-0.8.2 lib/mill/resources/robots.rb
mill-0.8 lib/mill/resources/robots.rb
mill-0.7.3 lib/mill/resources/robots.rb
mill-0.7.2 lib/mill/resources/robots.rb
mill-0.7.1 lib/mill/resources/robots.rb
mill-0.6 lib/mill/resources/robots.rb
mill-0.5.1 lib/mill/resources/robots.rb
mill-0.5 lib/mill/resources/robots.rb
mill-0.4 lib/mill/resources/robots.rb
mill-0.3 lib/mill/resources/robots.rb