Apparently there is a notion of for example a $G$-connection on a discrete set. I've understood that this is a standard tool in for example lattice gauge theory. I'm looking for references to learn more about this (i.e. discrete 1-forms, connections, etc.) in the discrete setting.

More specifically, suppose I have a set $V$ of vertices and a set $E$ of directed edges. Let $G$ be a finite (perhaps non-abelian) group. What is the right notion of $G$-connection on $(V,E)$? Is there some classification of connections? In particular, I suppose it might matter if the directed graph can be drawn on a torus or on a sphere (or the plane).

Any references to literature where the basic notions are described is greatly appreciated.