How can I override the title of a GitLab wiki page?

I’m runnning GitLab CE. If I name a wiki page “first-last”, the URL is “project/wikis/first-last” and the page title is rendered in sentence case as “First last”. If I name a page “first-(last)”, the URL is “project/wikis/first-(last)” and the page title is rendered in sentence case as “First (last)”.

I want the URL to be “project/wikis/first-last” and the page title to be “First (last)”. Thus, I want to override the page title.

My understanding is that GitLab project wikis run on Gollum. According to the Gollum docs page titles can be overridden with one of two methods:

  1. Enable --h1-title . The first H1-level title on the page will override the page title.
  2. Use the metadata directive. If the first line of the page is <!-- --- title: My page title --> , the given value will override the page title.

I don’t have access to option 1. I tried option 2 and nothing happened.

How can I override the title of a GitLab wiki page?

Originally posted at: https://stackoverflow.com/questions/51419354