Comments (6)
@email2vimalraj Just use:
var opts = {
repositories: [
{
id: "<id></id>",
url: "<url>Modified ! See below</url>"
}
]};
mvn(opts, function(err, mvnResults) {
//Callback after fetching from the protected repo.
});
For HTTP Authentication modify the url as ^^ https://user:[email protected]/repo
But this issue can't be closed yet, as we still need complete documentation. :)
Being dumb, burnt time looking at alternate solutions for resolving dependencies thinking that I would need to do a hack. Some good time with the code and documentation of the modules it uses, was easy to figure out. I would be happy to do some documentation as I find time...
from node-java-maven.
Are you doing something like this in your settings.xml
or is it more complex?
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0
http://maven.apache.org/xsd/settings-1.0.0.xsd">
...
<mirrors>
<mirror>
<id>planetmirror.com</id>
<name>PlanetMirror Australia</name>
<url>http://downloads.planetmirror.com/pub/maven2</url>
<mirrorOf>central</mirrorOf>
</mirror>
</mirrors>
...
</settings>
from node-java-maven.
Sorry for delay in response. My settings.xml
look like this:
<?xml version="1.0" encoding="UTF-8"?>
<settings xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.1.0 http://maven.apache.org/xsd/settings-1.1.0.xsd" xmlns="http://maven.apache.org/SETTINGS/1.1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<servers>
<server>
<username>myusername</username>
<password>encrypted password</password>
<id>central</id>
</server>
<server>
<username>myusername</username>
<password>encrypted password</password>
<id>snapshots</id>
</server>
</servers>
<profiles>
<profile>
<repositories>
<repository>
<snapshots>
<enabled>false</enabled>
</snapshots>
<id>central</id>
<name>repo</name>
<url>http://mymvnartifactory.com/repo</url>
</repository>
<repository>
<snapshots />
<id>snapshots</id>
<name>repo</name>
<url>http://mymvnartifactory.com/repo</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<snapshots>
<enabled>false</enabled>
</snapshots>
<id>central</id>
<name>repo</name>
<url>http://mymvnartifactory.com/repo</url>
</pluginRepository>
<pluginRepository>
<snapshots />
<id>snapshots</id>
<name>repo</name>
<url>http://mymvnartifactory.com/repo</url>
</pluginRepository>
</pluginRepositories>
<id>artifactory</id>
</profile>
</profiles>
<activeProfiles>
<activeProfile>artifactory</activeProfile>
</activeProfiles>
</settings>
from node-java-maven.
Any updates on this?
from node-java-maven.
Sorry, I haven't had a chance to look into this issue.
from node-java-maven.
@pratikdmehta don't forget to add a trailing slash to the url
. It doesn't call join to combine the paths.
from node-java-maven.
Related Issues (20)
- Error: Could not resolve unknowns: javax.inject:javax.inject:null HOT 1
- Property substitution does not always work
- Error on run. HOT 1
- can you add “exclusion” feature?
- 0.0.11 regression HOT 1
- Can't fetch dependency if pom.xml for that dependency does not have a parent dependency HOT 2
- Support for dependency object passing instead of package.json
- Usage example is hard to understand
- Publish current version HOT 1
- Error: Could not resolve property: project.parent.groupId HOT 4
- localRepository and debug should be configurable via package.json
- Error: Could not resolve unknowns: javax.inject:javax.inject:null
- Error: Could not resolve property: compat.module
- Usage example details required.
- Cannot pull timestamped SNAPSHOT dependencies from remote Nexus repo
- Issues with integration in Cypress HOT 1
- Could not resolve property: project.parent.version HOT 5
- Error when using version ranges HOT 1
- Multiple matches found in dependency management error HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from node-java-maven.