Skip to content

Commit b00c435

Browse files
authored
Merge branch 'main' into lunny/move_issue_pin
2 parents 25f7cce + 943cc4f commit b00c435

Some content is hidden

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

81 files changed

+847
-334
lines changed

.github/workflows/cron-licenses.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
name: cron-licenses
22

33
on:
4-
schedule:
5-
- cron: "7 0 * * 1" # every Monday at 00:07 UTC
4+
#schedule:
5+
# - cron: "7 0 * * 1" # every Monday at 00:07 UTC
66
workflow_dispatch:
77

88
jobs:

main_timezones.go

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
// Copyright 2025 The Gitea Authors. All rights reserved.
2+
// SPDX-License-Identifier: MIT
3+
4+
//go:build windows
5+
6+
package main
7+
8+
// Golang has the ability to load OS's timezone data from most UNIX systems (https://github.com/golang/go/blob/master/src/time/zoneinfo_unix.go)
9+
// Even if the timezone data is missing, users could install the related packages to get it.
10+
// But on Windows, although `zoneinfo_windows.go` tries to load the timezone data from Windows registry,
11+
// some users still suffer from the issue that the timezone data is missing: https://github.com/go-gitea/gitea/issues/33235
12+
// So we import the tzdata package to make sure the timezone data is included in the binary.
13+
//
14+
// For non-Windows package builders, they could still use the "TAGS=timetzdata" to include the tzdata package in the binary.
15+
// If we decided to add the tzdata for other platforms, modify the "go:build" directive above.
16+
import _ "time/tzdata"

models/issues/issue_project.go

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,13 +38,15 @@ func (issue *Issue) projectID(ctx context.Context) int64 {
3838
}
3939

