# no --dry-run to git-pull ?

4 messages from 2008-07-04 to 2008-07-04. Participants: Neshama Parhoti, Miklos Vajna.
Thread: https://gitlist.dev/t/14288

## Neshama Parhoti, 2008-07-04 13:56

Subject: no --dry-run to git-pull ?
Message-ID: <912ec82a0807040656y1c48cba8m6f9981f6bb97b36a@mail.gmail.com>
URL: https://gitlist.dev/e/912ec82a0807040656y1c48cba8m6f9981f6bb97b36a%40mail.gmail.com

```
Hi,

Isn't there a way to do a --dry-run with git-pull ?

Thank you,
pnesh

```

## Miklos Vajna, 2008-07-04 13:59

Subject: Re: no --dry-run to git-pull ?
Message-ID: <20080704135944.GA4729@genesis.frugalware.org>
URL: https://gitlist.dev/e/20080704135944.GA4729%40genesis.frugalware.org
In-Reply-To: <912ec82a0807040656y1c48cba8m6f9981f6bb97b36a@mail.gmail.com>

```
On Fri, Jul 04, 2008 at 04:56:27PM +0300, Neshama Parhoti <pneshama@gmail.com> wrote:
> Isn't there a way to do a --dry-run with git-pull ?

Not really. But you can do a 'git fetch origin', then a
'git log master..origin/master', and it'll tell you what changes will be
merged if you do a 'git merge origin/master'.

NOTES:

1) Replace origin and master with your repomte and branch.

2) If this sounds cryptic for you, then it might be an important info
that by default a pull is a fetch + a merge.

```

## Neshama Parhoti, 2008-07-04 15:26

Subject: Re: no --dry-run to git-pull ?
Message-ID: <912ec82a0807040826v64afcc55i646d9c73b6fa8cd0@mail.gmail.com>
URL: https://gitlist.dev/e/912ec82a0807040826v64afcc55i646d9c73b6fa8cd0%40mail.gmail.com
In-Reply-To: <20080704135944.GA4729@genesis.frugalware.org>

```
On Fri, Jul 4, 2008 at 4:59 PM, Miklos Vajna <vmiklos@frugalware.org> wrote:
> On Fri, Jul 04, 2008 at 04:56:27PM +0300, Neshama Parhoti <pneshama@gmail.com> wrote:
>> Isn't there a way to do a --dry-run with git-pull ?
>
> Not really. But you can do a 'git fetch origin', then a
> 'git log master..origin/master', and it'll tell you what changes will be
> merged if you do a 'git merge origin/master'.
>
> NOTES:
>
> 1) Replace origin and master with your repomte and branch.
>
> 2) If this sounds cryptic for you, then it might be an important info
> that by default a pull is a fetch + a merge.

What puzzles me is the origin keyword. Is it set only if I initially
cloned a repo ?
Because in my case, I have just rsync'ed a repo to another station, so
I fear it will have no meaning in my case.
Thank you
>

```

## Miklos Vajna, 2008-07-04 15:29

Subject: Re: no --dry-run to git-pull ?
Message-ID: <20080704152915.GD4729@genesis.frugalware.org>
URL: https://gitlist.dev/e/20080704152915.GD4729%40genesis.frugalware.org
In-Reply-To: <912ec82a0807040826v64afcc55i646d9c73b6fa8cd0@mail.gmail.com>

```
On Fri, Jul 04, 2008 at 06:26:02PM +0300, Neshama Parhoti <pneshama@gmail.com> wrote:
> > 1) Replace origin and master with your remote and branch.
> >
> > 2) If this sounds cryptic for you, then it might be an important info
> > that by default a pull is a fetch + a merge.
> 
> What puzzles me is the origin keyword. Is it set only if I initially
> cloned a repo ?
> Because in my case, I have just rsync'ed a repo to another station, so
> I fear it will have no meaning in my case.

Heh. git remote add -f origin <url>, then you'll have it. And yes, you
have it if you cloned the repo, of course rsync won't add it. ;-)

```
