Trying to setup a new editor in git

I’m trying to find a good alternative to the VI editor that comes with my git version 1.8.0.msysgit.0 installed on my windows XP box. I’ve looked through the forums here and tried some of their suggestions. I must be missing something because they aren’t working for me. I’ve tried this from the git command line:

git config --global core.editor "'C:/Program Files/Notepad++/notepad++.exe' -multiInst"

I also tried another way that used a shell. There I created a folder named shell on the root of C: I then created a sh file named npp.sh with this content:

  • Cordova: Exclude plugins and platforms
  • git squashing multiple commits into multiple commits
  • How to push an existing projects in new Github repository?
  • Why is GitHub so much faster than a self hosted repository?
  • How do I omit certain files from the `git status` report?
  • Why does Xcode 4 continually display “Checking source control status” for a git repository?
  • #!/bin/sh
    "c:/Program Files/Notepad++/notepad++.exe" -multiInst "$*"
    

    after that I entered this command:

    git config --global core.editor C:/shell/npp.sh
    

    In both cases if I enter notepad++ on the git command line I get the message sh.exe": notepad++: command not found.

  • Cloning public repository on GitHub using SourceTree
  • Git push error: ssh: Could not resolve hostname domain.com: nodename nor servname provided, or not known
  • Why does Git use a cryptographic hash function?
  • Mirroring certain files/directories of a git repository
  • How do I make my git branch into the master without merging?
  • How to run Git commands on remote repository
  • One Solution collect form web for “Trying to setup a new editor in git”

    This turns out to be surprisingly difficult. /c/Program\ Files/Notepad++/notepad++.exe executes fine from Git bash, but doesn’t seem to work with git config core.editor.

    However, you can create a Bash alias for Notepad++ and use that as your core.editor. See this answer for details.

    Git Baby is a git and github fan, let's start git clone.