I'm trying to understand how I can accomplish a particular workflow.

First, some terms:

org:project-a:1.0-SNAPSHOT
org:project-b:1.0-SNAPSHOT
org.project-c:1.0-SNAPSHOT  DEPENDS_ON org.project-a:1.0-SNAPSHOT,
org.project-b:1.0-SNAPSHOT

Assume that we have a build server regularly building project-a and
project-b, and placing into an HTTP repository, like Artifactory.

Problem workflow:

User downloads project-b and project-c, but not project-a.  User fixes a bug
in project-b.  User does a 'mvn install' locally on both project-b and
project-c.    The user hasn't checked in anything yet to SCM.

For the time being, project-c should use project-b from the local repository
because it's the latest 1.0-SNAPSHOT, right?

Ok. Assume that now, the build server builds a new 1.0-SNAPSHOT of
project-b.  From the documentation I've read on maven, project-c will now
resolve against the latest version; which is in the remote repository.

This is problematic if you have actively changed project-b and were hoping
it to remain active while your working on it.  Your bug fix won't be in
effect because you are using the remote/build-server project-b, which
doesn't have your fix.

Also, I don't want to use mvn -o (offline), because if I haven't downloaded
project-a, and if there are changes, then I'd still like to get updates to
it as I'm working, per usual SNAPSHOT behavior.    Another way to put this:
I'm trying to solve this in a per-dependency way.

I have some ideas on how to solve this, none of which sound good to me, but
I first wanted to hear what anyone would suggest that I do, before I make
this post longer...

Thanks for any help,
Seth

--
View this message in context: 
http://maven.40175.n5.nabble.com/Preferring-local-repository-over-remote-for-work-sessions-tp5542872p5542872.html
Sent from the Maven - Users mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to