skip to Main Content

Some time ago, I was able to verify my blog at blogspot.com, and published packages on Pub.dev under that publisher. Recently, I decided to switch to a GitHub page, as it is a lot better from the version control perspective as well as gives a lot more flexibility in content creation. However, I’m unable to verify my GitHub page: Pub.dev requires domain verification, and I’m lost in endless attempts to find the DNS configuration page where I could paste a TXT record issued by the Google Search Console. I also thought that there could be a file with a special name in the root directory of my GitHub site which is supposed to hold that info. But I didn’t find anything like that.

Is this achievable at all? I don’t want to associate another domain with my GitHub page, as this adds no value. I tried to point my blogspot.com page to the GitHub one but did not succeed either. Why is it made so hard to do the most obvious thing: to link a Pub.dev publisher to a GitHub page? Especially, given that the most repos are hosted by GitHub anyway. Or maybe this feature is available for the paid GitHub accounts only?

Thanks in advance for your response.

2

Answers


  1. Chosen as BEST ANSWER

    At the moment, the best solution I came up with is to add

    <meta content='0; url=https://username.github.io/' http-equiv='refresh'/>

    to my Blogspot theme's HTML as well as replace the top (single) post's content with

    <h2>
        <p>
            This blog has been moved to
        </p>
        <p>
            <a href="https://username.github.io/">https://username.github.io/</a>
        </p>
        <p>
            Redirecting...
        </p>
    </h2>
    

    Not very elegant but allows me to avoid doubling the maintenance and to focus on the GitHub page. By verifying the GitHub Page's prefix URL in Google Search Console, I made that searchable.

    However, on the Pub.dev side, it still shows publisher as username.blogspot.com, and when someone goes to the publisher details and click a similar link, they eventually get re-directed to the GitHub page. Better than nothing.


  2. Verified publishers on pub.dev require that you own your own domain name. A subdomain will not suffice.

    From https://pub.dev/create-publisher (sign-in required):

    The user account creating a publisher must be the verifier of the domain property – not just a verifier of a URL prefix property – or a collaborator on a property that someone else has verified.

    Once you’ve paid for your own domain name, you should be able to set the TXT record through your domain registrar.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search