dice icon indicating copy to clipboard operation
dice copied to clipboard

adding px option for SET command

Open SyedMa3 opened this issue 1 year ago • 2 comments

  • Added support for the PX flag in the SET command.
  • Added unit and integration tests.
  • Refactored ParseCommand to reuse it in unit tests.

Fixes: Issue #200

SyedMa3 avatar Aug 04 '24 09:08 SyedMa3

@SyedMa3 There are some merge conflicts. Can you resolve them, I did skim your changes once. But will deep dive better after the conflicts are resolved.

arpitbbhayani avatar Aug 04 '24 19:08 arpitbbhayani

LGTM. cc @arpitbbhayani @JyotinderSingh do we need to add corresponding JSON support as part of this PR or do we have a separate PR for this?

@SyedMa3 Just one minor change for better readability. You may do a:

arg := strings.ToUpper(args[i])

This makes your code a little more readable: The related conditions are now reduced to:

case "EX", "PX":

and if arg == "EX" {

soumya-codes avatar Aug 05 '24 12:08 soumya-codes

There were some conflicts. I resolved them and merged the PR now.

Thanks @SyedMa3 and @soumya-codes!

arpitbbhayani avatar Aug 05 '24 18:08 arpitbbhayani