Thin films of highly oriented pyrolytic graphite (HOPG) give the opportunity to realize crystal optics with arbitrary geometry by mounting it on a mould of any shape. A specific feature of HOPG is its mosaicity accompanied by a high integral reflectivity, which is by an order of magnitude higher than that of all other known crystals in an energy range between 2 keV up to several 10 keV. These characteristics make it possible to realize highly efficient collecting optics, which could be also relevant for compact x-ray diagnostic tools and spectrometers. For these applications the achievable spectral resolution of the crystal optics is of interest. In this article measurements with a spectral resolution of E/DeltaE=2900 in the second order reflection and E/DeltaE=1800 in the first order reflection obtained with HOPG crystals are presented. These are by far the highest spectral resolutions reported for HOPG crystals. The integral reflectivity of these very thin films is still comparable with that of ideal Ge crystals. The trade-off between energy resolution and high integral reflectivity for HOPG is demonstrated by determining these parameters for HOPG films of different thickness.