Skip to content

Commit 08826b7

Browse files
committed
remove separate "SMAPI for developers' version
1 parent ad9cb48 commit 08826b7

7 files changed

Lines changed: 49 additions & 76 deletions

File tree

.github/workflows/build-smapi.yml

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -87,10 +87,8 @@ jobs:
8787
Write-Host "Building SMAPI $env:VERSION."
8888
./build/scripts/prepare-install-package.ps1 "$env:VERSION"
8989
90-
- name: Rename build zips
91-
run: |
92-
mv "bin/SMAPI ${{env.VERSION}} installer.zip" "bin/SMAPI-${{env.VERSION}}-installer.zip"
93-
mv "bin/SMAPI ${{env.VERSION}} installer for developers.zip" "bin/SMAPI-${{env.VERSION}}-installer-for-developers.zip"
90+
- name: Rename build zip
91+
run: mv "bin/SMAPI ${{env.VERSION}} installer.zip" "bin/SMAPI-${{env.VERSION}}-installer.zip"
9492

9593
- name: Upload installer
9694
uses: actions/upload-artifact@v4
@@ -99,13 +97,6 @@ jobs:
9997
path: 'bin/SMAPI-${{env.VERSION}}-installer.zip'
10098
if-no-files-found: 'error'
10199

102-
- name: Upload installer for developers
103-
uses: actions/upload-artifact@v4
104-
with:
105-
name: 'SMAPI ${{env.VERSION}} installer for developers'
106-
path: 'bin/SMAPI-${{env.VERSION}}-installer-for-developers.zip'
107-
if-no-files-found: 'error'
108-
109100
- name: Create GitHub release
110101
uses: ncipollo/release-action@v1
111102
if: github.ref_type == 'tag'
@@ -121,6 +112,4 @@ jobs:
121112
- name: Generate artifact attestations
122113
uses: actions/attest-build-provenance@v2
123114
with:
124-
subject-path: |
125-
bin/SMAPI-${{env.VERSION}}-installer.zip
126-
bin/SMAPI-${{env.VERSION}}-installer-for-developers.zip
115+
subject-path: bin/SMAPI-${{env.VERSION}}-installer.zip

build/scripts/finalize-install-package.sh

Lines changed: 32 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -24,44 +24,43 @@ buildFolders=("linux" "macOS" "windows")
2424
##########
2525
## Finalize release package
2626
##########
27-
for folderName in "SMAPI $version installer" "SMAPI $version installer for developers"; do
28-
# move files to Linux filesystem
29-
echo "Preparing $folderName.zip..."
30-
echo "-------------------------------------------------"
31-
echo "copying '$windowsBinPath/$folderName' to Linux filesystem..."
32-
cp -r "$windowsBinPath/$folderName" .
27+
# move files to Linux filesystem
28+
folderName = "SMAPI $version installer"
29+
echo "Preparing $folderName.zip..."
30+
echo "-------------------------------------------------"
31+
echo "copying '$windowsBinPath/$folderName' to Linux filesystem..."
32+
cp -r "$windowsBinPath/$folderName" .
3333

34-
# fix permissions
35-
echo "fixing permissions..."
36-
find "$folderName" -type d -exec chmod 755 {} \;
37-
find "$folderName" -type f -exec chmod 644 {} \;
38-
find "$folderName" -name "*.sh" -exec chmod 755 {} \;
39-
find "$folderName" -name "*.command" -exec chmod 755 {} \;
40-
find "$folderName" -name "SMAPI.Installer" -exec chmod 755 {} \;
41-
find "$folderName" -name "StardewModdingAPI" -exec chmod 755 {} \;
34+
# fix permissions
35+
echo "fixing permissions..."
36+
find "$folderName" -type d -exec chmod 755 {} \;
37+
find "$folderName" -type f -exec chmod 644 {} \;
38+
find "$folderName" -name "*.sh" -exec chmod 755 {} \;
39+
find "$folderName" -name "*.command" -exec chmod 755 {} \;
40+
find "$folderName" -name "SMAPI.Installer" -exec chmod 755 {} \;
41+
find "$folderName" -name "StardewModdingAPI" -exec chmod 755 {} \;
4242

