diff options
Diffstat (limited to 'lib/osugiru/ruleset.rb')
-rw-r--r-- | lib/osugiru/ruleset.rb | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/osugiru/ruleset.rb b/lib/osugiru/ruleset.rb new file mode 100644 index 0000000..a9bac16 --- /dev/null +++ b/lib/osugiru/ruleset.rb @@ -0,0 +1,11 @@ +module Osugiru + RuleSet = Struct.new(:name, :rule) do + def messages + Messages.new(db: Osugiru.db) + end + + def run + instance_eval(&rule) + end + end +end |