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

Option to create PR with the image #65

Open
abe-101 opened this issue May 24, 2024 · 0 comments
Open

Option to create PR with the image #65

abe-101 opened this issue May 24, 2024 · 0 comments

Comments

@abe-101
Copy link

abe-101 commented May 24, 2024

I think it would be useful to have a flag where we can set it to open a PR instead of pushing to the main branch

I had a rule in place to prevent from pushing to the main repo and the action failed

A  diagram.svg

A  diagram.svg
diff: A  diagram.svg

Commit and push diagram
  /usr/bin/git commit -m Repo visualizer: update diagram
  [main a6487aa] Repo visualizer: update diagram
   1 file changed, 1 insertion(+)
   create mode 100644 diagram.svg
  /usr/bin/git push
  remote: error: GH006: Protected branch update failed for refs/heads/main.        
  remote: error: Changes must be made through a pull request.        
  To https://github.com/************************
   ! [remote rejected] main -> main (protected branch hook declined)
  error: failed to push some refs to 'https://github.com/************************'
  Error: Error: The process '/usr/bin/git' failed with exit code 1

My action:

name: Create diagram
on:
workflow_dispatch: {}
push:
  branches:
    - main
jobs:
get_data:
  runs-on: ubuntu-latest
  steps:
    - name: Checkout code
      uses: actions/checkout@master
    - name: Update diagram
      uses: githubocto/repo-visualizer@main
      with:
        excluded_paths: "ignore,.github"
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

No branches or pull requests

1 participant