43-
# convert bundle folder into final 'install.dat' files
44-
for build in ${buildFolders[@]}; do
45-
echo "packaging $folderName/internal/$build/install.dat..."
46-
pushd "$folderName/internal/$build/bundle" > /dev/null
47-
zip "install.dat" * --recurse-paths --quiet
48-
mv install.dat ../
49-
popd > /dev/null
43+
# convert bundle folder into final 'install.dat' files
44+
for build in ${buildFolders[@]}; do
45+
echo "packaging $folderName/internal/$build/install.dat..."
46+
pushd "$folderName/internal/$build/bundle" > /dev/null
47+
zip "install.dat" * --recurse-paths --quiet
48+
mv install.dat ../
49+
popd > /dev/null
5050

51-
rm -rf "$folderName/internal/$build/bundle"
52-
done
51+
rm -rf "$folderName/internal/$build/bundle"
52+
done
5353

54-
# zip installer
55-
echo "packaging installer..."
56-
zip -9 "$folderName.zip" "$folderName" --recurse-paths --quiet
54+
# zip installer
55+
echo "packaging installer..."
56+
zip -9 "$folderName.zip" "$folderName" --recurse-paths --quiet
5757

58-
# move zip back to Windows bin path
59-
echo "moving release zip to $windowsBinPath/$folderName.zip..."
60-
mv "$folderName.zip" "$windowsBinPath"
61-
rm -rf "$folderName"
58+
# move zip back to Windows bin path
59+
echo "moving release zip to $windowsBinPath/$folderName.zip..."
60+
mv "$folderName.zip" "$windowsBinPath"
61+
rm -rf "$folderName"
6262

63-
echo ""
64-
echo ""
65-
done
63+
echo ""
64+
echo ""
6665

6766
echo "Done!"

build/scripts/prepare-install-package.ps1

Lines changed: 5 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,6 @@ Write-Output "----------------------------"
154154
# init paths
155155
$installAssets = "src/SMAPI.Installer/assets"
156156
$packagePath = "bin/SMAPI installer"
157-
$packageDevPath = "bin/SMAPI installer for developers"
158157

159158
# init structure
160159
foreach ($folder in $folders) {
@@ -268,33 +267,23 @@ else {
268267
}
269268
}
270269

