jalagar / animated-art-engine

A generative engine that takes various png layers on a sprite sheet format, combines them and then converts them into a .gif file
MIT License
166 stars 64 forks source link

Delete metadata.json file #191

Closed Snikerg1 closed 8 months ago

Snikerg1 commented 8 months ago

Hello jalagar and all the community....

This code has been very helpful, however I have had a problem. I have generated a collection of 25k gifs.... I have done it in parts and in the process I deleted the Metadata.json files.

The problem is that now I need them to replace the base URI in the json files of each gif.

I have the 25k gifs and the corresponding json but I can't replace the base URI....

I can't run the collection again either because I have been doing it for months. And I have been deleting the rendered files with which I made the gifs.

What can I do?

Thanks, greetings.

Snikerg1 commented 8 months ago

Hello again,

If someone by mistake deletes the metadata.json file as I did, here is the solution I found.

I installed the following : https://jqlang.github.io/jq/

Using the command: Chcoco install jq

You have to go to the folder where you locate your json files and open a cmd or PowerShell terminates.

And in my case given the configuration of the json files the following command worked for me.

jq -s '[.[]]' * > (name of your file) .json

As a suggestion to anyone who is starting to create his collection. Do not delete your metadata.json.

Greetings...

jalagar commented 8 months ago

Thank you for sharing! Glad it worked :)