Skip to main content

Création d’un site GitHub Pages avec Jekyll

Vous pouvez utiliser Jekyll pour créer un site GitHub Pages dans un dépôt nouveau ou existant.

Qui peut utiliser cette fonctionnalité ?

People with admin permissions for a repository can create a GitHub Pages site with Jekyll.

GitHub Pages est disponible dans les référentiels publics avec GitHub Free et GitHub Free pour les organisations, et dans les référentiels publics et privés avec GitHub Pro, GitHub Team, GitHub Enterprise Cloud et GitHub Enterprise Server.

Platform navigation

Prerequisites

Before you can use Jekyll to create a GitHub Pages site, you must install Jekyll and Git. For more information, see Installation in the Jekyll documentation and Set up Git.

We recommend using Bundler to install and run Jekyll. Bundler manages Ruby gem dependencies, reduces Jekyll build errors, and prevents environment-related bugs. To install Bundler:

  1. Install Ruby. For more information, see Installing Ruby in the Ruby documentation.
  2. Install Bundler. For more information, see Bundler.

Tip

If you see a Ruby error when you try to install Jekyll using Bundler, you may need to use a package manager, such as RVM or Homebrew, to manage your Ruby installation. For more information, see Troubleshooting in the Jekyll documentation.

Creating a repository for your site

You can either create a repository or choose an existing repository for your site.

If you want to create a GitHub Pages site for a repository where not all of the files in the repository are related to the site, you will be able to configure a publishing source for your site. For example, you can have a dedicated branch and folder to hold your site source files, or you can use a custom GitHub Actions workflow to build and deploy your site source files. To use GitHub Actions as a publishing source for GitHub Pages, a site administrator must enable GitHub Actions for GitHub Enterprise Server. For more information, see Enabling GitHub Actions for GitHub Enterprise Server.

If you want to create a site in an existing repository, skip to the Creating your site section.

  1. In the upper-right corner of any page, select , then click New repository.

    Screenshot of a GitHub dropdown menu showing options to create new items. The menu item "New repository" is outlined in dark orange.

  2. Use the Owner dropdown menu to select the account you want to own the repository.