Say which configuration jf setup changed and how widely it applies - #521
Say which configuration jf setup changed and how widely it applies#521sverdlov93 wants to merge 1 commit into
Conversation
jf setup writes user-level package manager configuration, so a run in one project silently changes resolution for every other project the user builds. The only output was "Successfully configured <pm> to use JFrog repository '<repo>'", which says nothing about the file that changed or its scope, so unrelated builds could start resolving elsewhere with nothing to trace it back to. Add a note naming the configuration and stating that it applies beyond the current directory. Container logins get a credentials-only wording, since docker/podman/helm authenticate rather than redirect resolution and an unqualified 'docker pull alpine' still reaches Docker Hub. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughSetup now generates package-manager-specific user-scope notes and prints them after successful configuration. Tests cover supported managers, container login behavior, and silent handling of unsupported managers. ChangesSetup configuration scope notes
Estimated code review effort: 2 (Simple) | ~10 minutes Sequence Diagram(s)sequenceDiagram
participant SetupCommand
participant configScopeNote
participant log.Output
SetupCommand->>configScopeNote: package manager
configScopeNote-->>SetupCommand: optional scope note
SetupCommand->>log.Output: note when non-empty
Possibly related PRs
Suggested labels: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches 💡 1🛠️ Fix failing CI checks 💡
📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Companion help-text change: jfrog/jfrog-cli#3627 — states the same scope in Worth noting |
|
Folded into #520 so both The commit is carried over there unchanged, plus a review fix on top: the scope note claimed user-level scope unconditionally, but Nothing is lost by closing this; #520 is the single PR to review. |
Overview
jf setupwrites user-level package manager configuration, so a run inside one project silently changes dependency resolution for every other project that user builds. The only output was:That says nothing about which file changed or how far the change reaches. When an unrelated project later fails to resolve, the error comes from the package manager itself and names only the missing artifact — there is nothing to connect it back to a
jf setuprun in a different directory. This came out of a report where configuring Maven against a demo repository broke a different project that resolved against another Artifactory, with no warning that the two were linked.Details
Adds a line after the success message naming the configuration that changed and stating that it applies beyond the current directory:
Container logins are worded differently on purpose.
docker,podmanandhelmauthenticate to the platform rather than redirecting resolution — afterjf setup docker, an unqualifieddocker pull alpinestill goes to Docker Hub — so claiming their projects now resolve through Artifactory would be wrong:A package manager with no entry prints nothing rather than something vague.
Notes
jfrog-cliadds the same scope statement tojf setup --help, so the behaviour is discoverable before running the command as well as after.TestSetupCommand_Pnpmfails on this machine both with and without this change (pnpm 11.17.0) — pre-existing and unrelated; every other test in the package passes.Summary by CodeRabbit