Todo_Marker/bin/todo_marker

21 lines
377 B
Plaintext
Raw Normal View History

2024-06-14 23:00:56 -06:00
# frozen_string_literal: true
2024-06-14 22:59:20 -06:00
# bin/todo_marker
2024-06-14 23:00:56 -06:00
# !/usr/bin/env ruby
2024-06-14 22:59:20 -06:00
2024-06-14 23:00:56 -06:00
require 'todo_marker'
2024-06-14 22:59:20 -06:00
if ARGV.empty?
2024-06-14 23:00:56 -06:00
puts 'Usage: todo_marker <directory>'
2024-06-14 22:59:20 -06:00
exit 1
end
directory = ARGV[0]
unless Dir.exist?(directory)
puts "Directory #{directory} does not exist"
exit 1
end
TodoMarker.generate_todo_md(directory)
puts "TODO.md has been generated in the #{directory} directory."