fix: generate bin directory first

This commit is contained in:
Daylin Morgan 2024-01-02 12:22:47 -06:00
parent 96eb08af6a
commit 5c769fc905
Signed by: daylin
GPG key ID: C1E52E7DD81DF79F

View file

@ -1724,9 +1724,9 @@ class Viv:
f"Write shim for {a.bold}{bin}{a.end} to {a.green}{output}{a.end}?", f"Write shim for {a.bold}{bin}{a.end} to {a.green}{output}{a.end}?",
yes=yes, yes=yes,
): ):
output.parent.mkdir(exist_ok=True, parents=True)
with output.open("w") as f: with output.open("w") as f:
f.write(self.t.shim(path, self.local_source, standalone, spec, bin)) f.write(self.t.shim(path, self.local_source, standalone, spec, bin))
make_executable(output) make_executable(output)
@staticmethod @staticmethod