Mantenimiento del tema de la revista
The Magazine theme is maintained in a Pagure repository. If you want to submit a change, start by forking and/or cloning this repository. This page does not cover git workflow; consult git documentation for more information, or ask the Magazine staff for help.
Testing your changes
The build.sh
and preview.sh
scripts let you deploy WordPress in a local container to test your work before you push your changes to the live site. Ensure you are in the root of the cloned repository and enter ./build.sh && ./preview.sh
to create and provision the container. This will take some time.
When done, you can point your local browser at http://localhost:5055 to see the theme with your local revisions. The container accesses the contents of the repo directly, so you can edit changes in the repository and quickly see them in action. To iterate on changes, after modifying the theme, run podman restart wordpress
from another terminal window so the containers’s web caching is cleared. Then refresh your browser window (F5 or Ctrl+F5) to view the modifications.
When finished, press Ctrl+C in the original terminal window from which you launched the container to stop the container. Optionally, you can run ./clean.sh
to remove all the contianer artifacts except for the repo itself from your system. If you remove all the artifacts (WordPress plugins, databases, etc.) it will take longer to run the build.sh
and preview.sh
commands the next time because everything will need to be re-downloaded and re-installed.
Etiquetar el tema
Una vez completadas las modificaciones del tema, debes hacer una publicación. Esto significa que cualquier persona puede volver a esta iteración del tema en caso de un problema con una versión futura.
El último commit en tus cambios debería actualizar el archivo fedoramagazine/styles.css
para actualizar la version
en la cabecera:
Theme Name: Fedora Magazine 2018 Text Domain: fmag2018 Theme URI: http://pagure.org/fedoramagazine-theme/ Version: 1.03 Description: The theme for the Fedora Magazine. This iteration first rolled out in March 2018
Aplique una etiqueta a esta confirmación para marcarla para su publicación, como v1.03
, y envíe la etiqueta al repositorio usando git push --tags
.
Liberar el tema
Mientras que en el repositorio, ejecute estos comandos para hacer un archivo zip en el que entregar el tema. Recuerda usar el número correcto de la nueva versión en lugar de 1.03.
$ ln -s fedoramagazine fedoramagazine-1.03 $ zip -r /tmp/fedoramagazine-theme-1.03.zip fedoramagazine-1.03 $ rm -f fedoramagazine-1.03
El resultado fedoramagazine-theme-1.03.zip
es una versión del tema.
Instalación del tema actualizado
Este paso debe realizarlo alguien con derechos de "administrador" en el sitio WordPress de Fedora Magazine.
Utilice las funciones integradas para añadir un nuevo tema. Sube el archivo resultante fedoramagazine-theme-1.03.zip
y actívalo.
Si necesitas cambiar de tema y no sabes cuál es el correcto, los detalles del tema te mostrarán el número de versión.
Want to help? Learn how to contribute to Fedora Docs ›