Page MenuHomePhabricator

Make `bin/lipsum generate` hanldle generator keys and arguments more clearly
ClosedPublic

Authored by epriestley on Feb 27 2017, 12:20 PM.

Details

Summary

Ref T12319. Currently, bin/lipsum uses substring matches against human-readable text to chose which objects to generate.

Instead:

  • Use separate selector keys which are guaranteed to be unique.
  • When a match is exact, select only that generator.
  • When a match is ambiguous, fail and warn the user.
Test Plan

Generated several types of objects, tried to generate ambiguous objects like "e".

Diff Detail

Repository
rP Phabricator
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.