diff --git a/source/dub/commandline.d b/source/dub/commandline.d index 1027daa..03772a0 100644 --- a/source/dub/commandline.d +++ b/source/dub/commandline.d @@ -192,7 +192,7 @@ case "upgrade": dub.loadPackageFromCwd(); logInfo("Upgrading project in %s", dub.projectPath.toNativeString()); - dub.update(UpdateOptions.Upgrade | (annotate ? UpdateOptions.JustAnnotate : UpdateOptions.None) | (pre_release ? UpdateOptions.preRelease : UpdateOptions.None)); + dub.update(UpdateOptions.upgrade | (annotate ? UpdateOptions.justAnnotate : UpdateOptions.none) | (pre_release ? UpdateOptions.preRelease : UpdateOptions.none)); return 0; case "install": warnRenamed(cmd, "fetch"); @@ -292,7 +292,7 @@ if( !nodeps ){ logInfo("Checking dependencies in '%s'", dub.projectPath.toNativeString()); - dub.update(annotate ? UpdateOptions.JustAnnotate : UpdateOptions.None); + dub.update(annotate ? UpdateOptions.justAnnotate : UpdateOptions.none); } enforce(build_config.length == 0 || dub.configurations.canFind(build_config), "Unknown build configuration: "~build_config); diff --git a/source/dub/dub.d b/source/dub/dub.d index bfe1b4c..feac1fc 100644 --- a/source/dub/dub.d +++ b/source/dub/dub.d @@ -160,7 +160,7 @@ } } - if (conflictedOrFailed || options & UpdateOptions.JustAnnotate) return; + if (conflictedOrFailed || options & UpdateOptions.justAnnotate) return; // Remove first foreach(Action a; filter!((Action a) => a.type == Action.Type.remove)(actions)) { @@ -168,7 +168,7 @@ remove(a.pack); } foreach(Action a; filter!((Action a) => a.type == Action.Type.fetch)(actions)) { - fetch(a.packageId, a.vers, a.location, (options & UpdateOptions.Upgrade) != 0, (options & UpdateOptions.preRelease) != 0); + fetch(a.packageId, a.vers, a.location, (options & UpdateOptions.upgrade) != 0, (options & UpdateOptions.preRelease) != 0); // never update the same package more than once masterVersionUpgrades[a.packageId] = true; } diff --git a/source/dub/project.d b/source/dub/project.d index bcbb705..5a34df8 100644 --- a/source/dub/project.d +++ b/source/dub/project.d @@ -491,7 +491,7 @@ else logDiagnostic("Triggering retrieval of required package '"~basepkg~"', which doesn't match the required versionh. Required '%s', available '%s'.", d.dependency, p.vers); actions ~= Action.get(basepkg, PlacementLocation.userWide, d.dependency, d.packages); } else { - if (option & UpdateOptions.Upgrade) { + if (option & UpdateOptions.upgrade) { auto existing = m_packageManager.getBestPackage(basepkg, d.dependency); // Only add one upgrade action for each package. if(basepkg !in upgradePackages && m_packageManager.isManagedPackage(existing)) { @@ -724,9 +724,9 @@ enum UpdateOptions { - None = 0, - JustAnnotate = 1<<0, - Upgrade = 1<<1, + none = 0, + justAnnotate = 1<<0, + upgrade = 1<<1, preRelease = 1<<2 // inclde pre-release versions in upgrade }