Update 'Keep your fork updated' instructions
This commit is contained in:
@@ -27,19 +27,19 @@ git remote -v
|
|||||||
|
|
||||||
again you should get:
|
again you should get:
|
||||||
|
|
||||||
> upstream git@github.com:consuldemocracy/consuldemocracy.git (fetch)\
|
|
||||||
> upstream git@github.com:consuldemocracy/consuldemocracy.git (push)\
|
|
||||||
> origin git@github.com:your_user_name/consuldemocracy.git (fetch)\
|
> origin git@github.com:your_user_name/consuldemocracy.git (fetch)\
|
||||||
> origin git@github.com:your_user_name/consuldemocracy.git (push)
|
> origin git@github.com:your_user_name/consuldemocracy.git (push)\
|
||||||
|
> upstream git@github.com:consuldemocracy/consuldemocracy.git (fetch)\
|
||||||
|
> upstream git@github.com:consuldemocracy/consuldemocracy.git (push)
|
||||||
|
|
||||||
## Pulling changes from Consul Democracy
|
## Pulling changes from Consul Democracy
|
||||||
|
|
||||||
Start by creating a branch named **upstream** from your **master** branch to apply Consul Democracy changes:
|
Start by creating a branch named **upgrade** from your **master** branch to apply Consul Democracy changes:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git checkout master
|
git checkout master
|
||||||
git pull
|
git pull
|
||||||
git checkout -b upstream
|
git checkout -b upgrade
|
||||||
```
|
```
|
||||||
|
|
||||||
Then we can fetch all changes from the **Consul Democracy** remote server with:
|
Then we can fetch all changes from the **Consul Democracy** remote server with:
|
||||||
@@ -52,7 +52,7 @@ And then you can choose to either:
|
|||||||
|
|
||||||
A. Get all the latest changes on Consul Democracy's **master** branch with `git merge upstream/master`.
|
A. Get all the latest changes on Consul Democracy's **master** branch with `git merge upstream/master`.
|
||||||
|
|
||||||
B. Just update up to an specific release tag (so you can do incremental updates if you're more than one release behind). For example to update up to [v0.9](https://github.com/consuldemocracy/consuldemocracy/releases/tag/v0.9) release just: `git merge v0.9`.
|
B. Just update up to an specific release tag (so you can do incremental updates if you're more than one release behind). For example to update up to [1.3.0](https://github.com/consuldemocracy/consuldemocracy/releases/tag/1.3.0) release just: `git merge 1.3.0`.
|
||||||
|
|
||||||
## Merging changes
|
## Merging changes
|
||||||
|
|
||||||
@@ -60,10 +60,10 @@ After the previous section `merge` command, there are three possible outcomes:
|
|||||||
|
|
||||||
A. You get a nice `Already up-to-date.` response. That means your fork is up to date with Consul Democracy 😊👌.
|
A. You get a nice `Already up-to-date.` response. That means your fork is up to date with Consul Democracy 😊👌.
|
||||||
|
|
||||||
B. You get a screen on your git configured editor showing the commit message `Merge remote-tracking branch 'upstream/master' into upstream`. That means git was able to grab latest changes from Consul Democracy's master branch, and it can merge them without code change conflicts. Finish the commit.
|
B. You get a screen on your git configured editor showing the commit message `Merge remote-tracking branch 'upstream/master' into upgrade`. That means git was able to grab latest changes from Consul Democracy's master branch, and it can merge them without code change conflicts. Finish the commit.
|
||||||
|
|
||||||
C. You get some git errors along with a `Automatic merge failed; fix conflicts and then commit the result.` message. That means there are conflicts between the code changes you did and the ones done on Consul Democracy repository since the last time you update it. That's the main reason we strongly recommend often updates of your fork (think at least monthly). Resolve merge conflicts carefully and commit them.
|
C. You get some git errors along with a `Automatic merge failed; fix conflicts and then commit the result.` message. That means there are conflicts between the code changes you did and the ones done on Consul Democracy repository since the last time you update it. That's the main reason we strongly recommend often updates of your fork (think at least monthly). Resolve merge conflicts carefully and commit them.
|
||||||
|
|
||||||
Now you can just simply push your **upstream** branch to github and create a Pull Request so you can easily check all changes going into your repo, and see your tests suite runs.
|
Now you can just simply push your **upgrade** branch to github and create a Pull Request so you can easily check all changes going into your repo, and see your tests suite runs.
|
||||||
|
|
||||||
Remember you can always quickly check changes that will come from Consul Democracy to your fork by replacing **your_org_name** on the url: <https://github.com/your_org_name/consuldemocracy/compare/master...consuldemocracy:master>.
|
Remember you can always quickly check changes that will come from Consul Democracy to your fork by replacing **your_org_name** on the url: <https://github.com/your_org_name/consuldemocracy/compare/master...consuldemocracy:master>.
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
# Manten tu fork actualizado
|
# Mantén tu fork actualizado
|
||||||
|
|
||||||
## Configura tus servidores remotos de git
|
## Configura tus servidores remotos de git
|
||||||
|
|
||||||
@@ -25,24 +25,24 @@ comprueba de nuevo que con:
|
|||||||
git remote -v
|
git remote -v
|
||||||
```
|
```
|
||||||
|
|
||||||
deberías recibir algo como:
|
deberías ver algo como:
|
||||||
|
|
||||||
> upstream git@github.com:consuldemocracy/consuldemocracy.git (fetch)\
|
|
||||||
> upstream git@github.com:consuldemocracy/consuldemocracy.git (push)\
|
|
||||||
> origin git@github.com:your_user_name/consuldemocracy.git (fetch)\
|
> origin git@github.com:your_user_name/consuldemocracy.git (fetch)\
|
||||||
> origin git@github.com:your_user_name/consuldemocracy.git (push)
|
> origin git@github.com:your_user_name/consuldemocracy.git (push)\
|
||||||
|
> upstream git@github.com:consuldemocracy/consuldemocracy.git (fetch)\
|
||||||
|
> upstream git@github.com:consuldemocracy/consuldemocracy.git (push)
|
||||||
|
|
||||||
## Obteniendo cambios de Consul Democracy
|
## Obteniendo cambios de Consul Democracy
|
||||||
|
|
||||||
Empieza creando una rama **upstream** a partir de tu rama **master** sobre la que trabajar:
|
Empieza creando una rama **upgrade** a partir de tu rama **master** sobre la que trabajar:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git checkout master
|
git checkout master
|
||||||
git pull
|
git pull
|
||||||
git checkout -b upstream
|
git checkout -b upgrade
|
||||||
```
|
```
|
||||||
|
|
||||||
Y actualiza la información del repositorio de Consul Democracy con las referencias a las ramas, tags, etc..:
|
Y actualiza la información del repositorio de **Consul Democracy** con las referencias a las ramas, tags, etc..:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git fetch upstream
|
git fetch upstream
|
||||||
@@ -52,18 +52,18 @@ Y por fin puedes elegir entre:
|
|||||||
|
|
||||||
A. Actualizar con los últimos cambios de la rama **master** usando `git merge upstream/master`
|
A. Actualizar con los últimos cambios de la rama **master** usando `git merge upstream/master`
|
||||||
|
|
||||||
B. Sólo actualizar hasta cierta versión (en el caso de que prefieras actualizar de forma incremental, si estas varias versiones por detrás). Por ejemplo para actualizarte a la versión [v0.9](https://github.com/consuldemocracy/consuldemocracy/releases/tag/v0.9) utilizamos el tag asociado: `git merge v0.9`
|
B. Sólo actualizar hasta cierta versión (en el caso de que prefieras actualizar de forma incremental, si estás varias versiones por detrás). Por ejemplo para actualizarte a la versión [1.3.0](https://github.com/consuldemocracy/consuldemocracy/releases/tag/1.3.0) utilizamos el tag asociado: `git merge 1.3.0`
|
||||||
|
|
||||||
## Fusionando cambios
|
## Fusionando cambios
|
||||||
|
|
||||||
Tras el `merge` de la anterior sección, hay tres posibles escenarios:
|
Tras el `merge` de la anterior sección, hay tres posibles escenarios:
|
||||||
|
|
||||||
A. Obtienes una respuesta `Already up-to-date.`. Eso significa que tu fork esta al dia con los cambios de Consul Democracy 😊👌
|
A. Obtienes una respuesta `Already up-to-date.`. Eso significa que tu fork esta al día con los cambios de Consul Democracy 😊👌
|
||||||
|
|
||||||
B. Se abre una ventana del editor que tengas configurado en git, mostrando el mensaje de commit `Merge remote-tracking branch 'upstream/master' into upstream`. Esto significa que git fue capaz de mezclar los cambios de Consul Democracy sobre tu código sin encontrar problemas o conflictos. Termina el commit.
|
B. Se abre una ventana del editor que tengas configurado en git, mostrando el mensaje de commit `Merge remote-tracking branch 'upstream/master' into upgrade`. Esto significa que git fue capaz de mezclar los cambios de Consul Democracy sobre tu código sin encontrar problemas o conflictos. Termina el commit.
|
||||||
|
|
||||||
C. Recibes mensajes de error de git junto con un `Automatic merge failed; fix conflicts and then commit the result.`. Esto significa que se han encontrado conflictos entre los cambios en tu código y los cambios que se realizaron en Consul Democracy desde la última vez que actualizaste tu fork. Esta es una de las principales razones para intentar mantener tu fork lo más al dia posible, realizando este proceso al menos mensualmente. Resuelve manualmente los conflictos para terminar el merge y haz un commit.
|
C. Recibes mensajes de error de git junto con un `Automatic merge failed; fix conflicts and then commit the result.`. Esto significa que se han encontrado conflictos entre los cambios en tu código y los cambios que se realizaron en Consul Democracy desde la última vez que actualizaste tu fork. Esta es una de las principales razones para intentar mantener tu fork lo más al día posible, realizando este proceso al menos mensualmente. Resuelve manualmente los conflictos para terminar el merge y haz un commit.
|
||||||
|
|
||||||
Ahora simplemente sube la rama **upstream** a github y crea un Pull Request, así podrás ver de manera sencilla todos los cambios que se han realizado en el repositorio y verás también como arranca la suite de tests.
|
Ahora simplemente sube la rama **upgrade** a github y crea un Pull Request. Así podrás ver de manera sencilla todos los cambios que se han realizado en el repositorio y verás también cómo arranca la suite de tests.
|
||||||
|
|
||||||
Recuerda que siempre puedes comprobar rápidamente los cambios que tienes pendientes de integrar de Consul Democracy a tu fork sustituyendo **your_org_name** en la url: <https://github.com/your_org_name/consuldemocracy/compare/master...consuldemocracy:master>
|
Recuerda que siempre puedes comprobar rápidamente los cambios que tienes pendientes de integrar de Consul Democracy a tu fork sustituyendo **your_org_name** en la url: <https://github.com/your_org_name/consuldemocracy/compare/master...consuldemocracy:master>
|
||||||
|
|||||||
Reference in New Issue
Block a user