Remove "by [username]" in github document.title pages

I have a github pages site for my company and I dont want to use raw html to develop the site because no developers on my team will push.

The problem is that it document.title

contains "by organization name" at the end. I want to remove this and just make it initial.

I already tried title: [custom title]

in jekyll and it still has the organization name at the end.

I am using the Midnight theme.

My repo is at https://git.io/vQpxz and the site is at http://thebclickteam.tk .

Thank!

+3


source to share


1 answer


As pointed out in the comments, you are using jekyll-midnight-theme , copy the default layout file in the repository jekyll-theme-midnight

to a directory _layouts

on your Jekyll website.

Now edit /_layouts/default.html

and edit the <title>

HTML tag , in this case remove the "by" part so that this:

 <title>{{ site.title | default: site.github.repository_name }} by {{ site.github.owner_name }}</title>

      



replace it with:

  <title>{{ site.title | default: site.github.repository_name }}</title>

      

Now your site will not include "by organization name" at the end.

+2


source







All Articles