4040
// ProjectColumnID return project column id if issue was assigned to one
41-
func (issue *Issue) ProjectColumnID(ctx context.Context) int64 {
41+
func (issue *Issue) ProjectColumnID(ctx context.Context) (int64, error) {
4242
var ip project_model.ProjectIssue
4343
has, err := db.GetEngine(ctx).Where("issue_id=?", issue.ID).Get(&ip)
44-
if err != nil || !has {
45-
return 0
44+
if err != nil {
45+
return 0, err
46+
} else if !has {
47+
return 0, nil
4648
}
47-
return ip.ProjectColumnID
49+
return ip.ProjectColumnID, nil
4850
}
4951

5052
// LoadIssuesFromColumn load issues assigned to this column

models/project/project.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -244,6 +244,10 @@ func GetSearchOrderByBySortType(sortType string) db.SearchOrderBy {
244244
return db.SearchOrderByRecentUpdated
245245
case "leastupdate":
246246
return db.SearchOrderByLeastUpdated
247+
case "alphabetically":
248+
return "title ASC"
249+
case "reversealphabetically":
250+
return "title DESC"
247251
default:
248252
return db.SearchOrderByNewest
249253
}

modules/indexer/issues/util.go

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,11 @@ func getIssueIndexerData(ctx context.Context, issueID int64) (*internal.IndexerD
9292
projectID = issue.Project.ID
9393
}
9494

95+
projectColumnID, err := issue.ProjectColumnID(ctx)
96+
if err != nil {
97+
return nil, false, err
98+
}
99+
95100
return &internal.IndexerData{
96101
ID: issue.ID,
97102
RepoID: issue.RepoID,
@@ -106,7 +111,7 @@ func getIssueIndexerData(ctx context.Context, issueID int64) (*internal.IndexerD
106111
NoLabel: len(labels) == 0,
107112
MilestoneID: issue.MilestoneID,
108113
ProjectID: projectID,
109-
ProjectColumnID: issue.ProjectColumnID(ctx),
114+
ProjectColumnID: projectColumnID,
110115
PosterID: issue.PosterID,
111116
AssigneeID: issue.AssigneeID,
112117
MentionIDs: mentionIDs,

options/gitignore/Flutter

Lines changed: 119 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,119 @@
1+
# Miscellaneous
2+
*.class
3+
*.lock
4+
*.log
5+
*.pyc
6+
*.swp
7+
.buildlog/
8+
.history
9+
10+
11+
12+
# Flutter repo-specific
13+
/bin/cache/
14+
/bin/internal/bootstrap.bat
15+
/bin/internal/bootstrap.sh
16+
/bin/mingit/
17+
/dev/benchmarks/mega_gallery/
18+
/dev/bots/.recipe_deps
19+
/dev/bots/android_tools/
20+
/dev/devicelab/ABresults*.json
21+
/dev/docs/doc/
22+
/dev/docs/flutter.docs.zip
23+
/dev/docs/lib/
24+
/dev/docs/pubspec.yaml
25+
/dev/integration_tests/**/xcuserdata
26+
/dev/integration_tests/**/Pods
27+
/packages/flutter/coverage/
28+
version
29+
analysis_benchmark.json
30+
31+
# packages file containing multi-root paths
32+
.packages.generated
33+
34+
# Flutter/Dart/Pub related
35+
**/doc/api/
36+
.dart_tool/
37+
.flutter-plugins
38+
.flutter-plugins-dependencies
39+
**/generated_plugin_registrant.dart
40+
.packages
41+
.pub-preload-cache/
42+
.pub/
43+
build/
44+
flutter_*.png
45+
linked_*.ds
46+
unlinked.ds
47+
unlinked_spec.ds
48+
49+
# Android related
50+
**/android/**/gradle-wrapper.jar
51+
.gradle/
52+
**/android/captures/
53+
**/android/gradlew
54+
**/android/gradlew.bat
55+
**/android/local.properties
56+
**/android/**/GeneratedPluginRegistrant.java
57+
**/android/key.properties
58+
*.jks
59+
60+
# iOS/XCode related
61+
**/ios/**/*.mode1v3
62+
**/ios/**/*.mode2v3
63+
**/ios/**/*.moved-aside
64+
**/ios/**/*.pbxuser
65+
**/ios/**/*.perspectivev3
66+
**/ios/**/*sync/
67+
**/ios/**/.sconsign.dblite
68+
**/ios/**/.tags*
69+
**/ios/**/.vagrant/
70+
**/ios/**/DerivedData/
71+
**/ios/**/Icon?
72+
**/ios/**/Pods/
73+
**/ios/**/.symlinks/
74+
**/ios/**/profile
75+
**/ios/**/xcuserdata
76+
**/ios/.generated/
77+
**/ios/Flutter/.last_build_id
78+
**/ios/Flutter/App.framework
79+
**/ios/Flutter/Flutter.framework
80+
**/ios/Flutter/Flutter.podspec
81+
**/ios/Flutter/Generated.xcconfig
82+
**/ios/Flutter/ephemeral
83+
**/ios/Flutter/app.flx
84+
**/ios/Flutter/app.zip
85+
**/ios/Flutter/flutter_assets/
86+
**/ios/Flutter/flutter_export_environment.sh
87+
**/ios/ServiceDefinitions.json
88+
**/ios/Runner/GeneratedPluginRegistrant.*
89+
90+
# macOS
91+
**/Flutter/ephemeral/
92+
**/Pods/
93+
**/macos/Flutter/GeneratedPluginRegistrant.swift
94+
**/macos/Flutter/ephemeral
95+
**/xcuserdata/
96+
97+
# Windows
98+
**/windows/flutter/generated_plugin_registrant.cc
99+
**/windows/flutter/generated_plugin_registrant.h
100+
**/windows/flutter/generated_plugins.cmake
101+
102+
# Linux
103+
**/linux/flutter/generated_plugin_registrant.cc
104+
**/linux/flutter/generated_plugin_registrant.h
105+
**/linux/flutter/generated_plugins.cmake
106+
107+
# Coverage
108+
coverage/
109+
110+
# Symbols
111+
app.*.symbols
112+
113+
# Exceptions to above rules.
114+
!**/ios/**/default.mode1v3
115+
!**/ios/**/default.mode2v3
116+
!**/ios/**/default.pbxuser
117+
!**/ios/**/default.perspectivev3
118+
!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages
119+
!/dev/ci/**/Gemfile.lock

options/gitignore/Nix

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
# Ignore build outputs from performing a nix-build or `nix build` command
22
result
33
result-*
4+
5+
# Ignore automatically generated direnv output
6+
.direnv
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Excludes Obsidian workspace cache and plugins. All notes and core obsidian
2+
# configuration files are tracked by Git.
3+
4+
# The current application UI state (DOM layout, recently-opened files, etc.) is
5+
# stored in these files (separate for desktop and mobile) so you can resume
6+
# your session seamlessly after a restart. If you want to track UI state, use
7+
# the Workspaces core plugin instead of relying on these files.
8+
.obsidian/workspace.json
9+
.obsidian/workspace-mobile.json
10+
11+
# Obsidian plugins are stored under .obsidian/plugins/$plugin_name. They
12+
# contain metadata (manifest.json), application code (main.js), stylesheets
13+
# (styles.css), and user-configuration data (data.json).
14+
# We want to exclude all plugin-related files, so we can exclude everything
15+
# under this directory.
16+
.obsidian/plugins/**/*
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
# Excludes Obsidian workspace cache and plugin code, but retains plugin
2+
# configuration. All notes and user-controlled configuration files are tracked
3+
# by Git.
4+
#
5+
# !!! WARNING !!!
6+
#
7+
# Community plugins may store sensitive secrets in their data.json files. By
8+
# including these files, those secrets may be tracked in your Git repository.
9+
#
10+
# To ignore configurations for specific plugins, add a line like this after the
11+
# contents of this file (order is important):
12+
# .obsidian/plugins/{{plugin_name}}/data.json
13+
#
14+
# Alternatively, ensure that you are treating your entire Git repository as
15+
# sensitive data, since it may contain secrets, or may have contained them in
16+
# past commits. Understand your threat profile, and make the decision
17+
# appropriate for yourself. If in doubt, err on the side of not including
18+
# plugin configuration. Use one of the alternative gitignore files instead:
19+
# * NotesOnly.gitignore
20+
# * NotesAndCoreConfiguration.gitignore
21+
22+
# The current application UI state (DOM layout, recently-opened files, etc.) is
23+
# stored in these files (separate for desktop and mobile) so you can resume
24+
# your session seamlessly after a restart. If you want to track UI state, use
25+
# the Workspaces core plugin instead of relying on these files.
26+
.obsidian/workspace.json
27+
.obsidian/workspace-mobile.json
28+
29+
# Obsidian plugins are stored under .obsidian/plugins/$plugin_name. They
30+
# contain metadata (manifest.json), application code (main.js), stylesheets
31+
# (styles.css), and user-configuration data (data.json).
32+
# We only want to track data.json, so we:
33+
# 1. exclude everything under the plugins directory recursively,
34+
# 2. unignore the plugin directories themselves, which then allows us to
35+
# 3. unignore the data.json files
36+
.obsidian/plugins/**/*
37+
!.obsidian/plugins/*/
38+
!.obsidian/plugins/*/data.json

options/gitignore/NotesOnly

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Excludes all Obsidian-related configuration. All notes are tracked by Git.
2+
3+
# All Obsidian configuration and runtime state is stored here
4+
.obsidian/**/*

0 commit comments

Comments
 (0)