Closed Celeo closed 4 years ago
All great catches!
The output now looks like:
This failure is a problem with github action's caching that I can't figure out. It fails randomly with this specific error, and I have no idea why, but if I expire the cache, it gets fixed. I'll take care of it, since I have to squash and sign the commit anyways.
Okay copy that. The first couple were definitely on me, but that Mac build failure definitely had me stumped.
I added an env.CACHE_KEY_PREFIX
key to the github actions config, whose value is just an integer, now 2
. It's used as a prefix on the cache keys, so incrementing it will clear the caches. If you run into this error again, you can just increment the number in there and it should fix it. However! I then read that other people are having the same issues, so I added yet another hacky attempt at a workaround, installing GNU Tar, because apparently there's a bug in BSD Tar that's causing the issues. Hopefully that actually fixes it, and incrementing the cache prefix isn't necessary.
When I squished I also made a couple changes that I didn't notice during review. Tiny things, but they're nice rustisms to know about:
Instead of format!("{}", some_value)
, where some_value
is a type that implements Display
, you can just do some_value.to_string()
. All types that implement Display
get a ToString
impl for free.
I changed a couple of unwrap_or
instances to unwrap_or_default
, which returns the default value (false
for integers, the empty vec for vectors, etc) if the Option or Result is None or Err.
There's an outln!
macro (specific to intermodal) that handles printing output to stdout, so you don't need to do write!(&mut env.out, ...
.
Thanks for the PR! This is a very nice addition. I'm going to cut a release, probably tonight or tomorrow, so that the published version of imdl
has the feature.
Just cut v0.1.12!
https://github.com/casey/intermodal/issues/465