Coder Social home page Coder Social logo

Comments (2)

etiennebarrie avatar etiennebarrie commented on June 12, 2024

Rails engines provide a $engine_name:install that can be used on the first installation and any upgrade. It's idempotent for the migration files but isn't super smart, it just checks whether the same migration exist based on its class name.

We even have an explanation about this in the README, for people who roll up their migrations and then have our migrations re-appear: https://github.com/Shopify/maintenance_tasks/blob/eeee3f4ebfdeea048c2d3bb9897ca29c2cd93187/README.md#upgrading

While we could provide a special task for first installs (with a rolled up migration) and keep the current migrations for everyone else that need the "diff" migrations, ultimately this should be built in Rails so it can benefit every engine, and not just this one.

from maintenance_tasks.

Schwad avatar Schwad commented on June 12, 2024

Use bundler to check for and upgrade to newer versions. After installing a new version, re-run the install command:

Okay, that makes sense, so that folks can upgrade in a clear way. Thanks for the explainer

from maintenance_tasks.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.