276 is not quite fixed, because if you clone the ProjectScaffold repo by copying the URL from your browser (in which case its remote will be https://github.com/fsprojects/ProjectScaffold) then it won't be matched by the regex in init.fsx and the git history won't be cleared.
Repro steps
Please provide the steps required to reproduce the problem
The best fix, IMHO, is to add (\.git)? to the remote-matching regex so that it will also match if someone clones the repo from a remote without the .git extension.
Description
276 is not quite fixed, because if you clone the ProjectScaffold repo by copying the URL from your browser (in which case its remote will be
https://github.com/fsprojects/ProjectScaffold
) then it won't be matched by the regex ininit.fsx
and the git history won't be cleared.Repro steps
Please provide the steps required to reproduce the problem
./build.sh
Solution
The best fix, IMHO, is to add
(\.git)?
to the remote-matching regex so that it will also match if someone clones the repo from a remote without the .git extension.Note that @jackfoxy's comment at https://github.com/fsprojects/ProjectScaffold/issues/276#issuecomment-345783002 should also be considered; i.e., what do we do when there's no remote?