Hacker News new | past | comments | ask | show | jobs | submit login

In the getting started guide, it looks like they use an as-yet-non-existent Post struct to create the migration SQL. Where is the migration CLI getting the struct's fields from if it hasn't yet been written in that part of the tutorial? Am I missing something obvious?



The CLI just generates the file structure. We fill in the SQL manually as part of the guide, and then create the structs immediately after that.


What I get for reading too quickly! Thanks for clarifying.


It wasn't super clear, anyway. Fixed in https://github.com/sgrif/diesel.rs-website/pull/5 :)


You're supposed to write that SQL yourself, I believe. I'll file an issue to clear this up either way.




Consider applying for YC's Summer 2025 batch! Applications are open till May 13

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: