mirror of
https://github.com/bower/bower.git
synced 2026-04-24 03:00:19 -04:00
Minor tweaks.
This commit is contained in:
@@ -6,18 +6,19 @@ var UrlResolver = require('./resolvers/UrlResolver');
|
||||
|
||||
function createResolver(endpoint, options) {
|
||||
var split = endpoint.split('#'),
|
||||
source,
|
||||
target;
|
||||
|
||||
// Extract the range from the endpoint
|
||||
endpoint = split[0];
|
||||
// Extract the source and target from the endpoint
|
||||
source = split[0];
|
||||
target = split[1];
|
||||
|
||||
// Ensure options
|
||||
options = options || {};
|
||||
options.target = options.target || target;
|
||||
|
||||
// TODO: analyze endpoint and create appropriate package
|
||||
return Q.fcall(new GitRemoteResolver(endpoint, options));
|
||||
// TODO: analyze source and create appropriate package
|
||||
return Q.fcall(new GitRemoteResolver(source, options));
|
||||
}
|
||||
|
||||
module.exports = createResolver;
|
||||
Reference in New Issue
Block a user