aspect-cli
aspect-cli copied to clipboard
[Bug]: Set `BAZELISK_HOME` to `~/.bazeliskrc` or existance of that dir makes CLI errors and exit
What happened?
I still may need to re-reproduce and confirm my findings but I'm already sharing it anyway. I'll update this issue accordingly.
The error I'm currently getting:
Standalone Aspect CLI
$ aspect
2024/07/03 01:54:22 read /home/alberto/.bazeliskrc: is a directory
Bazelisk
$ bazelisk help init
2024/07/03 01:58:14 read /home/alberto/.bazeliskrc: is a directory
Version
Development (host) and target OS/architectures: linux_x86_amd4 (WSL2)
Output of bazel --version: Errors out
Version of the Aspect rules, or other relevant rules from your
WORKSPACE or MODULE.bazel file: None
Language(s) and/or frameworks involved: None
How to reproduce
touch WORKSPACE
echo 7.2.1 > .bazelversion
cat > .bazeliskrc << EOF
BAZELISK_HOME=~/.bazeliskrc # EDIT: was supposed to be .bazelisk
BAZELISK_BASE_URL=https://github.com/aspect-build/aspect-cli/releases/download
USE_BAZEL_VERSION=aspect/5.10.1
EOF
Then:
`bazelisk init`
`bazelisk help init`
and from now on:
`aspect` also fails.
Any other information?
(Note: I'm using a fork of bazelisk which carries these changes only: https://github.com/bazelbuild/bazelisk/pull/587, to reproduce it you can change ~ with the actual homedir path).