Class: Linksta::CLI
- Inherits:
-
Thor
- Object
- Thor
- Linksta::CLI
- Includes:
- Thor::Actions
- Defined in:
- lib/linksta/cli.rb
Instance Method Summary collapse
- #check(url, base, reg, filename) ⇒ Object
- #scan(url, filename) ⇒ Object
- #smoke(file) ⇒ Object
- #status(url, base, reg, filename) ⇒ Object
Instance Method Details
#check(url, base, reg, filename) ⇒ Object
20 21 22 23 |
# File 'lib/linksta/cli.rb', line 20 def check(url, base, reg, filename) scan(url, filename) status(url, base, reg, filename) end |
#scan(url, filename) ⇒ Object
8 9 10 11 |
# File 'lib/linksta/cli.rb', line 8 def scan(url, filename) html = Linksta::SaveLinks.new(url, filename) html.capture_links end |
#smoke(file) ⇒ Object
26 27 28 29 |
# File 'lib/linksta/cli.rb', line 26 def smoke(file) check = Linksta::Checker.new(file) check.smoke end |
#status(url, base, reg, filename) ⇒ Object
14 15 16 17 |
# File 'lib/linksta/cli.rb', line 14 def status(url, base, reg, filename) status = Linksta::CheckResponse.new(url, base, reg, filename) status.check_links end |