Skip to content

Showing command line instructions on pull request despite branch protection existing #17121

Closed
@my1e5

Description

@my1e5

Gitea Version

1.15.3

Git Version

N/A

Operating System

N/A

How are you running Gitea?

Running on a Linux machine

Database

MySQL

Can you reproduce the bug on the Gitea demo site?

Yes

Log Gist

No response

Description

https://try.gitea.io/my1e5_test_user/Test-Repo/pulls/1

I have branch protection enabled on my 'master' branch so that "No pushing will be allowed to this branch"

image

However, on my pull request it shows these command line instructions which technically are not valid as I have branch protection enabled. git push origin master wouldn't work.

image

I feel this is slightly inelegant. Is there a way to make it so that if branch protection is enabled, these command line instructions are not shown?

Or alternatively, create a setting that allows you to disable showing these command line instructions? I don't want it to confuse users - I've had a user ask why these instructions are showing when branch protection is enabled.

Thanks!

Screenshots

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    type/docsThis PR mainly updates/creates documentation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions