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

Move https://digihistch24.github.io/book-of-abstracts/ to https://digihistch24.github.io #83

Closed
maehr opened this issue Nov 7, 2024 · 1 comment · Fixed by #85
Closed
Assignees

Comments

@maehr
Copy link
Contributor

maehr commented Nov 7, 2024

Describe what feature you'd like. Pseudo-code, mockups, or screenshots of similar solutions are encouraged!

To move your site from https://digihistch24.github.io/book-of-abstracts/ to https://digihistch24.github.io/, you'll need to update the GitHub Pages settings and potentially modify your Quarto project structure if necessary.

Here’s a step-by-step guide:

1. Update the Project Settings

  1. Go to GitHub Repository Settings: Navigate to the Settings page for your digihistch24.github.io repository.
  2. Change the GitHub Pages Source:
    • In the Pages section, set the source branch to main (or the branch where your site is built).
    • Ensure that the source folder is set to the root or _site (depending on your build setup).
    • This configuration will publish the site directly to https://digihistch24.github.io/.

2. Update _quarto.yml for New Base URL

In your Quarto project’s _quarto.yml, update the website base URL to match the new location.

From:

project:
  type: website

website:
  title: "Book of Abstracts"
  base-url: /book-of-abstracts/

To:

project:
  type: website

website:
  title: "Book of Abstracts"
  base-url: /

Setting base-url: / ensures that all relative links, images, and assets will load correctly from the new root path.

3. Re-render the Project

After updating _quarto.yml, re-render the project to update all links and paths.

quarto render

4. Push Changes to GitHub

Commit and push the changes to your repository. This will trigger the GitHub Pages deployment and move your site to the new URL.

git add .
git commit -m "Update base URL for GitHub Pages root deployment"
git push origin main

5. Verify the Move

After pushing the changes, check https://digihistch24.github.io/ to ensure that everything loads correctly. Double-check internal links, images, and styles to confirm they work as expected at the new root URL.

Optional: Redirect Old URL (If Necessary)

If users are still accessing the old URL (https://digihistch24.github.io/book-of-abstracts/), you can create a simple index.html file in the /book-of-abstracts/ directory with a redirect to the new URL.

Example index.html for Redirection:

<!DOCTYPE html>
<html lang="en">
<head>
  <meta http-equiv="refresh" content="0; url='https://digihistch24.github.io/'" />
  <title>Redirecting...</title>
</head>
<body>
  <p>If you are not redirected automatically, follow this <a href="https://digihistch24.github.io/">link</a>.</p>
</body>
</html>

This approach will seamlessly transition users to the new URL.

What type of pull request would this be?

Enhancement

Any links to similar examples or other references we should review?

No response

@maehr maehr self-assigned this Nov 7, 2024
@maehr maehr mentioned this issue Nov 8, 2024
8 tasks
@maehr
Copy link
Contributor Author

maehr commented Nov 8, 2024

@mtwente we should also change the redirect of bit.ly/digihistch24

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 a pull request may close this issue.

1 participant