A generalized Gray map for codes over the ring Fq[u]/ is introduced, where q=pm is a prime power. It is shown that the generalized Gray image of a linear length-N (1-ut)-cyclic code over Fq[u]/ is a distance-invariant linear length-qtN quasi-cyclic code of index qt/p over Fq. It turns out that if (N,p)=1 then every linear code over Fq that is the generalized Gray image of a length-N cyclic code over Fq[u]/, is also equivalent to a linear length-qtN quasi-cyclic code of index qt/p over Fq. The relationship between linear length-pN cyclic codes with (N,p)=1 over Fp and linear length-N cyclic codes over Fp+uFp is explicitly determined.