Spin-orbit coupling of planetary systems plays an important role in the dynamics and habitability of planets. However, symplectic integrators that can accurately simulate not only how orbit affects spin but also how spin affects orbit have not been constructed for general systems. Thus, we develop symplectic Lie-group integrators to simulate systems consisting gravitationally interacting rigid bodies. A user friendly package (GRIT) is provided and external forcing such as tidal interactions are also included. As a demonstration, this package is applied to Trappist-I. It shows that the differences in transit timing variations due to spin-orbit coupling could reach a few min in ten year measurements, and strong planetary perturbations can push Trappist-I f, g and h out of the synchronized states.