Improve handling of site specific translations, content, texts, images, taxonomies etc. in git for OFF, OBF, OPF, OPFF etc. #1536
Labels
🌐 i18n
Regarding software localization
🧴 Open Beauty Facts
Our cosmetic analysis project https://world.openbeautyfacts.org
🐾 Open Pet Food Facts
Our pet food analysis project https://world.openpetfoodfacts.org
📸 Open Products Facts
Our project to increase the lifespan of objects. https://world.openproductsfacts.org
🎯 P0
🧬 Taxonomies
https://wiki.openfoodfacts.org/Global_taxonomies
We used to have only Open Food Facts (OFF) and then we added Open Beauty Facts, Open Pet Food Facts, Open Products Facts. All the sites share the same code, but they share only parts of translations, taxonomies etc. We need a better system to store in github the site specific content.
An option is to add a $site_id variable in Config2.pm, which would be either "off" or "openbeautyfacts", and then we use that to add a sublevel in the directory structure, like we currently have for translations in the /po/ dir:
lrwxrwxrwx 1 off root 13 Jul 9 16:51 site-specific -> openfoodfacts
drwxr-xr-x 2 off off 4096 Nov 5 16:47 openfoodfacts
drwxr-xr-x 2 off off 4096 Nov 7 15:36 openbeautyfacts
drwxr-xr-x 2 off off 4096 Nov 7 15:36 openpetfoodfacts
drwxr-xr-x 2 off off 4096 Nov 7 15:36 openproductsfacts
drwxr-xr-x 2 off off 4096 Nov 8 14:34 common
But instead of using symlinks like the "site-specific", we use the $site_id variable from the Config2.pm configuration file.
We also create a common directory that we load first, and that can be overridden by site specific content.
Directories with site specific content:
/taxonomies : create /taxonomies/common/ (e.g. languages, countries) and /taxonomies/openfoodfacts/ingredients.txt etc.
/images/misc/favicon
/lang
Part of
The text was updated successfully, but these errors were encountered: