Closed gounthar closed 4 months ago
As said in this comment, I am not sure which place would be opt to create dir, any suggestions?
The place you chose is not bad, but it does not allow us to use the tool. 🤷 I think we should add a test about this cache directory creation that would prevent to merge to the main branch code that does not work.
It's possible to override the cache dire via CLI or env vars to point to a writable location.
We can set it on the gitpod environnement
On Wed, 17 Jul 2024, 08:14 Bruno Verachten, @.***> wrote:
The place you chose is not bad, but it does not allow us to use the tool. 🤷 I think we should add a test about this cache directory creation that would prevent to merge to the main branch code that does not work.
— Reply to this email directly, view it on GitHub https://github.com/jenkinsci/plugin-modernizer-tool/issues/99#issuecomment-2232509734, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAGJTFTLTDZ4BMFPPIAL7X3ZMYDV5AVCNFSM6AAAAABK75I7LGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMZSGUYDSNZTGQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>
See --cache-path
option
java -jar plugin-modernizer-cli/target/jenkins-plugin-modernizer-999999-SNAPSHOT.jar --dry-run --plugin-file plugins.txt --recipes AddPluginsBom,AddCodeOwner --cache-path /tmp
works, but the tool should try to create the path if it does not exist, and fail if it can't use it before even trying to use the path to store files.
java -jar plugin-modernizer-cli/target/jenkins-plugin-modernizer-999999-SNAPSHOT.jar --dry-run --plugin-file plugins.txt --recipes AddPluginsBom,AddCodeOwner --cache-path /tmp works, but the tool should try to create the path if it does not exist, and fail if it can't use it before even trying to use the path to store files.
your right! merging #100 should resolve this issue.
Jenkins and plugins versions report
What Operating System are you using (both controller, and any agents involved in the problem)?
GitPod
Reproduction steps
java -jar plugin-modernizer-cli/target/jenkins-plugin-modernizer-999999-SNAPSHOT.jar --dry-run --plugin-file plugins.txt --recipes AddPluginsBom,AddCodeOwner
Expected Results
I thought that with the merge of #87 we would be good with the
--plugin-file
option.Actual Results
java.io.UncheckedIOException: java.nio.file.NoSuchFileException: /home/gitpod/.cache/jenkins-plugin-modernizer-cli/update-center.json
Anything else?
No response
Are you interested in contributing a fix?
No response