Skip to content

Conversation

silverwind
Copy link
Member

@silverwind silverwind commented Aug 18, 2022

Remove spaces inside template curly brackets and add it to make fmt and verify in make fmt-check.

The sed expressions work on both GNU and BSD variants and for that reason, they are using pretty ancient regexp syntax (BSD sed can't do \s, \t, +). The closing bracket expression has an exception for allow multi-line content so, }} on new line won't get dedented.

@silverwind silverwind changed the title Add whitespace removal around inside template curly brackes Add whitespace removal inside template curly brackes Aug 18, 2022
@silverwind silverwind added topic/code-linting type/refactoring Existing code has been cleaned up. There should be no new functionality. skip-changelog This PR is irrelevant for the (next) changelog, for example bug fixes for unreleased features. labels Aug 18, 2022
@silverwind silverwind added this to the 1.18.0 milestone Aug 18, 2022
@GiteaBot GiteaBot added the lgtm/need 1 This PR needs approval from one additional maintainer to be merged. label Aug 20, 2022
@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Aug 20, 2022
@techknowlogick techknowlogick merged commit 6c4688e into go-gitea:main Aug 25, 2022
@silverwind silverwind deleted the fmt-tmpl branch August 25, 2022 23:41
zjjhot added a commit to zjjhot/gitea that referenced this pull request Aug 26, 2022
* upstream/main:
  Add whitespace removal inside template curly brackes (go-gitea#20853)
  Only show relevant repositories on explore page (go-gitea#19361)
  Replace `ServeStream` with `ServeContent` (go-gitea#20903)
  Update JS dependencies (go-gitea#20950)
  chore: remove broken gitea-format-imports (go-gitea#20952)
vsysoev pushed a commit to IntegraSDL/gitea that referenced this pull request Aug 28, 2022
@go-gitea go-gitea locked and limited conversation to collaborators May 3, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. skip-changelog This PR is irrelevant for the (next) changelog, for example bug fixes for unreleased features. topic/code-linting type/refactoring Existing code has been cleaned up. There should be no new functionality.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants