Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update github-pages.qmd to include instructions for custom domains #1298

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

jdfoote
Copy link

@jdfoote jdfoote commented Aug 20, 2024

Adding instructions for publishing to custom domains.

Adding instructions for publishing to custom domains.
@@ -103,6 +103,21 @@ If you are publishing to a private (i.e. password protected) website then the lo
quarto publish gh-pages --no-browser
```

#### Custom Domains

There are a few steps you will need to take to publish to a custom domain. First, [set up a CNAME record](https://docs.github.com/en/pages/configuring-a-custom-domain-for-your-github-pages-site/managing-a-custom-domain-for-your-github-pages-site#configuring-a-subdomain) with your DNS provider. Next, in the Github repository for your site, edit the domain (Settings > Pages > Custom Domain). Then, add a file called CNAME to the root directory of your project. The only content of the file is the custom domain (e.g., `site.example.com`). Finally, add the `site-url` and the CNAME file to your `_quarto.yml` file like this:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Next, in the Github repository for your site, edit the domain (Settings > Pages > Custom Domain).

I wonder if there's a slightly cleaner way to provide the expected navigation here.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I couldn't think of anything simpler, but happy to change it.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that being a little more explicit would help, something like

Next, change the configuration on GitHub. In the webpage for your GitHub repository, click on "Settings", "Pages", and "Custom Domain", then enter the domain name in the text field.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah! Good advice. I changed that, but the paragraph started to feel unwieldy, so I changed it to a numbered list.

docs/publishing/github-pages.qmd Outdated Show resolved Hide resolved
Responding to code review, trying to simplify instructions.
@jdfoote jdfoote requested a review from cscheid August 21, 2024 14:28
Added more detail about subdomains, changed to numbered steps as paragraph was becoming unwieldy.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants