[vtk-developers] Stupid git question #1

David E DeMarle dave.demarle at kitware.com
Tue Apr 27 16:48:42 EDT 2010


This means that you've committed something to your index and that has
not been pushed to the remote git hosting server.

git diff --cached will show what it is.

David E DeMarle
Kitware, Inc.
R&D Engineer
28 Corporate Drive
Clifton Park, NY 12065-8662
Phone: 518-371-3971 x109



On Tue, Apr 27, 2010 at 4:44 PM, Bill Lorensen <bill.lorensen at gmail.com> wrote:
> Do not fear, this is not the VTK repository...
>
> I get the message:
>  git status
> # On branch master
> # Your branch is ahead of 'origin/master' by 1 commit.
> #
> nothing to commit (working directory clean)
>
> What does that mean?
>
> On Tue, Apr 27, 2010 at 4:37 PM, Bill Lorensen <bill.lorensen at gmail.com> wrote:
>> It works.
>>
>> Maybe I have messed up my remote repository,
>>
>> Thanks
>>
>>
>> On Tue, Apr 27, 2010 at 4:33 PM, David E DeMarle
>> <dave.demarle at kitware.com> wrote:
>>> Does:
>>>
>>> git checkout Hybrid
>>>
>>> not work?
>>>
>>> On my system it recursively restores the whole Hybrid directory from
>>> my Index into my working directory. Then I am back to where I was
>>> before I "rm -rf"'d it.
>>>
>>> David E DeMarle
>>> Kitware, Inc.
>>> R&D Engineer
>>> 28 Corporate Drive
>>> Clifton Park, NY 12065-8662
>>> Phone: 518-371-3971 x109
>>>
>>>
>>>
>>> On Tue, Apr 27, 2010 at 4:27 PM, Bill Lorensen <bill.lorensen at gmail.com> wrote:
>>>> OK, let we be a bit more specific.
>>>>
>>>> I cloned the VTK repository.
>>>> After a while I did
>>>> git pull
>>>>
>>>> Now I'm up to date.
>>>>
>>>> Now I
>>>> rm -rf Hybrid
>>>>
>>>> How do I get it back!
>>>>
>>>>
>>>> On Tue, Apr 27, 2010 at 4:23 PM, Bill Lorensen <bill.lorensen at gmail.com> wrote:
>>>>> I know they are local.
>>>>>
>>>>> But, if I screwup my local repository, how can I recover files from
>>>>> the noon-local repository.
>>>>>
>>>>> Fortunately for all, I am experimenting with a repository on gitorious...
>>>>>
>>>>> On Tue, Apr 27, 2010 at 4:19 PM, David Cole <david.cole at kitware.com> wrote:
>>>>>> Maybe you should preface your response with "Stupid git *answer* #1"
>>>>>>
>>>>>> Think of it like this, everyone: with cvs, *checkout* and *commit* were
>>>>>> "communicate with the server" commands. Now with git, they are "communicate
>>>>>> with the local repository" commands.
>>>>>> checkout and commit are both now completely local operations. It's
>>>>>> fetch/pull and push that go back-and-forth over the wire now.
>>>>>>
>>>>>> On Tue, Apr 27, 2010 at 4:08 PM, David E DeMarle <dave.demarle at kitware.com>
>>>>>> wrote:
>>>>>>>
>>>>>>> no confusion, checkout will restore a file from the repository.
>>>>>>>
>>>>>>> [kargad:devel/ParaView/VTK] demarle% fif "*.txt" Lorensen
>>>>>>> ./Copyright.txt:Copyright (c) 1993-2008 Ken Martin, Will Schroeder,
>>>>>>> Bill Lorensen
>>>>>>> ./Copyright.txt: * Neither name of Ken Martin, Will Schroeder, or Bill
>>>>>>> Lorensen nor the names
>>>>>>> ./Utilities/Doxygen/authors.txt:lorensen: Lorensen, Bill
>>>>>>> (lorensen at crd.ge.com)
>>>>>>> ./Utilities/EncodeString/CMakeLists.txt:# Copyright (c) Ken Martin,
>>>>>>> Will Schroeder, Bill Lorensen
>>>>>>> ./Utilities/HashSource/CMakeLists.txt:# Copyright (c) Ken Martin, Will
>>>>>>> Schroeder, Bill Lorensen
>>>>>>> ./Utilities/ParseOGLExt/CMakeLists.txt:# Copyright (c) Ken Martin,
>>>>>>> Will Schroeder, Bill Lorensen
>>>>>>> [kargad:devel/ParaView/VTK] demarle% rm Copyright.txt
>>>>>>> [kargad:devel/ParaView/VTK] demarle% rm Utilities/Doxygen/authors.txt
>>>>>>> [kargad:devel/ParaView/VTK] demarle% rm
>>>>>>> Utilities/EncodeString/CMakeLists.txt
>>>>>>> [kargad:devel/ParaView/VTK] demarle% rm
>>>>>>> Utilities/HashSource/CMakeLists.txt
>>>>>>> [kargad:devel/ParaView/VTK] demarle% rm
>>>>>>> Utilities/ParseOGLExt/CMakeLists.txt
>>>>>>> [kargad:devel/ParaView/VTK] demarle% fif "*.txt" Lorensen
>>>>>>> [kargad:devel/ParaView/VTK] demarle% git checkout Copyright.txt
>>>>>>> [kargad:devel/ParaView/VTK] demarle% fif "*.txt" Lorensen
>>>>>>> ./Copyright.txt:Copyright (c) 1993-2008 Ken Martin, Will Schroeder,
>>>>>>> Bill Lorensen
>>>>>>> ./Copyright.txt: * Neither name of Ken Martin, Will Schroeder, or Bill
>>>>>>> Lorensen nor the names
>>>>>>>
>>>>>>> David E DeMarle
>>>>>>> Kitware, Inc.
>>>>>>> R&D Engineer
>>>>>>> 28 Corporate Drive
>>>>>>> Clifton Park, NY 12065-8662
>>>>>>> Phone: 518-371-3971 x109
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On Tue, Apr 27, 2010 at 3:56 PM, Bill Lorensen <bill.lorensen at gmail.com>
>>>>>>> wrote:
>>>>>>> > I'm not using the correct terminology I think.
>>>>>>> >
>>>>>>> > I have cloned a repository.
>>>>>>> > By accident I changed or deleted a file.
>>>>>>> > How do I get a copy of that file from the cloned repository?
>>>>>>> >
>>>>>>> > Bill
>>>>>>> >
>>>>>>> > On Tue, Apr 27, 2010 at 3:49 PM, David E DeMarle
>>>>>>> > <dave.demarle at kitware.com> wrote:
>>>>>>> >> git checkout path/to/file
>>>>>>> >>
>>>>>>> >> David E DeMarle
>>>>>>> >> Kitware, Inc.
>>>>>>> >> R&D Engineer
>>>>>>> >> 28 Corporate Drive
>>>>>>> >> Clifton Park, NY 12065-8662
>>>>>>> >> Phone: 518-371-3971 x109
>>>>>>> >>
>>>>>>> >>
>>>>>>> >>
>>>>>>> >> On Tue, Apr 27, 2010 at 3:42 PM, Bill Lorensen
>>>>>>> >> <bill.lorensen at gmail.com> wrote:
>>>>>>> >>> If I accidentally  delete or modify  a file in my local repository,
>>>>>>> >>> how can I undelete it. I want the equivalent of
>>>>>>> >>> cvs update -C
>>>>>>> >>>
>>>>>>> >>> Bill
>>>>>>> >>> _______________________________________________
>>>>>>> >>> Powered by www.kitware.com
>>>>>>> >>>
>>>>>>> >>> Visit other Kitware open-source projects at
>>>>>>> >>> http://www.kitware.com/opensource/opensource.html
>>>>>>> >>>
>>>>>>> >>> Follow this link to subscribe/unsubscribe:
>>>>>>> >>> http://www.vtk.org/mailman/listinfo/vtk-developers
>>>>>>> >>>
>>>>>>> >>>
>>>>>>> >>
>>>>>>> >
>>>>>>> _______________________________________________
>>>>>>> Powered by www.kitware.com
>>>>>>>
>>>>>>> Visit other Kitware open-source projects at
>>>>>>> http://www.kitware.com/opensource/opensource.html
>>>>>>>
>>>>>>> Follow this link to subscribe/unsubscribe:
>>>>>>> http://www.vtk.org/mailman/listinfo/vtk-developers
>>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>
>>>
>>
>



More information about the vtk-developers mailing list