How can I deploy/publish to GitHub Pages of another repository? #42772
Replies: 5 comments 3 replies
-
|
@tschaub I went through this and I am wondering if it can help me find a solution |
Beta Was this translation helpful? Give feedback.
-
|
has anyone found a solution to this ? @praveenpandey02 : did that work for you ? (https://github.com/tschaub/gh-pages) |
Beta Was this translation helpful? Give feedback.
-
|
Did you end up finding a solution? I'm trying to do the same thing |
Beta Was this translation helpful? Give feedback.
-
|
For anyone else getting here and still looking for a solution, I recently went through this exercise and I shared my approach with what's already available using only GitHub Actions and OpenTofu. Read the full blog post here: Hope you enjoy. Cheers 🥂 |
Beta Was this translation helpful? Give feedback.
-
|
Google led me here, amongst other places. I hope I can contribute now that my code works. push one repo to another repo using Here's a part of my working - name: Deploy to GitHub Pages
id: deployment
uses: peaceiris/actions-gh-pages@v4
with:
deploy_key: ${{ secrets.ACTIONS_DEPLOY_KEY }}
publish_branch: <branch to push to, gh-pages is safest>
publish_dir: ./<build/dist dir>
enable_jekyll: true # if you just have .md files, index.html can set to false
external_repository: <user/org>/<deployment repo like org.github.io>
if: ${{ github.ref == 'refs/heads/main' }} # only deploy if main branch changedI wrote a guide in a github snippets repo documenting the various techniques and packages I tried to do this (several successfully) and go into a lot more depth. Feel free to check it out: |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Select Topic Area
Question
Body
I have an enterprise GitHub repository (let’s name it
Repo-A) and its GitHub Pages is already occupied. Meaning it is already used. I would still want to publish the static html fromRepo-A. So I have created another repository within the same organisation in which myRepo-Aexists ( let’s call this oneRepo-B). How can I publish static html present inRepo-Ato GitHub Pages ofRepo-B? Even if get a direction, I can try it out. Right now, I do not even know how to get started.Beta Was this translation helpful? Give feedback.
All reactions