percolatestudio / meteor-migrations

Simple migration system for Meteor
https://atmospherejs.com/percolate/migrations
MIT License
245 stars 58 forks source link

Get Current Version #18

Closed mccormjt closed 9 years ago

mccormjt commented 9 years ago

This is fairly simple, but it would be nice to see which version you are on. Could be useful if you are tinkering around. Something like -> Migrations.currentVersion()

zol commented 9 years ago

@mccormjt This already exists. Call Migrations.getVersion. I will document it now.

mccormjt commented 9 years ago

great thanks!

sungwoncho commented 9 years ago

How about storing the history of the migration in the db? Rails does this by storing the timestamps of migrations already run and I think it's quite useful.

That way, I don't have to try to run Migrations.getVersion on the server side every time I need to check the current migration version.

Update Never mind, it already does in db.migrations