Skip to content

Simplify user interaction when handling user input in new_post.rb #18

@donovanglover

Description

@donovanglover

The end-user shouldn't and doesn't want to read such a long description of his or her every action.

Instead, the program should assume that:

  • Whatever the user enters is final.
    • This means that there should be no "confirmation message".
    • There should be no repetition of what the user has already typed.
  • The input should be intuitive. Use the print method instead of the puts method, and make sure to use colons followed by a space before gets.chomp.
  • Assume the default metadata. Using new_post.rb should be simple and the user should not have to change the default settings.
    • If the user does want to change the default settings, then he or she is not part of the target audience of new_post.rb, as he or she would already comprehend the actions needed to accomplish such task.

Finally, remove the gatekeeper. The user should not have to enter "confirm" to confirm something. They can, however, press enter or press Ctrl+C simultaneously as you describe.

If the user ever needs help, you can get the command line arguments in ruby and check if he or she has appended a help argument such as -h or --help. Any program with no parameters should by default attempt to solve the problem in the simplest manner.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions