Skip to content

Commit 25cc669

Browse files
authored
Merge branch 'main' into fix-ui
2 parents a603731 + ac64c82 commit 25cc669

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+203
-1848
lines changed

.gitpod.yml

+5-2
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,11 @@ tasks:
2424
make watch-frontend
2525
openMode: split-right
2626
- name: Run docs
27-
before: sudo bash -c "$(grep 'https://github.com/gohugoio/hugo/releases/download' Makefile | tr -d '\')" # install hugo
28-
command: cd docs && make clean update && hugo server -D -F --baseUrl $(gp url 1313) --liveReloadPort=443 --appendPort=false --bind=0.0.0.0
27+
command: |
28+
gp sync-await setup
29+
cd docs
30+
make clean update
31+
hugo server -D -F --baseUrl $(gp url 1313) --liveReloadPort=443 --appendPort=false --bind=0.0.0.0
2932
openMode: split-right
3033

3134
vscode:

Makefile

+10-11
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ TEST_TAGS ?= sqlite sqlite_unlock_notify
131131

132132
TAR_EXCLUDES := .git data indexers queues log node_modules $(EXECUTABLE) $(FOMANTIC_WORK_DIR)/node_modules $(DIST) $(MAKE_EVIDENCE_DIR) $(AIR_TMP_DIR) $(GO_LICENSE_TMP_DIR)
133133

134-
GO_DIRS := cmd tests models modules routers build services tools
134+
GO_DIRS := build cmd models modules routers services tests
135135
WEB_DIRS := web_src/js web_src/css
136136

137137
GO_SOURCES := $(wildcard *.go)
@@ -189,6 +189,7 @@ help:
189189
@echo " - clean delete backend and integration files"
190190
@echo " - clean-all delete backend, frontend and integration files"
191191
@echo " - deps install dependencies"
192+
@echo " - deps-docs install docs dependencies"
192193
@echo " - deps-frontend install frontend dependencies"
193194
@echo " - deps-backend install backend dependencies"
194195
@echo " - deps-tools install tool dependencies"
@@ -218,7 +219,6 @@ help:
218219
@echo " - tidy run go mod tidy"
219220
@echo " - test[\#TestSpecificName] run unit test"
220221
@echo " - test-sqlite[\#TestSpecificName] run integration test for sqlite"
221-
@echo " - pr#<index> build and start gitea from a PR with integration test data loaded"
222222

223223
.PHONY: go-check
224224
go-check:
@@ -352,7 +352,7 @@ lint-backend: golangci-lint vet editorconfig-checker
352352

353353
.PHONY: watch
354354
watch:
355-
bash tools/watch.sh
355+
bash build/watch.sh
356356

357357
.PHONY: watch-frontend
358358
watch-frontend: node-check node_modules
@@ -816,14 +816,17 @@ release-docs: | $(DIST_DIRS) docs
816816
tar -czf $(DIST)/release/gitea-docs-$(VERSION).tar.gz -C ./docs/public .
817817

818818
.PHONY: docs
819-
docs:
819+
docs: deps-docs
820+
cd docs; make trans-copy clean build-offline;
821+
822+
.PHONY: deps-docs
823+
deps-docs:
820824
@hash hugo > /dev/null 2>&1; if [ $$? -ne 0 ]; then \
821-
curl -sL https://github.com/gohugoio/hugo/releases/download/v$(HUGO_VERSION)/hugo_$(HUGO_VERSION)_Linux-64bit.tar.gz | tar zxf - -C /tmp && mv /tmp/hugo /usr/bin/hugo && chmod +x /usr/bin/hugo; \
825+
curl -sL https://github.com/gohugoio/hugo/releases/download/v$(HUGO_VERSION)/hugo_$(HUGO_VERSION)_Linux-64bit.tar.gz | tar zxf - -C /tmp && mkdir -p ~/go/bin && mv /tmp/hugo ~/go/bin/hugo && chmod +x ~/go/bin/hugo; \
822826
fi
823-
cd docs; make trans-copy clean build-offline;
824827

825828
.PHONY: deps
826-
deps: deps-frontend deps-backend deps-tools
829+
deps: deps-frontend deps-backend deps-tools deps-docs
827830

828831
.PHONY: deps-frontend
829832
deps-frontend: node_modules
@@ -935,10 +938,6 @@ generate-manpage:
935938
@gzip -9 man/man1/gitea.1 && echo man/man1/gitea.1.gz created
936939
@#TODO A small script that formats config-cheat-sheet.en-us.md nicely for use as a config man page
937940

938-
.PHONY: pr\#%
939-
pr\#%: clean-all
940-
$(GO) run contrib/pr/checkout.go $*
941-
942941
.PHONY: golangci-lint
943942
golangci-lint:
944943
$(GO) run $(GOLANGCI_LINT_PACKAGE) run

build/backport-locales.go

+3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
// Copyright 2023 The Gitea Authors. All rights reserved.
2+
// SPDX-License-Identifier: MIT
3+
14
//go:build ignore
25

36
package main

build/code-batch-process.go

-1
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,6 @@ func newFileCollector(fileFilter string, batchSize int) (*fileCollector, error)
6565
"modules",
6666
"routers",
6767
"services",
68-
"tools",
6968
}
7069
co.includePatterns = append(co.includePatterns, regexp.MustCompile(`.*\.go$`))
7170

build/test-echo.go

+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
// Copyright 2023 The Gitea Authors. All rights reserved.
2+
// SPDX-License-Identifier: MIT
3+
4+
//go:build ignore
5+
6+
package main
7+
8+
import (
9+
"fmt"
10+
"io"
11+
"os"
12+
)
13+
14+
func main() {
15+
_, err := io.Copy(os.Stdout, os.Stdin)
16+
if err != nil {
17+
fmt.Fprintf(os.Stderr, "Error: %v", err)
18+
os.Exit(1)
19+
}
20+
}
File renamed without changes.

contrib/autoboot.sh

-2
This file was deleted.

contrib/mysql.sql

-2
This file was deleted.

contrib/pr/checkout.go

-267
This file was deleted.

0 commit comments

Comments
 (0)