see fwded msg below, my msg, then answer. -Nalin ---------- Forwarded message ---------- From: Nalin Savara <[email protected]> Date: Sun, 27 Jan 2013 08:29:36 +0530 Subject: Fwd: [ilugd] a question about GIT To: [email protected]
Hiya Friends... Fwded below is a mail... With answer to a question I asked about GIT. Relevant because this is a common use case and various git commands seem to be available like rename, rebase, etc.... and sometimes its not obvious what to do. Seems the answerer wasnt subscribed to this list-- hence his mail didnt reach the list. Hope this helps.... Regards, -Nalin ---------- Forwarded message ---------- From: ragsagar <[email protected]> Date: Sat, 26 Jan 2013 15:22:46 +0530 Subject: Re: [ilugd] a question about GIT To: Nalin Savara <[email protected]> Cc: Linux Delhi <[email protected]>, The Linux-Delhi mailing list <[email protected]> On Sat, Jan 26, 2013 at 3:07 PM, Nalin Savara <[email protected]> wrote: > Hi People... > > A few questions:-- > > (1) I have a git repository that's organized as: > [repository-name]/nalinFolder > There are around 20 subfolders in it-- and around 200 files-- and 10-15 > commits have been done. > > (2) I want to change the structure slightly... and after that add more > files and folders. > I want the new structure to be: > > [repository-name]/[folder1]/[folder2]/nalinFolder > ANd I want to do this while preserving the commits and comments with > commits. > > git mv nalinfolder folder1/folder2 git commit -m "Moved nalinfolder" > (3) > And after I have moved the "nalinFolder" to be a directory > repos-name/folder1/folder2 --->> I will add more files and folders to > repos-name and folder1 --> which are not yet under version control > > What are the GIT commands/steps to achieve the above ? > > I didn't understand what you want to achieve here. If you want to add more files and directories. Add them using `git add` and commit. -- blog : ragsagar.wordpress.com mail id : python -c "print '@'.join(['ragsagar','.'.join([x for x in ['gmail','com']])])" -- -- Mailing list guidelines and other related articles: http://lug-iitd.org/Footer
