Skip to content

Instantly share code, notes, and snippets.

@jbd
Created March 16, 2017 16:21
Show Gist options
  • Select an option

  • Save jbd/58f583d48a261c026b31b79bf94a5e71 to your computer and use it in GitHub Desktop.

Select an option

Save jbd/58f583d48a261c026b31b79bf94a5e71 to your computer and use it in GitHub Desktop.
tensorflow bazel cache patch
#!/bin/bash
# once the configure is done, you have to patch your bazel cache...
BAZEL_CACHE=${HOME}/.cache/bazel
if [ ! -d "$BAZEL_CACHE" ]
then
echo "No $BAZEL_CACHE to look for. Weird."
exit 1
fi
for i in $(find $BAZEL_CACHE -name protobuf.bzl)
do
echo "Patching $i"
sed -i 's/mnemonic=\"ProtoCompile\".*,/mnemonic=\"ProtoCompile\", use_default_shell_env=True,/g' "${i}"
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment