Skip to content

ufz/styleguide

Repository files navigation

OpenGeoSys C++ Style Guide

This styleguide is derived from the Google C++ Style Guide. Some modifications were made to match the OpenGeoSys development needs.

Automatically apply this guide

This guide comes with a configuration file for the uncrustify automatic code styler. With this tool you can restyle your source code according to this styleguide. The config file is not finished yet. For creating the config file the UniversalIndentGUI was used.

To reformat your code:

  • Install uncrustify

  • Download the configuration file

  • Download the uncrustify.sh script

  • Run the script on your code:

      uncrustify.sh [Path to your code directory] [file extension]
      E.g for header files: uncrustify.sh sources/ h
      E.g for source files: uncrustify.sh sources/ cpp