Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jgit-dev] "git mv" with jgit?

> Git has an 'mv' command that makes it possible to move or renames files and
> folders with retained history. How can I accomplish the same thing using
> jgit?

Hi,

the mv command is currently beeing added to the jgit api (see
http://egit.eclipse.org/r/#change,4790). But be aware that you don't
need the 'git mv' command to achieve what you want. See this
discussion: http://stackoverflow.com/questions/1094269/whats-the-purpose-of-git-mv

See here: http://egit.eclipse.org/w/?p=jgit.git;a=blob;f=org.eclipse.jgit.test/tst/org/eclipse/jgit/diff/RenameDetectorTest.java;hb=refs/heads/master
for some examples in JGit.

Ciao
  Chris


Back to the top