Skip to content

Commit f838b5a

Browse files
committed
Merge branch 'main' into packer重构
2 parents 4cc5972 + cb6cd9a commit f838b5a

102 files changed

Lines changed: 2327 additions & 380 deletions

File tree

Some content is hidden

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

.github/workflows/packer.yml

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ jobs:
109109
110110
- name: Run Packer for ${{ matrix.version }}
111111
# 分发包中应当包含全部内容
112-
run: ./Packer --version="${{ matrix.version }}"
112+
run: ./Packer --version="${{ matrix.version }}" --grouped --flattened
113113
# 运行逻辑:内容有更改 或 手动运行
114114
if: steps.check-changes.outputs.changed == 'true' || github.event_name == 'workflow_dispatch'
115115

@@ -122,6 +122,15 @@ jobs:
122122
Minecraft-Mod-Language-Modpack-${{ matrix.version }}.zip
123123
${{ matrix.version }}.md5
124124
if: steps.check-changes.outputs.changed == 'true' || github.event_name == 'workflow_dispatch'
125+
126+
# feat:按命名空间打小包
127+
- name: Upload Artifact for ${{ matrix.version }} grouped
128+
uses: actions/upload-artifact@v4
129+
with:
130+
name: grouped-Minecraft-Mod-Language-Modpack-${{ matrix.version }}
131+
path: |
132+
Minecraft-Mod-Language-Modpack-${{ matrix.version }}-namespaced.zip
133+
if: steps.check-changes.outputs.changed == 'true' || github.event_name == 'workflow_dispatch'
125134

126135
upload:
127136
concurrency:
@@ -154,6 +163,9 @@ jobs:
154163
uses: actions/download-artifact@v4
155164
with:
156165
path: artifacts/
166+
pattern: Minecraft-Mod-Language-Modpack-* # 先不拉取新格式,否则会乱掉
167+
168+
# Pending: 把按命名空间传的包也传上去
157169

158170
# feat: UTC 20:00~21:00 取消上传(避开远程服务器的4:00-4:10)
159171
- name: Fail at inappropriate time

.github/workflows/pr-packer.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ jobs:
100100
101101
- name: Run Packer for ${{ matrix.version }}
102102
# 部分包原则:Packer和配置均没有改动
103-
run: ./Packer --version="${{ matrix.version }}" --increment=${{ steps.check-critical-changes.outputs.changed == 'false' }}
103+
run: ./Packer --version="${{ matrix.version }}" --increment=${{ steps.check-critical-changes.outputs.changed == 'false' }} --flattened
104104
# 运行逻辑:内容有更改 或 手动运行
105105
if: steps.check-changes.outputs.changed == 'true' || github.event_name == 'workflow_dispatch'
106106

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# CFPA-specifics
22
Minecraft-Mod-Language-Package-*.zip
3+
Minecraft-Mod-Language-Modpack-*.zip
34
*.md5
45
build/
56
Packer.exe

Packer-Doc.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,10 @@
5252
暂时闲置,以待后续需求。
5353
- string
5454
排除的命名空间。<!--以[S部分](./S.-本仓库的结构向导)中定义的 **[namespace]** | **(命名空间)**为准。-->
55+
- `fallbackVersions` list
56+
该配置所允许的回退版本。对每个模组文件夹,打包器会先寻找 `version` 字段指向的版本,再在这里按顺序寻找回退版本;打包器会选择找到的**第一个**版本,而不会加载其他版本的内容。
57+
- string
58+
回退版本,以 `projects/` 中的文件夹名称为准。
5559
- `floating` object
5660
打包流程中的*可变配置*,可能被文件结构中的**局域配置文件**改写。包含的内容都是**低于**命名空间层级的,因为局域配置文件就是放在命名空间一级中的。
5761
- `inclusionDomains` list

config/packer/1.12.2.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@
1616
],
1717
"exclusionNamespaces": [
1818
"srparasites"
19-
]
19+
],
20+
"fallbackVersions": []
2021
},
2122
"floating": {
2223
"inclusionDomains": [

config/packer/1.16-fabric.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@
1313
"1.16.5 Fabric"
1414
],
1515
"exclusionMods": [],
16-
"exclusionNamespaces": []
16+
"exclusionNamespaces": [],
17+
"fallbackVersions": []
1718
},
1819
"floating": {
1920
"inclusionDomains": [

config/packer/1.16.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@
1313
"1.16.5 Forge"
1414
],
1515
"exclusionMods": [],
16-
"exclusionNamespaces": []
16+
"exclusionNamespaces": [],
17+
"fallbackVersions": []
1718
},
1819
"floating": {
1920
"inclusionDomains": [

config/packer/1.18-fabric.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@
1515
"exclusionMods": [],
1616
"exclusionNamespaces": [
1717
"litematica"
18-
]
18+
],
19+
"fallbackVersions": []
1920
},
2021
"floating": {
2122
"inclusionDomains": [

config/packer/1.18.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,8 @@
2020
"thermal",
2121
"tinkers_things",
2222
"createaddition"
23-
]
23+
],
24+
"fallbackVersions": []
2425
},
2526
"floating": {
2627
"inclusionDomains": [

config/packer/1.19.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@
1616
"exclusionNamespaces": [
1717
"nochatreports",
1818
"illager_additions"
19+
],
20+
"fallbackVersions": [
21+
"1.18"
1922
]
2023
},
2124
"floating": {

0 commit comments

Comments
 (0)