Is there a way to upgrade a package to a major ver...
# box-products
r
Is there a way to upgrade a package to a major version within the cbox CLI? I even attempted to uninstall and install, but I cannot get the package to uninstall with the use of a
--system
flag. Not implying the
--system
flag is the culprit.. just explaining what I have attempted, thus far. Particularly, I am viewing that system module cfmigrations is at v2.0.10 and upgradeable to 3.0.6.
b
As you suspect, the
--system
flag has no bearing on the version logic
What may be the case is you could have that module saved as both a dev dep and a normal dep in the core
box.json
file
I've seen that give strange behaviors when trying to upgrade
The next version of CommandBox will prevent that BTW
I bet I see the problem
I just installed
commandbox-migrations
to look and I too have cfmigrations 2.x
That is because the commandbox-migrations package is set to ONLY have 2.x of the cfmigrations dependency
Copy code
"dependencies":{
        "cfmigrations":"^2.0.0"
    },
So even though there is a major update 'available', you're never going to get it no mater how many times you reinstall commandbox-migrations 🙂
👍🏼 1
The takeaway here is we should probably hide "major" updates to nested dependencies even though that's still not technically going to be correct in every scenario
@ryan I fixed this in the bleeding edge https://ortussolutions.atlassian.net/browse/COMMANDBOX-1447
👀 1
Running
Copy code
outdated --system --hideUpToDate
returns nothing now
👍🏼 1
r
awesome, thank you @bdw429s