If I used a single ignore at the top level with the lines:

  bin
  target

these would match in *every* subdirectory within the entire repository.  Thus a source package called "bin" or "target" would be omitted, which may lead a contributor to forget to git add something they have created.

The only safe way to force limit these to the top of each plugin directory is to use a leading "/" as I have done.  I could use an identical file in each plugin (as this patch does), or I could have used a single top-level file with every plugin:

  /org.eclipse.jgit/bin
  /org.eclipse.jgit/target
  /org.eclipse.jgit.test/bin
  /org.eclipse.jgit.test/target

Either form is ugly, but using the identical file makes it easier to setup a new project as you just need to cp .gitignore.