Config Atom with Mac OS Terminal

The code I found [git config --global core.editor “atom --wait”], but it does not allow me to commit my staging index. Please help.