Skip to content

Plugin Request: Generate Ecto "schema.ex" and "migration.exs" files for Elixir/Ecto Language Platform #21

@mrjbj

Description

@mrjbj

I love pgModeler but am struggling to integrate it into the workflow by Elixir developers. Elixir uses a database persistence framework called "Ecto", which is actually freaking amazing. However, it requires two files be maintained in a "code-first" approach to the database. The first file (called a "schema") governs how application data is cast to/from data types in the UI to database (and that data passes business validations). The second file (called a "migration") is used to create/alter/seed the database itself.

My current workflow is to design in pgModeler, then manually create these two files based pretty much 1:1 from column content already designed into pgModeler. It would be super helpful if the "create code" feature of pgModeler could be templated in such a way as to emit these Elixir/Ecto schema and migration files as an option. Given that the pgModeler files are saved in XML format, I suppose I could probably figure out a way transform from this using Elixir myself, but I was thinking perhaps this plugin architecture might be an easier or more supportable way of doing so instead.

Here is a link to overview on Ecto, if interested. No worries if not a good idea or not enough people use Elixir yet. Just wanted to get the idea out there for consideration. Thank you.

Elixir/Ecto Basic Overview

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions