mirror of
https://github.com/meteor/meteor.git
synced 2026-05-02 03:01:46 -04:00
fixing version in publishing
This commit is contained in:
@@ -11,10 +11,10 @@ PackageVersion.parseVersionConstraint = function (versionString) {
|
||||
return versionDesc;
|
||||
}
|
||||
|
||||
if (versionString.charAt(0) === '=') {
|
||||
/* if (versionString.charAt(0) === '=') {
|
||||
versionDesc.exact = true;
|
||||
versionString = versionString.substr(1);
|
||||
}
|
||||
} */
|
||||
|
||||
// XXX check for a dash in the version in case of foo@1.2.3-rc0
|
||||
|
||||
|
||||
@@ -551,7 +551,7 @@ main.registerCommand({
|
||||
|
||||
|
||||
var getVersionFromVersionConstraint = function(constraint) {
|
||||
if (constraint[0] === "=") {
|
||||
if (constraint && constraint[0] === "=") {
|
||||
return constraint.split("=")[1];
|
||||
}
|
||||
return constraint;
|
||||
@@ -609,6 +609,7 @@ constraint.packageName + "@" + constraint.versionConstraint + ": no such versio
|
||||
// Add the package to the list of packages that we use directly.
|
||||
usingDirectly[constraint.packageName] = constraint.versionConstraint;
|
||||
var usingIndirectly = project.getDepsAsObj(project.getIndirectDependencies(options.appDir));
|
||||
console.log(usingDirectly);
|
||||
|
||||
// Call the constraint solver.
|
||||
var ConstraintSolver = unipackage.load({
|
||||
@@ -617,7 +618,10 @@ constraint.packageName + "@" + constraint.versionConstraint + ": no such versio
|
||||
release: release.current.name
|
||||
})['constraint-solver'].ConstraintSolver;
|
||||
|
||||
console.log("Going to init constraint resolver");
|
||||
var resolver = new ConstraintSolver.Resolver(cat);
|
||||
console.log("Initialized constraint resolver");
|
||||
|
||||
var newVersions = resolver.resolve(usingDirectly,
|
||||
usingIndirectly,
|
||||
{ optionsGoHere : false });
|
||||
@@ -1476,7 +1480,7 @@ main.registerCommand({
|
||||
|
||||
if (! version) {
|
||||
process.stderr.write(
|
||||
"That package cannot be published because it doesn't have a version.\n");
|
||||
"That package cannot be published because it doesn't have a version.\n");
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
@@ -982,14 +982,14 @@ _.extend(Package.prototype, {
|
||||
_.keys(self.defaultSlices));
|
||||
|
||||
//XXX: this is commented out, but maybe shouldn't be.
|
||||
if (! chosenArch) {
|
||||
/*if (! chosenArch) {
|
||||
buildmessage.error(
|
||||
(self.name || "this app") +
|
||||
" is not compatible with architecture '" + arch + "'",
|
||||
{ secondary: true });
|
||||
// recover by returning by no slices
|
||||
return [];
|
||||
}
|
||||
}*/
|
||||
|
||||
return _.map(self.defaultSlices[chosenArch], function (name) {
|
||||
return self.getSingleSlice(name, arch);
|
||||
|
||||
Reference in New Issue
Block a user