General method for the synthesis of indoles