Refactor repository structure for easier maintenance
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 25/100
- Tipo de issue
- Refactorización
- Claridad
- Bastante claro
- Estado de actividad
- Estancado
- Área
- tooling
Línea de trabajo
Empieza leyendo el index.yml existente y los manifiestos de cada aplicación en los directorios de categorías; después, inspecciona el comportamiento actual del cliente Bottles al buscar manifiestos. Compara el meta.yml propuesto, los nombres y categorías derivados de los nombres de archivo y los campos Icon, Event y Hidden con el formato actual. Se considera terminado cuando la estructura del repositorio y el comportamiento del cliente se hayan migrado sin que fallen los clientes obsoletos.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
As discussed in #413:
Problem:
The index.yml is very often forgotten by people (even core contributors). Some people edit the manifest, some people edit the index, but 50% of the time one of them is forgotten. There's lots of metadata repetition, leading to maintainer and contributor mistakes.
Proposal:
- Delete:
index.yml(almost all of its fields are copy-pasted duplicates of the per-app manifests, causing a maintenance burden) - Add:
meta.ymlwith the following contents, to tell Bottles which sub-directories to scan for*.ymlmanifests:
categories:
- Games
- Software
- Modify
<app name>.ymlformat as follows:Name: Change this to be the "pretty display name" that used to only exist in the index, such as "GOG Galaxy". This field used to be redundant in the manifest and was always the same name as the manifest file minus the.ymlextension (so for example,epicgamestore.ymlhad aName: epicgamestorewhich is pointless and a source of potential typos). So let's instead track that internal "name" via the actual.ymlfilename, and use theNamefield to carry the UI display name.Category: Do not add this to the manifest. Instead, automatically detect it based on the name of the directory the manifest is inside, such as "Games" or "Software". That's one less source of typos.Icon: Add this to the manifest. It's the filename of the icon to display during installation.Event: If it's useful, add it to the manifest. I don't know the purpose. Only a few entries in the index currently have this value, and it's always a filename pointing at an installer file. It may be possible to just remove this entirely. Edit: Include it, I found its purpose and it looks like a great idea: https://github.com/bottlesdevs/programs/issues/414#issuecomment-3061658624Hidden: Add this optional field. If missing, assumefalse. Otherwise allow the manifest to containtrue/falsehere. If hidden istrue, do not display this manifest in the UI. The purpose is to allow an easy way to hide broken manifests without having to manually move them out of the auto-scanned manifest directories.
The scanning process for the client to index all manifests is then as follows:
for category in categories: # "categories" comes from meta.yml
category_dir = programs_dir / category # assumes pathlib.Path
for manifest_yml in category_dir.glob("*.yml"):
name = manifest_yml.stem
# We have now automatically derived the category and manifest name:
# category: Games
# name: epicgamestore
# Now read the manifest YAML file, and immediately skip the manifest
# if `Hidden` exists and is `true`. Do that check before any other parsing,
# to avoid trying to parse other possibly-outdated manifest structures.
With this repo structure, maintenance is only a matter of editing/moving a single .yml file per application.
Target: Bottles-Next, or possibly even the current public release. If targeting the current release, a simple migration solution is to put up a dummy index.yml file which is empty, so that outdated Bottles clients won't have any fatal errors and simply don't display any programs at all until the user has updated Bottles.
- Lenguaje dominante
- Sin datos de lenguaje
- Estrellas
- 111
- Forks
- 93
- Merge medio
- 1 d 1 h
- PR fusionados (30 d)
- 3
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de bottlesdevs/programs
-
[Feature Request] VirtualDJ Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
bottlesdevs/programs#498 ·
-
Wrong file path for FL Studio Abierto
Dificultad 1/5 Menos de una hora Aptitud para principiantes 82/100
bottlesdevs/programs#490 · 1 comentario ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
bottlesdevs/programs#429 · 27 comentarios ·
-
[Feature Request] PaintShop Pro Abierto
Dificultad 3/5 1-2 días Aptitud para principiantes 64/100
bottlesdevs/programs#497 ·
-
Installer Request: Wine Import Abierto
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
bottlesdevs/programs#495 ·
Todos los issues de bottlesdevs/programs
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
pastelsky/bundlephobia#1122 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
anthropics/skills#1811 · 1 comentario ·
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
CachyOS/distribution#587 ·
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
datalayer/mcp-compose#42 ·
-
[Chore] Keep one viget-block-generator skill and replicate it, instead of four tracked copies Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100