This work reports on the development and numerical implementation of the linear electromagnetic gyrokinetic (GK) model in a tokamak flux-tube geometry using a moment approach based on the expansion of the perturbed distribution function on a velocity-space Hermite–Laguerre polynomials basis. A hierarchy of equations of the expansion coefficients, referred to as the gyro-moments (GMs), is derived. We verify the numerical implementation of the GM hierarchy in the collisionless limit by performing a comparison with the continuum GK code GENE, recovering the linear properties of the ion temperature gradient, trapped electron, kinetic ballooning and microtearing modes, as well as the collisionless damping of zonal flows. An analysis of the distribution functions and ballooning eigenmode structures is performed. The present investigation reveals the ability of the GM approach to describe fine velocity-space-scale structures appearing near the trapped and passing boundary and kinetic effects associated with parallel and perpendicular particle drifts. In addition, the effects of collisions are studied using advanced collision operators, including the GK Coulomb collision operator. The main findings are that the number of GMs necessary for convergence decreases with plasma collisionality and is lower for pressure gradient-driven modes, such as in H-mode pedestal regions, compared with instabilities driven by trapped particles and magnetic gradient drifts often found in the core. The accuracy of approximations often used to model collisions (relative to the GK Coulomb operator) is studied in the case of trapped electron modes, showing differences between collision operator models that increase with collisionality and electron temperature gradient, consistent with the results of Pan et al. (Phys. Rev. E, vol. 103, 2021, L051202). Such differences are not observed in other edge microinstabilities, such as microtearing modes. The importance of a proper collision operator model is also confirmed by analysing the collisional damping of geodesic acoustic modes and zonal flows.