grunt.rb 805 B

12345678910111213141516171819202122232425262728293031323334
  1. module Docs
  2. class Grunt < UrlScraper
  3. self.name = 'Grunt'
  4. self.type = 'simple'
  5. self.release = '1.0.1'
  6. self.base_url = 'https://gruntjs.com/'
  7. self.root_path = 'getting-started'
  8. self.initial_paths = %w(api/grunt)
  9. html_filters.push 'grunt/clean_html', 'grunt/entries'
  10. options[:only] = %w(
  11. configuring-tasks
  12. sample-gruntfile
  13. creating-tasks
  14. creating-plugins
  15. using-the-cli
  16. installing-grunt
  17. project-scaffolding
  18. )
  19. options[:only_patterns] = [/\Aapi\//, /\Aupgrading-/]
  20. options[:container] = '.container > .row-fluid'
  21. options[:attribution] = <<-HTML
  22. &copy; GruntJS Team<br>
  23. Licensed under the MIT License.
  24. HTML
  25. def get_latest_version(opts)
  26. get_npm_version('grunt-cli', opts)
  27. end
  28. end
  29. end