gourmet icon indicating copy to clipboard operation
gourmet copied to clipboard

.rtk Inport

Open DavidIN25 opened this issue 7 years ago • 4 comments

Gourmet to import Recette Tek .rtk files. See Google play for info on Recette Tek.

DavidIN25 avatar Mar 06 '18 18:03 DavidIN25

RecetteTek's website. You can use the generator to create a recipe and download an .rtk file.

Okay. The .rtk file is a ZIP file, with a straightforward JSON file format. That should be fairly easy to support. It is a bunch of text fields, which is simple.

I half-tried to remember my cornbread recipe and here is the JSON result (from the generator):

[{"title":"Cornbread",
"preparationTime":"5 minutes",
"cookingTime":"15 min",
"inactiveTime":"",
"quantity":"8 slices",
"ingredients":"1/2 cup flour all-purpose flour\r\n1/2 cup\r\n4 tsp baking soda\r\n1/2 cup butter\r\n1 egg\r\n1 cup of milk.",
"video":"",
"instructions":"1. Preheat oven to 425 degrees Fahrenheit.  Place butter in a cast iron skillet in the oven.\r\n2. In a medium bowl mix the dry ingredients, add the wet ingredients, and the butter. Pour contents of bowl into the hot skillet.\r\n3. Place skillet in the oven and bake for 15-18 minutes.",
"notes":"",
"cookware":"",
"url":"",
"originalPicture":""}]

micahcochran avatar Mar 06 '18 22:03 micahcochran

Good. What I'm looking at is exporting from Recette Tek on phone, Android, (48 files) to Import to Gourmet, Fedora.

On Mar 6, 2018 5:33 PM, "Micah Cochran" [email protected] wrote:

RecetteTek's website https://www.recettetek.fr/. You can use the generator https://www.recettetek.fr/generator.html to create a recipe and download an .rtk file.

Okay. The .rtk file is a ZIP file, with a straightforward JSON file format. That should be fairly easy to support. It is a bunch of text fields, which is simple.

I half-tried to remember my cornbread recipe and here is the JSON result (from the generator):

[{"title":"Cornbread","preparationTime":"5 minutes","cookingTime":"15 min","inactiveTime":"","quantity":"8 slices","ingredients":"1/2 cup flour all-purpose flour\r\n1/2 cup\r\n4 tsp baking soda\r\n1/2 cup butter\r\n1 egg\r\n1 cup of milk.","video":"","instructions":"1. Preheat oven to 425 degrees Fahrenheit. Place butter in a cast iron skillet in the oven.\r\n2. In a medium bowl mix the dry ingredients, add the wet ingredients, and the butter. Pour contents of bowl into the hot skillet.\r\n3. Place skillet in the oven and bake for 15-18 minutes.","notes":"","cookware":"","url":"","originalPicture":""}]

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/thinkle/gourmet/issues/903#issuecomment-370953266, or mute the thread https://github.com/notifications/unsubscribe-auth/AglkSD_hHv1J1L0LspdwbI7kt5pEk9Iqks5tbw6egaJpZM4SfP04 .

DavidIN25 avatar Mar 06 '18 22:03 DavidIN25

Does the spec really do ingredients in one string with newlines between them? Seems crazy that that's not an array :)

On Tue, Mar 6, 2018, 5:41 PM DavidIN25 [email protected] wrote:

Good. What I'm looking at is exporting from Recette Tek on phone, Android, (48 files) to Import to Gourmet, Fedora.

On Mar 6, 2018 5:33 PM, "Micah Cochran" [email protected] wrote:

RecetteTek's website https://www.recettetek.fr/. You can use the generator https://www.recettetek.fr/generator.html to create a recipe and download an .rtk file.

Okay. The .rtk file is a ZIP file, with a straightforward JSON file format. That should be fairly easy to support. It is a bunch of text fields, which is simple.

I half-tried to remember my cornbread recipe and here is the JSON result (from the generator):

[{"title":"Cornbread","preparationTime":"5 minutes","cookingTime":"15 min","inactiveTime":"","quantity":"8 slices","ingredients":"1/2 cup flour all-purpose flour\r\n1/2 cup\r\n4 tsp baking soda\r\n1/2 cup butter\r\n1 egg\r\n1 cup of milk.","video":"","instructions":"1. Preheat oven to 425 degrees Fahrenheit. Place butter in a cast iron skillet in the oven.\r\n2. In a medium bowl mix the dry ingredients, add the wet ingredients, and the butter. Pour contents of bowl into the hot skillet.\r\n3. Place skillet in the oven and bake for 15-18 minutes.","notes":"","cookware":"","url":"","originalPicture":""}]

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/thinkle/gourmet/issues/903#issuecomment-370953266, or mute the thread < https://github.com/notifications/unsubscribe-auth/AglkSD_hHv1J1L0LspdwbI7kt5pEk9Iqks5tbw6egaJpZM4SfP04

.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/thinkle/gourmet/issues/903#issuecomment-370955346, or mute the thread https://github.com/notifications/unsubscribe-auth/AAi8W8Nfa1tQ14-J3xX8wPS970bOPcCyks5tbxB9gaJpZM4SfP04 .

thinkle avatar Mar 07 '18 01:03 thinkle

The generator uses "\r\n" to separate lines for ingredients and instruction (and probably many of the other boxes) on Windows and Linux.

I tried two recipes and fairly predictably added a second dictionary to the outer list. Only one file in .rtk zip file.

micahcochran avatar Mar 07 '18 04:03 micahcochran