Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: ✏️ Change orgremote to upstream and clarify instructions #191

Merged
merged 1 commit into from
May 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 12 additions & 6 deletions docs/src/90-developer.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,24 +33,30 @@ pre-commit run -a

## First time clone

!!! note "If you have writing rights"
If you have writing rights, you don't have to fork. Instead, simply clone and skip ahead. Whenever **upstream** is mentioned, use **origin** instead.

If this is the first time you work with this repository, follow the instructions below to clone the repository.

1. Fork this repo
2. Clone your repo (this will create a `git remote` called `origin`)
3. Add this repo as a remote:

```bash
git remote add orgremote https://github.com/abelsiqueira/COPIERTemplate.jl
git remote add upstream https://github.com/abelsiqueira/COPIERTemplate.jl
```

This will ensure that you have two remotes in your git: `origin` and `upstream`.
You will create branches and push to `origin`, and you will fetch and update your local `main` branch from `upstream`.

## Working on a new issue

1. Fetch from the JSO remote and fast-forward your local main
1. Fetch from the remote and fast-forward your local main

```bash
git fetch orgremote
git fetch upstream
git switch main
git merge --ff-only orgremote/main
git merge --ff-only upstream/main
```

2. Branch from `main` to address the issue (see below for naming)
Expand Down Expand Up @@ -88,8 +94,8 @@ If this is the first time you work with this repository, follow the instructions
- Fetch any `main` updates from upstream and rebase your branch, if necessary:

```bash
git fetch orgremote
git rebase orgremote/main BRANCH_NAME
git fetch upstream
git rebase upstream/main BRANCH_NAME
```

- Then you can open a pull request and work with the reviewer to address any issues.
Expand Down
18 changes: 12 additions & 6 deletions template/docs/src/90-developer.md.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -33,24 +33,30 @@ pre-commit run -a

## First time clone

!!! note "If you have writing rights"
If you have writing rights, you don't have to fork. Instead, simply clone and skip ahead. Whenever **upstream** is mentioned, use **origin** instead.

If this is the first time you work with this repository, follow the instructions below to clone the repository.

1. Fork this repo
2. Clone your repo (this will create a `git remote` called `origin`)
3. Add this repo as a remote:

```bash
git remote add orgremote https://github.com/{{ PackageOwner }}/{{ PackageName }}.jl
git remote add upstream https://github.com/{{ PackageOwner }}/{{ PackageName }}.jl
```

This will ensure that you have two remotes in your git: `origin` and `upstream`.
You will create branches and push to `origin`, and you will fetch and update your local `main` branch from `upstream`.

## Working on a new issue

1. Fetch from the JSO remote and fast-forward your local main
1. Fetch from the remote and fast-forward your local main

```bash
git fetch orgremote
git fetch upstream
git switch main
git merge --ff-only orgremote/main
git merge --ff-only upstream/main
```

2. Branch from `main` to address the issue (see below for naming)
Expand Down Expand Up @@ -88,8 +94,8 @@ If this is the first time you work with this repository, follow the instructions
- Fetch any `main` updates from upstream and rebase your branch, if necessary:

```bash
git fetch orgremote
git rebase orgremote/main BRANCH_NAME
git fetch upstream
git rebase upstream/main BRANCH_NAME
```

- Then you can open a pull request and work with the reviewer to address any issues.
Expand Down
Loading