Add mix task to undo latest codegen/delete latest migration
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 38/100
调研方向
首先定位生成迁移的 mix task,以及负责迁移文件和表快照文件的代码。跟踪最新迁移及其关联快照的识别方式,然后查看现有的任务测试或迁移生成测试。当名为 ash_postgres.delete_latest_migration 的任务在确认迁移名称后,仅删除最新迁移及其快照时,即表示完成。
由索引模型根据 Issue 内容生成。
描述
Is your feature request related to a problem? Please describe.
Codegen to generate a migration is really awesome, but sometimes you generate a migration and then you realize you missed something, so you want to delete that migration, make the change, and then generate it again. Currently that's a manual process - go find the migration, find the snapshots for all the relevant tables, delete them all, and do it again. It's pretty annoying!
Describe the solution you'd like
A task like ash_postgres.delete_latest_migration that will delete the last migration, and any snapshots that were created at the same time. No option to delete other migrations or anything like that - only the last one.
And it should probably confirm the name of the migration just to make sure!
Describe alternatives you've considered
You could just generate another migration with the added changes, but snapshot files are big and ugly and if you haven't even run the first migration, being able to undo/regenerate it seems like the smarter approach.
- 主要语言
- Elixir
- 星标
- 191
- 派生
- 186
- 平均合并
- 16 小时 4 分钟
- 30 天内合并 PR
- 17
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
ash-project/ash_postgres 的其他 Issue
-
Temporal: an update or destroy as of an instant doesn't carry into later versions可能已有人在做 @hoanle0126 于 14 天前认领。 未关闭
难度 5/5 一周以上 新手友好度 15/100
ash-project/ash_postgres#915 · 1 条评论 ·
维护者通常 1 天内回复
-
has_create_action?/1 excludes manual creates, making the #49 nullability fix inert on AshEvents resources可能重新可做 @Mckay-Hinds 于 19 天前认领,目前没有进行中的 PR。 未关闭
难度 3/5 1-2 天 新手友好度 76/100
ash-project/ash_postgres#851 · 9 条评论 ·
维护者通常 1 天内回复
-
enhancement
难度 4/5 3-5 天 新手友好度 35/100
ash-project/ash_postgres#650 · 6 条评论 ·
维护者通常 1 天内回复
-
bug
难度 4/5 3-5 天 新手友好度 35/100
ash-project/ash_postgres#642 · 5 条评论 ·
维护者通常 1 天内回复
-
enhancement
难度 5/5 一周以上 新手友好度 40/100
ash-project/ash_postgres#628 · 1 条评论 ·
维护者通常 1 天内回复
查看 ash-project/ash_postgres 的全部 Issue
相似的 Issue
-
Flaky test未关闭dette technique
难度 2/5 1-3 小时 新手友好度 65/100
etalab/transport-site#5701 ·
维护者通常 5 天内回复
-
难度 2/5 1-3 小时 新手友好度 75/100
维护者通常 1 天内回复
-
@swmansion/popcorn: published .d.ts files lack extensions on relative imports, breaking moduleResolution node16/nodenext可能已有人在做 @Huyvux12 于 1 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 78/100
software-mansion/popcorn#929 · 2 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 76/100
intellij-elixir/intellij-elixir#4705 ·
维护者通常 1 天内回复
-
难度 1/5 1 小时以内 新手友好度 85/100
phoenixframework/phoenix#6908 · 1 条评论 ·
维护者通常 1 天内回复