Measurements of the branching fractions and CP asymmetries of B-+/- -> J/psi pi(+/-) and B-+/- -> psi(2S)pi(+/-) decays