Skip to content

Add git hooks permission check when generating repository from template#37127

Draft
lunny wants to merge 1 commit intogo-gitea:mainfrom
lunny:lunny/template_gen_githooks
Draft

Add git hooks permission check when generating repository from template#37127
lunny wants to merge 1 commit intogo-gitea:mainfrom
lunny:lunny/template_gen_githooks

Conversation

@lunny
Copy link
Copy Markdown
Member

@lunny lunny commented Apr 7, 2026

The template repository might be created by a user who can create git hooks. When a regular user who cannot be allowed to edit git hooks generate repositories from that template repository, the git hooks copied.

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Apr 7, 2026
@lunny lunny added type/bug and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels Apr 7, 2026
@github-actions github-actions bot added the modifies/go Pull requests that update Go code label Apr 7, 2026
Copy link
Copy Markdown
Contributor

@wxiaoguang wxiaoguang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But why "a regular user who cannot be allowed to edit git hooks" shouldn't copy the git hooks? They are just not allowed to edit, why they shouldn't share the git hooks from template?

@GiteaBot GiteaBot added the lgtm/blocked A maintainer has reservations with the PR and thus it cannot be merged label Apr 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lgtm/blocked A maintainer has reservations with the PR and thus it cannot be merged modifies/go Pull requests that update Go code type/bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants