robertdfrench / git-pr

Pull requests without Git(Hub|Lab)
GNU General Public License v3.0
0 stars 1 forks source link

Prefer String over Path/OsString #11

Closed robertdfrench closed 3 years ago

robertdfrench commented 3 years ago

We don't need Path anymore, because @calebwherry found that we don't need the Path construction stuff that I assumed we needed on Windows. I also didn't realize that String implements a trait called AsRef<OsStr>, meaning that it can be passed as a reference to std::process::Command::new. So that will bring the number of string types in this code from 3 down to 1!

_Originally posted by @robertdfrench in https://github.com/robertdfrench/git-pr/pull/1#discussion_r725710107_

robertdfrench commented 3 years ago