]> git.r.bdr.sh - rbdr/lyricli.rb/blobdiff - bin/lrc
Change error names to favor convention
[rbdr/lyricli.rb] / bin / lrc
diff --git a/bin/lrc b/bin/lrc
index 7bb26999cee3aeda4ea4b88323a31858458e798a..b1a44b625e45d182bdb8e1a020d34178e7775ff3 100755 (executable)
--- a/bin/lrc
+++ b/bin/lrc
@@ -15,7 +15,8 @@ Options:
 }
 
     opts.on("-e", "--enable SOURCE", "Enable SOURCE") do |source|
 }
 
     opts.on("-e", "--enable SOURCE", "Enable SOURCE") do |source|
-      puts "Enabling sources is not yet implemented"
+      Lyricli.enable(source)
+      puts "#{source} has been enabled"
       exit
     end
 
       exit
     end
 
@@ -25,12 +26,14 @@ Options:
     end
 
     opts.on("-d", "--disable SOURCE", "Disable SOURCE") do |source|
     end
 
     opts.on("-d", "--disable SOURCE", "Disable SOURCE") do |source|
-      puts "Disabling sources is not yet implemented"
+      Lyricli.disable(source)
+      puts "#{source} has been disabled"
       exit
     end
 
     opts.on("-r", "--reset SOURCE", "Reset the configuration of SOURCE") do |source|
       exit
     end
 
     opts.on("-r", "--reset SOURCE", "Reset the configuration of SOURCE") do |source|
-      puts "Resetting sources is not yet implemented"
+      Lyricli.reset(source)
+      puts "#{source} has been disabled and all its configuration reset"
       exit
     end
 
       exit
     end