CLI doesn't download empty stubs

This issue was surfaced in Empty solution files, but exercism download --track=<track> --exercise=<exercise> doesn’t download an empty stub file, forcing students to create it before they can work on the exercise. Some tracks may provide blank stubs on purpose so we shouldn’t assume an empty stub is a mistake.

Alternatively, we could keep this behavior as-is and suggest maintainers who want an empty stub file to add an explanatory comment to that file. Then the file won’t be strictly empty and can be downloaded properly.

2 Likes

I can’t think of a good reason to have a completely empty stub file (but maybe that’s a failure of imagination?). +1 for demanding at least a comment.

2 Likes

Related issue at Newsletter exercise: `assets/empty.txt` file not being created where an intentionally empty file used in the test suite isn’t being downloaded locally.

I don’t think we should ever have empty stubs, but I do think .keep should exist so an exercise can come with a file tree strucutre (without files) and perhaps empty.ext should exist so a test suite can have an empty file to test against.

…so I do think a CLI change should be made :smiley:

2 Likes

@SleeplessByte download empty by IsaacG · Pull Request #1213 · exercism/cli · GitHub (from Newsletter exercise: `assets/empty.txt` file not being created - #3 by angelikatyborska)

2 Likes

Approved. Merge whenever you want. I think you did a few CLI releases thusfar, so you know how that process works right?

Thanks!

Roughly. There’s a doc in that repo with the steps which, if you pay attention and actually follow it, is fairly straight forward. Though IIRC there’s a new to manually bump Brew somehow.

2 Likes