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

support: external_repository seems to not support a PR-based workflow #1114

Open
3 tasks done
brianthelion opened this issue Dec 24, 2024 · 0 comments
Open
3 tasks done
Assignees
Labels
support User support

Comments

@brianthelion
Copy link

brianthelion commented Dec 24, 2024

Checklist

  • I am using the latest version of this action.
  • I have read the latest README and followed the instructions.
  • I have read the latest GitHub Actions official documentation and learned the basic spec and concepts.

Describe your question

I have succeeded in using the peaceiris/actions-gh-pages@v4 action to push a branch to an external_repository using a deploy_key as described in the docs. To achieve this, I use publish_branch: ${{ github.ref_name }}.

As a final sanity check, I would like to manually create a PR from, eg, newbranch/3@abcdef to main, where main is a protected branch that is published to the web through gh-pages.

Unfortunately, the new branch pushed by the peaceiris/actions-gh-pages@v4 action doesn't share a commit history with main because it came from a static site generator. Github refuses to allow PRs without any shared history.

The net result is that I'm unable to use a PR-based workflow on my external_repository. In fact, there doesn't appear to be a way to merge the new branch unless I do some manual git-fu.

Is my only choice is to use publish_branch: main?

Relevant links

Public repository: 
  `external_repository:` https://github.com/lonely-bike/www
YAML config: (private)
YAML workflow: (private)


      - name: Deploy to GitHub Pages
        uses: peaceiris/actions-gh-pages@v4
        with:
          # github_token: ${{ secrets.GITHUB_TOKEN }}
          deploy_key: ${{ secrets.DEPLOY_KEY }}
          external_repository: lonely-bike/www
          publish_branch: ${{ github.ref_name }}
          publish_dir: ./website/_site
          cname: lonely.bike
          commit_message: ${{ github.event.head_commit.message }}


### Relevant log output

![image](https://github.com/user-attachments/assets/6c3ab054-d7bd-4f18-9057-833fa76dad75)


### Additional context.

_No response_
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
support User support
Projects
None yet
Development

No branches or pull requests

2 participants