vfox icon indicating copy to clipboard operation
vfox copied to clipboard

[Feature]: Automatically install SDKs

Open koppor opened this issue 1 year ago • 3 comments

1. Your usage scenarios?

I cd in a directory and I expect the JDK to be available.

2. What is your expected outcome?

vfox asking for JDK installation if not installed yet.


Examples that sdk is set if installed:

  • /tmp/x: 21
  • /tmp/y: 20
  • /c/git-repositories/jabref-all/javafxreproducer: last SDK, because 22 was not installed before.
$ cat /c/TEMP/x/.tool-versions
java 21.0.2+13

koppor@DESKTOP-KAK953S MINGW64 /c/TEMP/x (master)
$ java -version
openjdk version "21.0.2" 2024-01-16
OpenJDK Runtime Environment (build 21.0.2+13-58)
OpenJDK 64-Bit Server VM (build 21.0.2+13-58, mixed mode, sharing)

$ cat /c/TEMP/y/.tool-versions
java 20.0.2+9

koppor@DESKTOP-KAK953S MINGW64 /c/TEMP/y
$ java -version
openjdk version "20.0.2" 2023-07-18
OpenJDK Runtime Environment (build 20.0.2+9-78)
OpenJDK 64-Bit Server VM (build 20.0.2+9-78, mixed mode, sharing)

koppor@DESKTOP-KAK953S MINGW64 /c/git-repositories/jabref-all/javafxreproducer (add-textfield-mwe)
$ cat .tool-versions
java 22.0.1+8-tem

koppor@DESKTOP-KAK953S MINGW64 /c/git-repositories/jabref-all/javafxreproducer (add-textfield-mwe)
$ java -version
openjdk version "20.0.2" 2023-07-18
OpenJDK Runtime Environment (build 20.0.2+9-78)
OpenJDK 64-Bit Server VM (build 20.0.2+9-78, mixed mode, sharing)

koppor avatar Jul 07 '24 13:07 koppor

我也喜欢增加这个功能,这样就可以放到 CI 的脚本里面,在编译前自动安装并切换到所需要的依赖。我的 nodejs 项目,使用 volta 都是这样管理的。如果 vfox 能提供类似的功能就更好了。

devbean avatar Jul 23 '24 03:07 devbean

I do not know the maintainers' opinion on this, but I would like to see this option turned off by default. Or at least configurable

ZuBB avatar Oct 10 '24 14:10 ZuBB

I do not know the maintainers' opinion on this, but I would like to see this option turned off by default. Or at least configurable

For me vfox should ask interactively. This is what I meant with followign text

vfox asking for JDK installation if not installed yet.

koppor avatar Oct 16 '24 12:10 koppor