Module: Gitlab::RobotsTxt
- Defined in:
- lib/gitlab/robots_txt.rb,
lib/gitlab/robots_txt/parser.rb
Defined Under Namespace
Classes: Parser
Class Method Summary collapse
Class Method Details
.disallowed?(path) ⇒ Boolean
5 6 7 |
# File 'lib/gitlab/robots_txt.rb', line 5 def self.disallowed?(path) parsed_robots_txt.disallowed?(path) end |
.parsed_robots_txt ⇒ Object
9 10 11 |
# File 'lib/gitlab/robots_txt.rb', line 9 def self.parsed_robots_txt @parsed_robots_txt ||= Parser.new(robots_txt) end |
.robots_txt ⇒ Object
13 14 15 |
# File 'lib/gitlab/robots_txt.rb', line 13 def self.robots_txt File.read(Rails.root.join('public', 'robots.txt')) end |