Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

Gem overrides stylesheet after regenerating site

Abierto
#657 6 comentarios 1 reacción 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
35/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Estancado
Stack tecnológico
ruby
Área
build-system

Línea de trabajo

Comienza con la entrada de Gemfile para github-pages y la reproducción de assets/css/style.css; después ejecuta bundle exec jekyll serve y activa la regeneración editando index.html. Está terminado cuando aparece el nuevo contenido de la landing page y la hoja de estilos del sitio sigue utilizándose en lugar de ser sobrescrita por una hoja de estilos de tema incluida en el bundle.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Summary

When github-pages is listed under the group :jekyll_plugins in the Gemfile, then on regeneration, a site has its assets/css/style.css overridden by one bundled with one of the themes in the gem.

This issue came to my notice while investigating jekyll/jekyll#7854.

This issue affects

  • The site generated by GitHub Pages maybe.. maybe not..
  • Building sites locally

Steps to reproduce

  • Set up a Jekyll site with at least the following:
    • Gemfile
      source 'https://rubygems.org'
      gem 'github-pages', group: :jekyll_plugins
      
    • assets/css/style.css with the following:
      h1 { color: red }
      
    • An index.html that uses the above stylesheet. (either via a layout or directly)
      <!DOCTYPE html>
      <html>
        <head>
          <meta charset="UTF-8"/>
          <title>Test Site</title>
          <link rel="stylesheet" href="/assets/css/style.css" />
        </head>
        <body>
          <h1>Hello World</h1>
        </body>
      </html>
      
  • Serve the site locally and preview at http://localhost:4000/
    bundle exec jekyll serve
    
  • Trigger a regeneration by just adding content to the landing page.
      <h1>Hello World</h1>
    + <p>Lorem ipsum dolor sit amet</p>
    

What did you expect to happen?

Expected the landing page to be rendered with the new content.

What happened instead?

The following would illustrate better:

Before regeneration:

before-regen

After regeneration:

after-regen

Lenguaje dominante
Ruby
Estrellas
1.9k
Forks
361
Métricas de merge de PR
Sin PR fusionados en 30 d

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de github/pages-gem

Todos los issues de github/pages-gem

Issues similares

Más issues de Ruby

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.