Maven, SBT and GitHub/SSH repos

624 views
Skip to first unread message

Dominic Williams

unread,
Nov 15, 2013, 7:16:08 PM11/15/13
to maven-a...@googlegroups.com

I have been using a private GitHub repo for storing company-wide dependencies...

Using SBT I was able to connect by adding one line to build.sbt:

resolvers += Resolver.ssh("Company Maven Repo", "git@github.com:company/company-repo.git", "/raw/master")

SBT actually pops up with a username/password dialog box so can use my keys etc. This is hugely advantageous, since anyone who already has their machine setup to access GitHub and has been granted access to the repo can access the dependencies. If their access to the repo is removed, then they can't access the dependencies anymore even though they still have access to other repos on GitHub etc. Highly secure, hassle free...

Question: how can Maven be made to do this?

David Bernard

unread,
Nov 16, 2013, 4:42:07 AM11/16/13
to Maven and Scala
Hi,

Disclaimer "Not tested !!" (I often use artifactory or nexus for company repository)

Have you try to use define the repository via the github url "https://raw.github.com/company/company-repo/master" and set user/password into $HOME/.m2/settings.xml



--
 
---
You received this message because you are subscribed to the Google Groups "Maven and Scala" group.
To unsubscribe from this group and stop receiving emails from it, send an email to maven-and-sca...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Matthias Kurz

unread,
Jan 22, 2016, 10:57:29 AM1/22/16
to Maven and Scala
Dominic Williams 
and/or
David Bernard 

did you find a working solution?
How did you solve this?

Thanks a lot!
Reply all
Reply to author
Forward
0 new messages