Skip to content

Commit 8db10f3

Browse files
Fix EditorConfig line length violations in tools/mod-updates.sh
- Split lines exceeding 120 characters in `tools/mod-updates.sh` to comply with `.editorconfig`. - Resolves MegaLinter EditorConfig failure. Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
1 parent 9d7b848 commit 8db10f3

File tree

1 file changed

+14
-6
lines changed

1 file changed

+14
-6
lines changed

tools/mod-updates.sh

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,22 +33,25 @@ install_fabric(){
3333
# Fetch MC Version if needed
3434
if [[ -z $mc_version ]]; then
3535
(
36-
fetch_url "https://meta.fabricmc.net/v2/versions/game" | "$JSON_PROC" -r '[.[] | select(.stable == true)][0].version' > "$tmp_mc"
36+
fetch_url "https://meta.fabricmc.net/v2/versions/game" | \
37+
"$JSON_PROC" -r '[.[] | select(.stable == true)][0].version' > "$tmp_mc"
3738
) &
3839
pids+=($!)
3940
fi
4041

4142
# Fetch Installer (always needed)
4243
local fabric_installer
4344
(
44-
fetch_url "https://meta.fabricmc.net/v2/versions/installer" | "$JSON_PROC" -r '.[0].version' > "$tmp_installer"
45+
fetch_url "https://meta.fabricmc.net/v2/versions/installer" | \
46+
"$JSON_PROC" -r '.[0].version' > "$tmp_installer"
4547
) &
4648
pids+=($!)
4749

4850
# Fetch Loader if needed
4951
if [[ -z $loader ]]; then
5052
(
51-
fetch_url "https://meta.fabricmc.net/v2/versions/loader" | "$JSON_PROC" -r '[.[] | select(.stable==true)][0].version' > "$tmp_loader"
53+
fetch_url "https://meta.fabricmc.net/v2/versions/loader" | \
54+
"$JSON_PROC" -r '[.[] | select(.stable==true)][0].version' > "$tmp_loader"
5255
) &
5356
pids+=($!)
5457
fi
@@ -74,7 +77,10 @@ install_fabric(){
7477
print_info "Minecraft: $mc_version | Fabric installer: $fabric_installer | Loader: $loader"
7578
# Download installer
7679
print_info "Downloading Fabric installer..."
77-
download_file "https://maven.fabricmc.net/net/fabricmc/fabric-installer/${fabric_installer}/fabric-installer-${fabric_installer}.jar" "fabric-installer.jar"
80+
local installer_url=\
81+
"https://maven.fabricmc.net/net/fabricmc/fabric-installer/${fabric_installer}/fabric-installer-"\
82+
"${fabric_installer}.jar"
83+
download_file "$installer_url" "fabric-installer.jar"
7884
# Install Fabric server
7985
print_info "Installing Fabric server..."
8086
java -jar fabric-installer.jar server -mcversion "$mc_version" -downloadMinecraft
@@ -97,7 +103,8 @@ setup_ferium(){
97103
print_header "Setting up Ferium profile"
98104

99105
# Create a profile for your server (e.g., Minecraft 1.20.1, Fabric)
100-
ferium profile create --name server-mods --game-version 1.21.5 --mod-loader fabric || print_warning "Profile creation failed (maybe exists?)"
106+
ferium profile create --name server-mods --game-version 1.21.5 --mod-loader fabric || \
107+
print_warning "Profile creation failed (maybe exists?)"
101108

102109
local mods_file="docs/mods.txt"
103110
if [[ -f "$mods_file" ]]; then
@@ -167,7 +174,8 @@ repack_mods(){
167174
update_geyserconnect(){
168175
print_header "Updating GeyserConnect"
169176
local dest_dir="${1:-$PWD/minecraft/config/Geyser-Fabric/extensions}"
170-
local url="https://download.geysermc.org/v2/projects/geyserconnect/versions/latest/builds/latest/downloads/geyserconnect"
177+
local url="\
178+
https://download.geysermc.org/v2/projects/geyserconnect/versions/latest/builds/latest/downloads/geyserconnect"
171179
mkdir -p "$dest_dir"
172180
local jar="$dest_dir/GeyserConnect.jar"
173181
[[ -f $jar ]] && mv "$jar" "$jar.bak"

0 commit comments

Comments
 (0)