# Publicar una página web con Github pages

GitHub se puede utilizar mediante:&#x20;

* **Github desktop**&#x20;
* **Terminal**: Para el modo terminal hay que configurar un acceso SSH y usar comandos de github y Linux o puedes acceder al terminal desde el mismo Github desktop. &#x20;

<figure><img src="/files/ks2FLPm9ENhyMF9yzfAH" alt=""><figcaption></figcaption></figure>

&#x20;

### MODO GITHUB WEB APP&#x20;

Primero crear una cuenta de Github &#x20;

<figure><img src="/files/9sh6ReVG22w75qIibdlu" alt=""><figcaption></figcaption></figure>

En la esquina superior derecha de cualquier página, utiliza el menú desplegable y selecciona Repositorio Nuevo.&#x20;

![Menú desplegable con opción para crear un repositorio nuevo](/files/PJ84qZKhv9qmQ9p1i9Hu)&#x20;

&#x20;

Ingresa username.github.io como nombre de repositorio. Reemplaza a username con tu nombre de usuario de GitHub. Por ejemplo, si tu nombre de usuario es octocat, el nombre de repositorio debería ser octocat.github.io.&#x20;

<figure><img src="/files/HKF718bmE96EDgzp0jff" alt=""><figcaption></figcaption></figure>

&#x20;

Una vez creado el repositorio, crea manualmente los archivos de Pages: &#x20;

<figure><img src="/files/6a1lvyNt2j2ID0CTjfpo" alt=""><figcaption></figcaption></figure>

Cambiar el título y la descripción&#x20;

Predeterminadamente, el título de tu sitio es `username.github.io`. Puedes cambiar el título si editas el archivo `_config.yml` en tu repositorio. También puedes agregar una descripción de tu sitio.&#x20;

* Haz clic en la pestaña de Código de tu repositorio.&#x20;
* En la lista de archivos, haz clic en `_config.yml` para abrir el archivo.&#x20;
* Edita el archivo: el archivo `_config.yml` ya contiene una línea que especifica el tema para tu sitio. Agrega una línea nueva con title:, seguido del título que quieras. Agrega una línea nueva con description:, seguido de la descripción que quieras. &#x20;

&#x20;

Por ejemplo:&#x20;

```
theme: jekyll-theme-minimal 
title: Octocat's homepage 
description: Bookmark this to keep an eye on my project updates! 
```

* Para cambiar el tema, revisa de la lista de [temas compatibles](https://pages.github.com/themes/) y cambia en la línea de “theme” la palabra resaltada por uno de la lista:&#x20;

`theme: jekyll-theme-minimal`&#x20;

Por otro&#x20;

`theme: jekyll-theme-merlot`&#x20;

* Cuando termines de editar el archivo, haz clic en Confirmar cambios.&#x20;

Visita `username.github.io` para ver tu sitio web nuevo. &#x20;

{% hint style="danger" %}
**Nota:** Las publicaciones y cambios pueden tardar un poco en reflejarse en la web, puedes ver los cambios en directo desde la pestaña “Actions”&#x20;
{% endhint %}

### GITHUB DESKTOP&#x20;

Una vez en el GitHub Desktop, clona tu repositorio en línea a través de navegador para crear una copia local.&#x20;

Desde la carpeta local de GitHub es más sencillo editar código o conectarlo directamente a Visual Code, Visual Studio u otros IDEs que tengan compatibilidad.&#x20;

{% hint style="warning" %}
**NOTA:** Hay un error en GitHub desktop la primera vez que lo abres que dice “Error &#x20;

Author identity unknown \*\*\* Please tell me who you are.” para ello ves al terminal: &#x20;

![](/files/AOkmgKanTy040L6R8lU0)

Y escribes:

```batch
git config --global user.email "you@example.com" 
git config --global user.name "Your Name" 
  
%USERPROFILE%\.gitconfig 
```

{% endhint %}

<details>

<summary>Practica: Uso de Github </summary>

A continuación, lo que quiero que hagáis es que montéis vuestro propio repositorio y creéis una web para promocionaros, como un CV online como el que realizasteis en FOL/EIE con una serie de requisitos:

* Debe contener una foto vuestra.
* Debe contener varias categorías debidamente separadas y distinguidas.
* Debe contener listas.
* Debe estar formateado el texto para cursiva y negrita.

Lo siguiente que deberéis crear es una categoría dentro del CV que sea el portfolio. Subid varias carpetas con proyectos de HTML/CSS realizados en clase o de otros lenguajes (Batch, python...) y enlazadlas en vuestro CV.&#x20;

Como referencia os dejo mi github:

* <https://github.com/aviladotgibert/aviladotgibert.github.io>
* <https://aviladotgibert.github.io/>

</details>

### WEBGRAFÍA&#x20;

GUIA INICIO GITHUB PAGES: <https://docs.github.com/es/pages/quickstart>&#x20;

MARKDOWN LANGUAGE DE GITHUB: [Basic writing and formatting syntax - GitHub Docs](https://docs.github.com/en/get-started/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax#links)&#x20;

GIT BASH: <https://www.atlassian.com/es/git/tutorials/git-bash>&#x20;

<https://docs.github.com/es/get-started/using-git/about-git>#&#x20;


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://apuntes-alex.gitbook.io/apuntes-sistemas-y-redes/servicios/file-transfer/publicar-una-pagina-web-con-github-pages.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
