Skip to content

Draft: new standalone command: fetch_metadata, replacing update functionality.

linsui requested to merge linsui/fdroidserver:fetch_metadata into master

When I try to add more search path for fastlane metadata, I take the chance to extract the whole function in to a sub command. I'm not sure if the performance will be affected. Before I polish this MR further I want to also get some feedback.

What I have done:

  1. Break up copy_triple_t_store_metadata and insert_localized_app_metadata into small functions and classes.
  2. Split the process into two parts. First the text is read and the image path is indexed. Then the images are copied.
  3. Add more search path for fastlane.
  4. Currenly both the mtime and size are compared between the images in repo and source. Because we also strip some images these images are always copied again and again. I removed the size check.
  5. Add a new fetch_metadata subcommand (maybe there is a better name?) so that the metadata structure can be checked easily.

What I haven't done:

  1. Add an item so that the search path can be specified in build metadata. Is this necessary? Should we support path out of the repo? E.g. another repo or a tarball?
  2. Clean up leftover images from repo. Currently F-Droid also support adding images into repo directly. How should we decide if the image is leftover?
  3. If there are images fetched from other path then all other images in repo should be remove.
  4. Drop this function and ask users to host the images in build dir instead.
  5. Output the result to a file.

What I want to drop/change:

  1. Currently fastlane structure in fdroiddata is supported, i.e. short_description.txt, etc. However they are not used and only the custon style, i.e. summary.txt is used.
  2. The author info from triple-t seems only used by few apps. They can be added to the build metadata directly anyway.
  3. Description and changelog is not stripped. I don't know if there is any use case to keep the new line and space.

Merge request reports