require 'parslet' module Shift module Parser include Parslet rule(:read_keyword) { str('read') } rule(:all_keyword) { str('all') } rule(:new_keyword) { str('new') } rule(:find_keyword) { str('find') } rule(:where_keyword) { str('where') } rule(:find_by_id_keyword) { str('find_by_id') } rule(:update_keyword) { str('update') } rule(:delete_keyword) { str('delete') } rule(:write_keyword) { str('write') } rule(:write_file_keyword) { str('write_file') } rule(:redirect_keyword) { str('redirect') } rule(:if_keyword) { str('if') } rule(:else_keyword) { str('else') } rule(:for_keyword) { str('for') } rule(:in_keyword) { str('in') } rule(:while_keyword) { str('while') } rule(:get_keyword) { str('get') } rule(:post_keyword) { str('post') } rule(:model_keyword) { str('model') } rule(:string_keyword) { str('string') } rule(:integer_keyword) { str('integer') } rule(:integer_cast_keyword) { str('int') } end end