could not download Bazel: could not create directory
I use go to install bazelisk to install tensorflow
go get github.com/bazelbuild/bazelisk
the configue file in tensorflow said:
You have bazel 0.28.0 installed.
Please upgrade your bazel installation to version 3.1.0 or higher to build TensorFlow!
then I type bazelisk
it shows: 2020/11/09 18:13:22 could not download Bazel: could not create directory /home/dynacolor/.cache/bazelisk/downloads/bazelbuild/bazel-3.1.0-linux-x86_64/bin: mkdir /home/dynacolor/.cache/bazelisk/downloads/bazelbuild/bazel-3.1.0-linux-x86_64: permission denied
then I type sudo bazeklisk
sudo: bazelisk: command not found
what can I do now?
It is not about sudo permission. Try
chmod +x /home/dynacolor/.cache/bazelisk/downloads/bazelbuild/bazel-3.1.0-linux-x86_64and run it again. I think it is because you need to set executable permission of it.
I can't since it hasn't been created yet
Sorry I was not reading carefully. What I was trying to say was
chmod +x bazelisk
in the directory that you built bazelisk to make sure it has permission to execute.
If the above does not work, you might use
sudo -s bazelisk
to work around.
Closing due to age. Please re-open if the problem still persists.