Start by examining how existing file type analyzers are implemented in OpenGrok, particularly in the AnalysisFactory class (e.g., in the source code at https://github.com/oracle/opengrok). Look at the addition of a new Analyzer for a file type, such as how 'xml' or 'json' are handled. Then, create a YANG analyzer that reads the file extension and provides syntax highlighting. No linked PR or comments exist, so the issue is open for contribution.