Commit ccacf1a7 authored by paugier's avatar paugier
Browse files

Github and Heptapod workflows

parent 2372bead
Pipeline #50754 passed with stage
in 43 seconds
......@@ -933,5 +933,86 @@
latexmk -pdf -pdflatex="$(LATEX)" $(name).tex
```
%% Cell type:markdown id: tags:
## Mercurial configuration files
Simple text files... They can be edited with any text editors.
- `~/.hgrc` (per user)
If you don't have this file, you can create a reasonable conf. file with `hg config --edit`. See https://fluiddyn.readthedocs.io/en/latest/mercurial_heptapod.html#set-up-mercurial. This file contains in particular the list of activated Mercurial extensions.
- `my_repo/.hg/hgrc` (per repo)
This file contains in particular the path from which to pull/push by default. Something like:
```
[paths]
default = ssh://hg@foss.heptapod.net/fluiddyn/transonic
```
To work with hg-git, it is convenient to have something like:
```
[paths]
default = git@github.com:paugier/pythran.git
upstream = https://github.com/serge-sans-paille/pythran.git
```
%% Cell type:markdown id: tags:
## Classical Github / Gitlab workflow
%% Cell type:raw id: tags:
<div align="middle">
<img src="./fig/schemes_hggit/github_workflow.png" style="width: 50%; margin-top: 20px; margin-bottom: -10px; margin-left: 20px;">
</div>
%% Cell type:markdown id: tags:
Git branches are really like "bookmarks" that can be located on commits. In Mercurial, such things are called "bookmarks".
To create a Git branch in your remote forked repository, one can do:
```bash
hg pull upstream
hg up master
hg bookmark my-fix-or-new-feature
hg commit
# ...
hg push -B my-fix-or-new-feature
```
Then, one can create the Pull Request (Github) or Merge Request (Gitlab).
%% Cell type:markdown id: tags:
## Heptapod workflow (without forks)
%% Cell type:raw id: tags:
<div align="middle">
<img src="./fig/schemes_hggit/heptapod_workflow.png" style="width: 50%; margin-top: 20px; margin-bottom: -10px; margin-left: 20px;">
</div>
%% Cell type:markdown id: tags:
Mercurial feature branches are called "topics".
To create a Merge Request in the remote repository, one can do:
```bash
hg pull
hg up default
hg topic my-fix-or-new-feature
hg commit
# ...
hg push
```
......
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment