loading up the forgejo repo on tangled to test page performance
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge pull request '[RELEASE] decouple the release name from the version number' (#2372) from earl-warren/forgejo:wip-test-release into forgejo

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/2372

+18 -8
+1 -1
.forgejo/workflows/build-release.yml
··· 190 190 destination-token: ${{ secrets.CASCADE_DESTINATION_TOKEN }} 191 191 update: .forgejo/cascading-release-end-to-end 192 192 env: 193 - FORGEJO_BINARY: "${{ env.GITHUB_SERVER_URL }}/${{ github.repository }}/releases/download/v${{ steps.tag-version.outputs.value }}/forgejo-${{ steps.tag-version.outputs.value }}-linux-amd64" 193 + FORGEJO_BINARY: "${{ env.GITHUB_SERVER_URL }}/${{ github.repository }}/releases/download/v${{ steps.release-info.outputs.version }}/forgejo-${{ steps.release-info.outputs.version }}-linux-amd64"
+2 -2
Dockerfile
··· 5 5 ARG GOPROXY 6 6 ENV GOPROXY ${GOPROXY:-direct} 7 7 8 - ARG GITEA_VERSION 8 + ARG RELEASE_VERSION 9 9 ARG TAGS="sqlite sqlite_unlock_notify" 10 10 ENV TAGS "bindata timetzdata $TAGS" 11 11 ARG CGO_EXTRA_CFLAGS ··· 36 36 RUN make clean-all 37 37 RUN make frontend 38 38 RUN go build contrib/environment-to-ini/environment-to-ini.go && xx-verify environment-to-ini 39 - RUN make go-check generate-backend static-executable && xx-verify gitea 39 + RUN make RELEASE_VERSION=$RELEASE_VERSION go-check generate-backend static-executable && xx-verify gitea 40 40 41 41 # Copy local files 42 42 COPY docker/root /tmp/local
+2 -2
Dockerfile.rootless
··· 5 5 ARG GOPROXY 6 6 ENV GOPROXY ${GOPROXY:-direct} 7 7 8 - ARG GITEA_VERSION 8 + ARG RELEASE_VERSION 9 9 ARG TAGS="sqlite sqlite_unlock_notify" 10 10 ENV TAGS "bindata timetzdata $TAGS" 11 11 ARG CGO_EXTRA_CFLAGS ··· 36 36 RUN make clean-all 37 37 RUN make frontend 38 38 RUN go build contrib/environment-to-ini/environment-to-ini.go && xx-verify environment-to-ini 39 - RUN make go-check generate-backend static-executable && xx-verify gitea 39 + RUN make RELEASE_VERSION=$RELEASE_VERSION go-check generate-backend static-executable && xx-verify gitea 40 40 41 41 # Copy local files 42 42 COPY docker/rootless /tmp/local
+3 -2
Makefile
··· 92 92 else 93 93 FORGEJO_VERSION ?= $(shell git describe --tags --always | sed 's/-/+/' | sed 's/^v//') 94 94 endif 95 - VERSION ?= ${FORGEJO_VERSION} 95 + RELEASE_VERSION ?= ${FORGEJO_VERSION} 96 + VERSION ?= ${RELEASE_VERSION} 96 97 97 98 GITEA_VERSION ?= 1.22.0 98 99 99 - LDFLAGS := $(LDFLAGS) -X "main.MakeVersion=$(MAKE_VERSION)" -X "main.Version=$(GITEA_VERSION)" -X "main.Tags=$(TAGS)" -X "main.ForgejoVersion=$(FORGEJO_VERSION)" 100 + LDFLAGS := $(LDFLAGS) -X "main.ReleaseVersion=$(RELEASE_VERSION)" -X "main.MakeVersion=$(MAKE_VERSION)" -X "main.Version=$(GITEA_VERSION)" -X "main.Tags=$(TAGS)" -X "main.ForgejoVersion=$(FORGEJO_VERSION)" 100 101 101 102 LINUX_ARCHS ?= linux/amd64,linux/386,linux/arm-5,linux/arm-6,linux/arm64 102 103
+10 -1
main.go
··· 29 29 Version = "development" // program version for this build 30 30 Tags = "" // the Golang build tags 31 31 MakeVersion = "" // "make" program version if built with make 32 + 33 + ReleaseVersion = "" 32 34 ) 33 35 34 36 var ForgejoVersion = "1.0.0" ··· 54 56 log.GetManager().Close() 55 57 os.Exit(code) 56 58 } 57 - app := cmd.NewMainApp(Version, formatBuiltWith()) 59 + app := cmd.NewMainApp(Version, formatReleaseVersion()+formatBuiltWith()) 58 60 _ = cmd.RunMainApp(app, os.Args...) // all errors should have been handled by the RunMainApp 59 61 log.GetManager().Close() 62 + } 63 + 64 + func formatReleaseVersion() string { 65 + if len(ReleaseVersion) > 0 { 66 + return " (release name " + ReleaseVersion + ")" 67 + } 68 + return "" 60 69 } 61 70 62 71 func formatBuiltWith() string {