271-
# split into main + for-dev folders
272-
Copy-Item -Recurse "$packagePath" "$packageDevPath"
270+
# convert bundle folder into final 'install.dat' files
273271
foreach ($folder in $folders) {
274-
# disable developer mode in main package
275-
In-Place-Regex -Path "$packagePath/internal/$folder/bundle/smapi-internal/config.json" -Search "`"DeveloperMode`": true" -Replace "`"DeveloperMode`": false"
272+
$path = "$packagePath/internal/$folder"
276273

277-
# convert bundle folder into final 'install.dat' files
278-
foreach ($path in @("$packagePath/internal/$folder", "$packageDevPath/internal/$folder"))
279-
{
280-
Compress-Archive -Path "$path/bundle/*" -CompressionLevel Optimal -DestinationPath "$path/install.dat"
281-
if (!$skipBundleDeletion) {
282-
Remove-Item -Recurse -Force "$path/bundle"
283-
}
274+
Compress-Archive -Path "$path/bundle/*" -CompressionLevel Optimal -DestinationPath "$path/install.dat"
275+
if (!$skipBundleDeletion) {
276+
Remove-Item -Recurse -Force "$path/bundle"
284277
}
285278
}
286279

287280

288281
###########
289282
### Create release zips
290283
###########
291-
# rename folders
292284
Move-Item "$packagePath" "bin/SMAPI $version installer"
293-
Move-Item "$packageDevPath" "bin/SMAPI $version installer for developers"
294285

295-
# package files
296286
Compress-Archive -Path "bin/SMAPI $version installer" -DestinationPath "bin/SMAPI $version installer.zip" -CompressionLevel Optimal
297-
Compress-Archive -Path "bin/SMAPI $version installer for developers" -DestinationPath "bin/SMAPI $version installer for developers.zip" -CompressionLevel Optimal
298287

299288
Write-Output ""
300289
Write-Output "Done! Package created in ${pwd.Path}/bin."

docs/release-notes.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@
99
* SMAPI can now detect known malicious loose files in the `Mods` folder.
1010
* Updated internal mod blacklist.
1111

12+
* For mod authors:
13+
* SMAPI no longer has a separate 'for developers' version. Instead, you can now use [Generic Mod Config Menu](<https://www.nexusmods.com/stardewvalley/mods/5098>) to enable 'developer mode' in the console window options.
14+
1215
## 4.4.0
1316
Released 10 January 2026 for Stardew Valley 1.6.14 or later. See [release highlights](https://www.patreon.com/posts/147916705).
1417

src/SMAPI.Web/Controllers/IndexController.cs

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,8 @@ public async Task<ViewResult> Index()
5757
{
5858
// choose versions
5959
ReleaseVersion[] versions = await this.GetReleaseVersionsAsync();
60-
ReleaseVersion? stableVersion = versions.LastOrDefault(version => !version.IsForDevs);
61-
ReleaseVersion? stableVersionForDevs = versions.LastOrDefault(version => version.IsForDevs);
60+
ReleaseVersion? stableVersion = versions.LastOrDefault();
61+
ReleaseVersion? stableVersionForDevs = versions.LastOrDefault();
6262

6363
// render view
6464
IndexVersionModel stableVersionModel = stableVersion != null
@@ -123,12 +123,11 @@ private IEnumerable<ReleaseVersion> ParseReleaseVersions(GitRelease? release)
123123
if (asset.FileName.StartsWith("Z_"))
124124
continue;
125125

126-
Match match = Regex.Match(asset.FileName, @"SMAPI-(?<version>[\d\.]+(?:-.+)?)-installer(?<forDevs>-for-developers)?.zip");
126+
Match match = Regex.Match(asset.FileName, @"SMAPI-(?<version>[\d\.]+(?:-.+)?)-installer.zip");
127127
if (!match.Success || !SemanticVersion.TryParse(match.Groups["version"].Value, out ISemanticVersion? version))
128128
continue;
129-
bool isForDevs = match.Groups["forDevs"].Success;
130129

131-
yield return new ReleaseVersion(release, asset, version, isForDevs);
130+
yield return new ReleaseVersion(release, asset, version);
132131
}
133132
}
134133

@@ -147,9 +146,6 @@ private class ReleaseVersion
147146
/// <summary>The SMAPI version.</summary>
148147
public ISemanticVersion Version { get; }
149148

150-
/// <summary>Whether this is a 'for developers' download.</summary>
151-
public bool IsForDevs { get; }
152-
153149

154150
/*********
155151
** Public methods
@@ -158,13 +154,11 @@ private class ReleaseVersion
158154
/// <param name="release">The underlying GitHub release.</param>
159155
/// <param name="asset">The underlying download asset.</param>
160156
/// <param name="version">The SMAPI version.</param>
161-
/// <param name="isForDevs">Whether this is a 'for developers' download.</param>
162-
public ReleaseVersion(GitRelease release, GitAsset asset, ISemanticVersion version, bool isForDevs)
157+
public ReleaseVersion(GitRelease release, GitAsset asset, ISemanticVersion version)
163158
{
164159
this.Release = release;
165160
this.Asset = asset;
166161
this.Version = version;
167-
this.IsForDevs = isForDevs;
168162
}
169163
}
170164
}

src/SMAPI.Web/Views/Index/Index.cshtml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,6 @@
9191

9292
<h2 id="modcreators">For mod creators</h2>
9393
<ul>
94-
<li><a href="@Model.StableVersion.DevDownloadUrl">SMAPI @Model.StableVersion.Version for developers</a> (includes <a href="https://docs.microsoft.com/en-us/visualstudio/ide/using-intellisense">intellisense</a> and full console output)</li>
9594
<li><a href="https://stardewvalleywiki.com/Modding:Index">Modding documentation</a></li>
9695
<li><a href="https://github.com/Pathoschild/SMAPI">Source code</a></li>
9796
</ul>

src/SMAPI/SMAPI.config.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ in future SMAPI versions.
4949
*
5050
* Not recommended for most players.
5151
*/
52-
"DeveloperMode": true,
52+
"DeveloperMode": false,
5353

5454
/**
5555
* Whether SMAPI should listen for console input. Disabling this will prevent you from using

0 commit comments

Comments
 (0)