DEV Community

Discussion on: Deploying to gh pages with git subtree

Collapse
 
letsbsocial1 profile image
Maria Campbell • Edited

Hi Max, I don't ignore my dist. In fact, you are right. It can't be in the .gitignore, otherwise the command won't work. Can I ask what kind of project are you trying to use this for? Is it a project using a static website generator like jekyll, or is it a rails project? I use a commands that are similar in concept for my hugo generated site that might help you determine which way to go. There, I push the contents of my public directory to gh-pages, but public is in .gitignore. Here is the link to the repo of this website: github.com/interglobalmedia/interg... Feel free to take a look and see what is going on. I also wrote a post about how to deploy your Hugo generated website to gh-pages based on my workflow: interglobalmedianetwork.com/post/a... Hope it helps!

Collapse
 
maxwell_dev profile image
Max Antonucci

Sorry for the late response, but yes it is a Jekyll site. I've also hit a similar issue while using Pattern Lab, which is an open-source tool generating the public directory using Gulp. I tried to check the github link you shared, but it lead to a 404 page. But it is good to know how you've worked around this particular issue, I'll definitely give that post a closer look!

Thread Thread
 
letsbsocial1 profile image
Maria Campbell

Sorry for the bad link and for not getting back to you sooner. Was not bad, just did not have a space after it! Should work now. Hugo in terms of workflows is similar to Jekyll, especially since both use the public folder. Perhaps you can give the scripts I use for my Hugo site with Jekyll? And now you should be able to access the repo for inter-global media network blog. Let me know if this helps!