FMCorz / mdk

Moodle Development Kit. A collection of tools meant to make developers' lives easier.
GNU General Public License v3.0
85 stars 47 forks source link

Make mdk pull offer to pull patches when remote ref incorrect #89

Closed danpoltawski closed 10 years ago

danpoltawski commented 10 years ago

Would be great if MDK would offer ability to pull patches in this situation:

$ mdk pull MDL-6698
Retrieving information about MDL-6698 from Moodle Tracker
FetchException: The ref to fetch is unknown

Actually, I don't know if you do url validation too, but that would be nice while i'm suggesting things too, cos people often put silly things in here.

FMCorz commented 10 years ago

I do not validate the information, but you can pass --prompt to force the patch download. Not sure if I should be validating the data, the branch name could be wrong too, and I cannot do much to prevent that.

danpoltawski commented 10 years ago

My suggestion wasn't to validate the input but to fall back to prompt when the fetch fails. But I wasn't aware of --prompt before and I suppose it is good enough for this bug and can imagine that you wouldn't want pull to be to magic.