Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minecraft Pi Server update #2437

Open
2 of 3 tasks
kidmakesreal opened this issue Aug 29, 2023 · 57 comments
Open
2 of 3 tasks

Minecraft Pi Server update #2437

kidmakesreal opened this issue Aug 29, 2023 · 57 comments

Comments

@kidmakesreal
Copy link

kidmakesreal commented Aug 29, 2023

What is the name of the app?

Minecraft Pi Server

(Optional) Where is the app hosted?

No response

About the app

a simple one click install mcpi server software

Upload file or Add PR Link

Minecraft Pi Server.zip

Confirmations

@github-actions
Copy link
Contributor

github-actions bot commented Aug 29, 2023

A zipfile was found in the body of an issue comment.
The sha1sum of the zip was: 1a028a974ff2d4844c4cd8c53a99a5db1024eca9

Click to show contents preview

Minecraft Pi Server/install-64

#!/bin/bash
version=2.4.8

#create server folder
sudo mkdir -p /usr/share/applications/mcpi_server
cd /usr/share/applications/mcpi_server


#download server
sudo wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-${version}-arm64.AppImage || error "failed to download server"

#make server executable
sudo chmod +x server.AppImage

#make desktop shortcut
mkdir -p /usr/share/applications || error "Could not make directory"
echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=.local/bin/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
" > ~/.local/share/applications/mcpi_server.desktop

enable_module fuse || exit 1

Minecraft Pi Server/install-32

#!/bin/bash
version=2.4.8

#create server folder
sudo mkdir -p /usr/share/applications/mcpi_server
cd /usr/share/applications/mcpi_server

#download server
sudo wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-${version}-armhf.AppImage || error "failed to download server"

#make server executable
sudo chmod +x server.AppImage

#make desktop shortcut
mkdir -p /usr/share/applications || error "Could not make directory"
echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=/usr/share/applications/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
" > ~/.local/share/applications/mcpi_server.desktop

enable_module fuse || exit 1

Minecraft Pi Server/credits

https://github.com/NoozAbooz/ for providing the appimage

Minecraft Pi Server/website

https://unschooledinventor.com/2023/08/diy-minecraft-pi-edition-server/

Minecraft Pi Server/description

I recently installed Minecraft pi edtition on my raspberry pi and wanted to start a minecraft pi server but found little documentation and had to figure it out on my own. So i created this simple one click installer for pi-apps.

Learn how to use this software here: https://unschooledinventor.com/2023/08/diy-minecraft-pi-edition-server/

Check out my YouTube channel: https://www.youtube.com/@kidmakesreal

Minecraft Pi Server/uninstall

#!/bin/bash

#remove server app image
rm -rf /usr/share/applications/mcpi_server/server.AppImage || error "Failed to remove server.appImage"

#remove shortcut
rm -rf /usr/share/applications/mcpi_server.desktop || error "Failed to remove Minecraft Pi Server shortcut"

@kidmakesreal
Copy link
Author

I've fixed all the previous problems with my scripts

@theofficialgman
Copy link
Collaborator

pi-apps prefers global installation of applications when possible. please refer to many other scripts that install globally

#download server
wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-2.4.8-arm64.AppImage || error "failed to download server"

correct URL to use version variable in appimage

@theofficialgman
Copy link
Collaborator

also please stop closing and opening new issues. that is unnecessary

if you want the github actions automated preview of the zipfile to change (instead of getting a new comment made), you can edit the body of the initial post to use your new zip

@kidmakesreal
Copy link
Author

also please stop closing and opening new issues. that is unnecessary

if you want the github actions automated preview of the zipfile to change (instead of getting a new comment made), you can edit the body of the initial post to use your new zip

sorry i didn't know you could do that im new to github

@kidmakesreal
Copy link
Author

pi-apps prefers global installation of applications when possible. please refer to many other scripts that install globally

#download server
wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-2.4.8-arm64.AppImage || error "failed to download server"

correct URL to use version variable in appimage

alright i fixed the url it should be good to go now

Repository owner deleted a comment from github-actions bot Sep 2, 2023
@theofficialgman
Copy link
Collaborator

again, there are still multiple issues. the use of apt directly inside of scripts is banned for almost all cases (refer again to our official script writing wiki linked to you before). also we prefer that global installations be done when possible (which is the case here) so you need to change to doing that.

@kidmakesreal
Copy link
Author

the use of apt directly inside of scripts is banned for almost all cases (refer again to our official script writing wiki linked to you before). also we prefer that global installations be done when possible (which is the case here) so you need to change to doing that.

what do you mean by that?

@theofficialgman
Copy link
Collaborator

theofficialgman commented Sep 2, 2023

local to the current user: ~, $HOME, /home/$USER. Don't use these
global: anywhere outside of the users home directory.

just pick any random pi-apps script type install to look at. the majority are global install based (eg: pixelorama https://github.com/Botspot/pi-apps/blob/master/apps/Pixelorama/install )

@kidmakesreal
Copy link
Author

local to the current user: ~, $HOME, /home/$USER. Don't use these global: anywhere outside of the users home directory.

just pick any random pi-apps script type install to look at. the majority are global install based (eg: pixelorama https://github.com/Botspot/pi-apps/blob/master/apps/Pixelorama/install )

oh ok thanks for helping me even though im not great at this

@kidmakesreal
Copy link
Author

local to the current user: ~, $HOME, /home/$USER. Don't use these global: anywhere outside of the users home directory.

just pick any random pi-apps script type install to look at. the majority are global install based (eg: pixelorama https://github.com/Botspot/pi-apps/blob/master/apps/Pixelorama/install )

ok i fixed that it should be good now

@Botspot
Copy link
Owner

Botspot commented Sep 2, 2023

It's still saving everything in the user's home directory.
The reason why this matters is for Pi systems that have multiple users. We try to make the app install in a way that all users can run the program.
Your script makes it only possible for the current user to see the program, because other users cannot access files in the current user's home folder.

And that is the problem: All app files are being saved to the current user's home folder, rather than to a global location.
~/.local/share/applications is a local location, which can only be accessed by the currently logged in user.
~/.local/bin/mcpi_server is a local location, which can only be accessed by the currently logged in user.
If my Pi has two user accounts and I login as user etaprime and install Minecraft Pi Server, I should be able to login as leepsp and still be able to run Minecraft Pi Server.

You should find the global equivalents to these locations, like /usr/share/applications or /usr/local/bin. It will require sudo to add files to these locations, but there are many good examples of pi-apps scripts doing it this way. Take another look at the Pixelorama app please. https://github.com/Botspot/pi-apps/blob/master/apps/Pixelorama/install

@kidmakesreal
Copy link
Author

kidmakesreal commented Sep 2, 2023

It's still saving everything in the user's home directory. The reason why this matters is for Pi systems that have multiple users. We try to make the app install in a way that all users can run the program. Your script makes it only possible for the current user to see the program, because other users cannot access files in the current user's home folder.

And that is the problem: All app files are being saved to the current user's home folder, rather than to a global location. ~/.local/share/applications is a local location, which can only be accessed by the currently logged in user. ~/.local/bin/mcpi_server is a local location, which can only be accessed by the currently logged in user. If my Pi has two user accounts and I login as user etaprime and install Minecraft Pi Server, I should be able to login as leepsp and still be able to run Minecraft Pi Server.

You should find the global equivalents to these locations, like /usr/share/applications or /usr/local/bin. It will require sudo to add files to these locations, but there are many good examples of pi-apps scripts doing it this way. Take another look at the Pixelorama app please. https://github.com/Botspot/pi-apps/blob/master/apps/Pixelorama/install

oh that makes sense i updated it to work that way thats a good idea to make it global for all users

@theofficialgman
Copy link
Collaborator

theofficialgman commented Sep 2, 2023

Minecraft Pi Server/wget-log.1
looks like you have multiple stray logfiles in your zip

@kidmakesreal
Copy link
Author

Minecraft Pi Server/wget-log.1 looks like you have a stray logfile in your zip

oops sorry i fixed that

@theofficialgman
Copy link
Collaborator

this is local ~/.local/share/applications

Icon=$HOME/pi-apps/apps/Minecraft Pi Server/icon-64.png this won't work for users that have pi-apps located elsewhere. refer to this again -> https://github.com/Botspot/pi-apps/blob/master/apps/Pixelorama/install

#update os
sudo apt-get update

again, pi-apps does not allow apps to use apt directly except under specific circumstances.

also your uninstall script needs correcting

also you need to enable the fuse module since this is an appimage. You can look at Musescore to see how to do this https://github.com/Botspot/pi-apps/blob/master/apps/MuseScore/install

@theofficialgman
Copy link
Collaborator

also @Botspot what are your thoughts on the actions bot here. Do you like that it edits the initial comment zip preview when the user edits their initial post or would it be clearer if it always made a new post (which would show up at the bottom)?

If you have other ideas I am all ears.

@kidmakesreal
Copy link
Author

this is local ~/.local/share/applications

Icon=$HOME/pi-apps/apps/Minecraft Pi Server/icon-64.png this won't work for users that have pi-apps located elsewhere. refer to this again -> https://github.com/Botspot/pi-apps/blob/master/apps/Pixelorama/install

#update os
sudo apt-get update

again, pi-apps does not allow apps to use apt directly except under specific circumstances.

also your uninstall script needs correcting

also you need to enable the fuse module since this is an appimage. You can look at Musescore to see how to do this https://github.com/Botspot/pi-apps/blob/master/apps/MuseScore/install

oh okay i fixed it

@theofficialgman
Copy link
Collaborator

still not fixed:

this is local ~/.local/share/applications

also you need to enable the fuse module since this is an appimage. You can look at Musescore to see how to do this https://github.com/Botspot/pi-apps/blob/master/apps/MuseScore/install

also I suggest using the 64x64 version of the icon in the .desktop file as it will be clearer

@kidmakesreal
Copy link
Author

still not fixed:

this is local ~/.local/share/applications
also you need to enable the fuse module since this is an appimage. You can look at Musescore to see how to do this https://github.com/Botspot/pi-apps/blob/master/apps/MuseScore/install

also I suggest using the 64x64 version of the icon in the .desktop file as it will be clearer

what is the fuse module for?

@theofficialgman
Copy link
Collaborator

also you need to enable the fuse module since this is an appimage

-> also you need to enable the fuse module since this is an appimage

using google "fuse appimage" -> "AppImages require FUSE version 2 to run. Filesystem in Userspace (FUSE) is a system that lets non-root users mount filesystems."

@Botspot
Copy link
Owner

Botspot commented Sep 2, 2023

also @Botspot what are your thoughts on the actions bot here. Do you like that it edits the initial comment zip preview when the user edits their initial post or would it be clearer if it always made a new post (which would show up at the bottom)?

If you have other ideas I am all ears.

@theofficialgman,
I think this issue in particular has shown how effective the bot can be for cases when a PR would be a bit much. I would recommend that in the future we advise the app-submitter to not edit their original post with a new zip, but instead post a new zip, for the bot to then reply with the zip preview. To prevent the page from getting too lengthy, I would recommend wrapping the preview in <details> tags, as seen on the README.

@kidmakesreal
Copy link
Author

kidmakesreal commented Sep 2, 2023

Heres the new file
Minecraft Pi Server.zip

@github-actions
Copy link
Contributor

github-actions bot commented Sep 2, 2023

A zipfile was found in the body of an issue comment.
The sha1sum of the zip was: 1a028a974ff2d4844c4cd8c53a99a5db1024eca9
The contents can be previewed below:

Minecraft Pi Server/install-64

#!/bin/bash
version=2.4.8

#create server folder
sudo mkdir -p /usr/share/applications/mcpi_server
cd /usr/share/applications/mcpi_server


#download server
sudo wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-${version}-arm64.AppImage || error "failed to download server"

#make server executable
sudo chmod +x server.AppImage

#make desktop shortcut
mkdir -p /usr/share/applications || error "Could not make directory"
echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=.local/bin/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
" > ~/.local/share/applications/mcpi_server.desktop

enable_module fuse || exit 1

Minecraft Pi Server/install-32

#!/bin/bash
version=2.4.8

#create server folder
sudo mkdir -p /usr/share/applications/mcpi_server
cd /usr/share/applications/mcpi_server

#download server
sudo wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-${version}-armhf.AppImage || error "failed to download server"

#make server executable
sudo chmod +x server.AppImage

#make desktop shortcut
mkdir -p /usr/share/applications || error "Could not make directory"
echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=/usr/share/applications/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
" > ~/.local/share/applications/mcpi_server.desktop

enable_module fuse || exit 1

Minecraft Pi Server/credits

https://github.com/NoozAbooz/ for providing the appimage

Minecraft Pi Server/website

https://unschooledinventor.com/2023/08/diy-minecraft-pi-edition-server/

Minecraft Pi Server/description

I recently installed Minecraft pi edtition on my raspberry pi and wanted to start a minecraft pi server but found little documentation and had to figure it out on my own. So i created this simple one click installer for pi-apps.

Learn how to use this software here: https://unschooledinventor.com/2023/08/diy-minecraft-pi-edition-server/

Check out my YouTube channel: https://www.youtube.com/@kidmakesreal

Minecraft Pi Server/uninstall

#!/bin/bash

#remove server app image
rm -rf /usr/share/applications/mcpi_server/server.AppImage || error "Failed to remove server.appImage"

#remove shortcut
rm -rf /usr/share/applications/mcpi_server.desktop || error "Failed to remove Minecraft Pi Server shortcut"

@theofficialgman
Copy link
Collaborator

theofficialgman commented Sep 2, 2023

I would recommend that in the future we advise the app-submitter to not edit their original post with a new zip, but instead post a new zip, for the bot to then reply with the zip preview.

@Botspot there is no reason we need to tell users which method to do.
Before this commit f6defd4 the bot would make a new post every time even if the edited the original post. I can revert to that while also implementing the hidden text

@kidmakesreal
Copy link
Author

also you need to enable the fuse module since this is an appimage

-> also you need to enable the fuse module since this is an appimage

using google "fuse appimage" -> "AppImages require FUSE version 2 to run. Filesystem in Userspace (FUSE) is a system that lets non-root users mount filesystems."

ok i did that im hoping its good now

@theofficialgman
Copy link
Collaborator

theofficialgman commented Sep 2, 2023

still not fixed:

this is local ~/.local/share/applications

^

@kidmakesreal
Copy link
Author

heres the file Minecraft.Pi.Server.zip i don't see where the issue is

that is the same file....

echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=.local/bin/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
" > ~/.local/share/applications/mcpi_server.desktop

this is local ~/.local/share/applications/mcpi_server.desktop I refer back to botspot's explaination -> #2437 (comment)

oh i see sorry about that
Minecraft Pi Server.zip

@github-actions
Copy link
Contributor

github-actions bot commented Sep 2, 2023

A zipfile was found in the body of your issue.
The sha1sum of the zip was: c8b312255302777e057f0d436678b82a52fb1741

Click to show contents preview

Minecraft Pi Server/Minecraft Pi Server/install-64

#!/bin/bash
version=2.4.8

#create server folder
sudo mkdir -p /usr/share/applications/mcpi_server
cd /usr/share/applications/mcpi_server


#download server
sudo wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-${version}-arm64.AppImage || error "failed to download server"

#make server executable
sudo chmod +x server.AppImage

#make desktop shortcut
mkdir -p /usr/share/applications || error "Could not make directory"
echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=/usr/share/applications/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
" > /usr/share/applications/mcpi_server.desktop

enable_module fuse || exit 1

Minecraft Pi Server/Minecraft Pi Server/install-32

#!/bin/bash
version=2.4.8

#create server folder
sudo mkdir -p /usr/share/applications/mcpi_server
cd /usr/share/applications/mcpi_server

#download server
sudo wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-${version}-armhf.AppImage || error "failed to download server"

#make server executable
sudo chmod +x server.AppImage

#make desktop shortcut
mkdir -p /usr/share/applications || error "Could not make directory"
echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=/usr/share/applications/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
" > /usr/share/applications/mcpi_server.desktop

enable_module fuse || exit 1

Minecraft Pi Server/Minecraft Pi Server/credits

https://github.com/NoozAbooz/ for providing the appimage

Minecraft Pi Server/Minecraft Pi Server/website

https://unschooledinventor.com/2023/08/diy-minecraft-pi-edition-server/

Minecraft Pi Server/Minecraft Pi Server/description

I recently installed Minecraft pi edtition on my raspberry pi and wanted to start a minecraft pi server but found little documentation and had to figure it out on my own. So i created this simple one click installer for pi-apps.

Learn how to use this software here: https://unschooledinventor.com/2023/08/diy-minecraft-pi-edition-server/

Check out my YouTube channel: https://www.youtube.com/@kidmakesreal

Minecraft Pi Server/Minecraft Pi Server/uninstall

#!/bin/bash

#remove server app image
rm -rf /usr/share/applications/mcpi_server/server.AppImage || error "Failed to remove server.appImage"

#remove shortcut
rm -rf /usr/share/applications/mcpi_server.desktop || error "Failed to remove Minecraft Pi Server shortcut"

@theofficialgman
Copy link
Collaborator

theofficialgman commented Sep 2, 2023

mkdir -p /usr/share/applications || error "Could not make directory"
" > /usr/share/applications/mcpi_server.desktop

refer again to #2437 (comment) , you can't write to or create a root owned directory as a regular user.

@theofficialgman
Copy link
Collaborator

also I'd personally prefer if the enable fuse module was placed directly after the version variable. that way if it fails then you aren't left with an unuseable application unless the user does an uninstall.

also you need a purge_packages in your uninstall if you have an enable_module

@github-actions
Copy link
Contributor

github-actions bot commented Sep 2, 2023

A zipfile was found in the body of an issue comment.
The sha1sum of the zip was: f8e82494afc74ca38e42b1d8f8b6a736a35a267a

Click to show contents preview

Minecraft Pi Server/install-64

#!/bin/bash
version=2.4.8

#create server folder
sudo mkdir -p /usr/share/applications/mcpi_server
cd /usr/share/applications/mcpi_server


#download server
sudo wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-${version}-arm64.AppImage || error "failed to download server"

#make server executable
sudo chmod +x server.AppImage

#make desktop shortcut
mkdir -p /usr/share/applications || error "Could not make directory"
echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=/usr/share/applicationsmcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
" > /usr/share/applications/mcpi_server.desktop

enable_module fuse || exit 1

Minecraft Pi Server/install-32

#!/bin/bash
version=2.4.8

#enable fuse
enable_module fuse || exit 1

#create server folder
sudo mkdir -p /usr/share/applications/mcpi_server
cd /usr/share/applications/mcpi_server

#download server
sudo wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-${version}-armhf.AppImage || error "failed to download server"

#make server executable
sudo chmod +x server.AppImage

#make desktop shortcut
sudo mkdir -p /usr/share/applications || error "Could not make directory"
sudo echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=/usr/share/applications/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
" > /usr/share/applications/mcpi_server.desktop

Minecraft Pi Server/credits

https://github.com/NoozAbooz/ for providing the appimage

Minecraft Pi Server/website

https://unschooledinventor.com/2023/08/diy-minecraft-pi-edition-server/

Minecraft Pi Server/description

I recently installed Minecraft pi edtition on my raspberry pi and wanted to start a minecraft pi server but found little documentation and had to figure it out on my own. So i created this simple one click installer for pi-apps.

Learn how to use this software here: https://unschooledinventor.com/2023/08/diy-minecraft-pi-edition-server/

Check out my YouTube channel: https://www.youtube.com/@kidmakesreal

Minecraft Pi Server/uninstall

#!/bin/bash

#remove server app image
rm -rf /usr/share/applications/mcpi_server/server.AppImage || error "Failed to remove server.appImage"

#remove shortcut
rm -rf /usr/share/applications/mcpi_server.desktop || error "Failed to remove Minecraft Pi Server shortcut"

#purge packages
purge_packages || exit 1

@kidmakesreal
Copy link
Author

also I'd personally prefer if the enable fuse module was placed directly after the version variable. that way if it fails then you aren't left with an unuseable application unless the user does an uninstall.

also you need a purge_packages in your uninstall if you have an enable_module

okay done
Minecraft Pi Server.zip

@theofficialgman
Copy link
Collaborator

@kidmakesreal you don't need to edit both the original post and make a new one with the zip. as per botspot's revised recommendations just make the new post.

" > /usr/share/applications/mcpi_server.desktop

still not fixed... refer again -> #2437 (comment)
also you have not updated install-64 to match install-32

I suggest you take a bit longer to digest and understand what we have been telling you to do rather than trying to solve the problem as quickly as possible and messing up. Think through what the commands are actually doing. There is no rush here, it won't be added today (or even this weekend likely) anyway.

@kidmakesreal
Copy link
Author

@kidmakesreal you don't need to edit both the original post and make a new one with the zip. as per botspot's revised recommendations just make the new post.

" > /usr/share/applications/mcpi_server.desktop

still not fixed... refer again -> #2437 (comment) also you have not updated install-64 to match install-32

I suggest you take a bit longer to digest and understand what we have been telling you to do rather than trying to solve the problem as quickly as possible and messing up. Think through what the commands are actually doing. There is no rush here, it won't be added today (or even this weekend likely) anyway.

ok sorry ill try harder

@theofficialgman
Copy link
Collaborator

ok sorry ill try harder

Don't worry about it. Nobody expects someone to become and expert on day one. Just make sure to give yourself time to digest and think about it.

We just have guidelines (some explicitly written down in our documentation and some implied) at pi-apps that we want all new scripts to follow.

@kidmakesreal
Copy link
Author

i cant get the global installation to work is it cool if i just make it install locally?

@kidmakesreal
Copy link
Author

kidmakesreal commented Sep 3, 2023

i think it would be better if the server folder was located in the home directory anyway due to then fact that to configure the server you have to change the server.properties file in the server folder and it would overcomplicate things for the user to have to be root to access it

@theofficialgman
Copy link
Collaborator

is there are reason why you chose to use the appimages from the release instead of the armhf/arm64 debs available?

all release types create their configuration files in the home directory as normal so that is a non-issue

@kidmakesreal
Copy link
Author

is there are reason why you chose to use the appimages from the release instead of the armhf/arm64 debs available?

all release types create their configuration files in the home directory as normal so that is a non-issue

where can i find the .deb files? i only was able to find appimages

@kidmakesreal
Copy link
Author

is there are reason why you chose to use the appimages from the release instead of the armhf/arm64 debs available?
all release types create their configuration files in the home directory as normal so that is a non-issue

where can i find the .deb files? i only was able to find appimages

nevermind found it

@kidmakesreal
Copy link
Author

is there are reason why you chose to use the appimages from the release instead of the armhf/arm64 debs available?

all release types create their configuration files in the home directory as normal so that is a non-issue

i have this desktop entry: "[Desktop Entry]
Name=Minecraft Pi Server
Exec=/usr/share/applications/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;" and for some reason it always gives me permission denied error when i try to run it do you know why this might be and how to fix it

@theofficialgman
Copy link
Collaborator

sudo mkdir -p /usr/share/applications/mcpi_server
cd /usr/share/applications/mcpi_server

#download server
sudo wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-${version}-armhf.AppImage || error "failed to download server"

application folders do not belong in the /usr/share/applications folder. that is only for the .desktop files, nothing else. any files or assets should be added to their own folder in /usr/share

Copy link
Contributor

A zipfile was found in the body of your issue.
The sha1sum of the zip was: ce3657d221d2a797c88ac1ec502342f4838bad5b

Click to show contents preview

Minecraft Pi Server/install-32

#!/bin/bash
version=2.4.8

#enable fuse
enable_module fuse || exit 1

#create server folder
sudo mkdir -p /usr/share/mcpi_server
cd /usr/share/mcpi_server

#download server
sudo wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-${version}-armhf.AppImage || error "failed to download server"

#make server executable
sudo chmod +x server.AppImage

#make desktop shortcut
sudo mkdir -p /usr/share/applications || error "Could not make directory"
cd /usr/share/applications

sudo echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=/usr/share/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
"

Minecraft Pi Server/website

https://unschooledinventor.com/2023/08/diy-minecraft-pi-edition-server/

Minecraft Pi Server/description

I recently installed Minecraft pi edtition on my raspberry pi and wanted to start a minecraft pi server but found little documentation and had to figure it out on my own. So i created this simple one click installer for pi-apps.

Learn how to use this software here: https://unschooledinventor.com/2023/08/diy-minecraft-pi-edition-server/

Check out my YouTube channel: https://www.youtube.com/@oldspiceman2583

Minecraft Pi Server/install-64

#!/bin/bash
version=2.4.8

#enable fuse
enable_module fuse || exit 1

#create server folder
sudo mkdir -p /usr/share/mcpi_server
cd /usr/share/mcpi_server


#download server
sudo wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-${version}-arm64.AppImage || error "failed to download server"

#make server executable
sudo chmod +x server.AppImage

#make desktop shortcut
sudo mkdir -p /usr/share/applications || error "Could not make directory"
cd /usr/share/applications

sudo echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=/usr/share/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
"

Minecraft Pi Server/credits

https://github.com/NoozAbooz/ for providing the appimage

Minecraft Pi Server/uninstall

#!/bin/bash

#remove server app image
sudo rm -rf /usr/share/mcpi_server/server.AppImage || error "Failed to remove server.appImage"

#remove shortcut
sudo rm -rf /usr/share/applications/mcpi_server.desktop || error "Failed to remove Minecraft Pi Server shortcut"

#purge packages
purge_packages || exit 1

@kidmakesreal
Copy link
Author

i've fixed all the previous errors in my scripts it should be all good now

@theofficialgman
Copy link
Collaborator

theofficialgman commented Oct 31, 2023

sudo echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=/usr/share/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
"

no .desktop file is created. this simply echos to the terminal. Writing to a .desktop file in a root owned location can be performed with a combination echo and | sudo tee command as seen in other scripts

@kidmakesreal
Copy link
Author

it gives me this error unless i run in root "bash: mcpi_server.desktop: Permission denied"

Copy link
Contributor

A zipfile was found in the body of your issue.
The sha1sum of the zip was: be8023bb9c674e44add565b1ae6b87e2b428391c

Click to show contents preview

Minecraft Pi Server/install-32

#!/bin/bash
version=2.4.8

#enable fuse
enable_module fuse || exit 1

#create server folder
sudo mkdir -p /usr/share/mcpi_server
cd /usr/share/mcpi_server

#download server
sudo wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-${version}-armhf.AppImage || error "failed to download server"

#make server executable
sudo chmod +x server.AppImage

#make desktop shortcut
sudo mkdir -p /usr/share/applications || error "Could not make directory"
cd /usr/share/applications

sudo echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=/usr/share/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
" | sudo tee mcpi_server.desktop

Minecraft Pi Server/website

https://unschooledinventor.com/2023/08/diy-minecraft-pi-edition-server/

Minecraft Pi Server/description

I recently installed Minecraft pi edtition on my raspberry pi and wanted to start a minecraft pi server but found little documentation and had to figure it out on my own. So i created this simple one click installer for pi-apps.

Learn how to use this software here: https://unschooledinventor.com/2023/08/diy-minecraft-pi-edition-server/

Check out my YouTube channel: https://www.youtube.com/@oldspiceman2583

Minecraft Pi Server/install-64

#!/bin/bash
version=2.4.8

#enable fuse
enable_module fuse || exit 1

#create server folder
sudo mkdir -p /usr/share/mcpi_server
cd /usr/share/mcpi_server


#download server
sudo wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-${version}-arm64.AppImage || error "failed to download server"

#make server executable
sudo chmod +x server.AppImage

#make desktop shortcut
sudo mkdir -p /usr/share/applications || error "Could not make directory"
cd /usr/share/applications

sudo echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=/usr/share/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
" | sudo tee mcpi_server.desktop

Minecraft Pi Server/credits

https://github.com/NoozAbooz/ for providing the appimage

Minecraft Pi Server/uninstall

#!/bin/bash

#remove server app image
sudo rm -rf /usr/share/mcpi_server/server.AppImage || error "Failed to remove server.appImage"

#remove shortcut
sudo rm -rf /usr/share/applications/mcpi_server.desktop || error "Failed to remove Minecraft Pi Server shortcut"

#purge packages
purge_packages || exit 1

@kidmakesreal
Copy link
Author

Ok sorry about that i think ive fixed it

@theofficialgman
Copy link
Collaborator

#make desktop shortcut
sudo mkdir -p /usr/share/applications || error "Could not make directory"
cd /usr/share/applications

sudo echo "[Desktop Entry]

/usr/share/applications is guaranteed to exist, there is no reason to make it.
sudo echo, echo does not need to be run with sudo
cd /usr/share/applications, it is better to tee directly to the full path of the file rather than rely on cd and then tee the file

Copy link
Contributor

github-actions bot commented Nov 1, 2023

A zipfile was found in the body of your issue.
The sha1sum of the zip was: 0e441d5596b8c1597dc430e0a440df026ee00471

Click to show contents preview

Minecraft Pi Server/install-32

#!/bin/bash
version=2.4.8

#enable fuse
enable_module fuse || exit 1

#create server folder
sudo mkdir -p /usr/share/mcpi_server
cd /usr/share/mcpi_server

#download server
sudo wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-${version}-armhf.AppImage || error "failed to download server"

#make server executable
sudo chmod +x server.AppImage

#make desktop shortcut
echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=/usr/share/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
" | sudo tee /usr/share/applications/mcpi_server.desktop

Minecraft Pi Server/website

https://unschooledinventor.com/2023/08/diy-minecraft-pi-edition-server/

Minecraft Pi Server/description

I recently installed Minecraft pi edtition on my raspberry pi and wanted to start a minecraft pi server but found little documentation and had to figure it out on my own. So i created this simple one click installer for pi-apps.

Learn how to use this software here: https://unschooledinventor.com/2023/08/diy-minecraft-pi-edition-server/

Check out my YouTube channel: https://www.youtube.com/@oldspiceman2583

Minecraft Pi Server/install-64

#!/bin/bash
version=2.4.8

#enable fuse
enable_module fuse || exit 1

#create server folder
sudo mkdir -p /usr/share/mcpi_server
cd /usr/share/mcpi_server


#download server
sudo wget -O server.AppImage https://github.com/NoozAbooz/mcpi-reborn-extended/releases/download/${version}/minecraft-pi-reborn-server-${version}-arm64.AppImage || error "failed to download server"

#make server executable
sudo chmod +x server.AppImage

#make desktop shortcut
echo "[Desktop Entry]
Name=Minecraft Pi Server
Exec=/usr/share/mcpi_server/server.AppImage
Comment=Multiplayer Server
Terminal=true
Icon=$(dirname "$0")/icon-64.png
Type=Application
Categories=Game;
" | sudo tee /usr/share/applications/mcpi_server.desktop

Minecraft Pi Server/credits

https://github.com/NoozAbooz/ for providing the appimage

Minecraft Pi Server/uninstall

#!/bin/bash

#remove server app image
sudo rm -rf /usr/share/mcpi_server/server.AppImage || error "Failed to remove server.appImage"

#remove shortcut
sudo rm -rf /usr/share/applications/mcpi_server.desktop || error "Failed to remove Minecraft Pi Server shortcut"

#purge packages
purge_packages || exit 1

@kidmakesreal
Copy link
Author

oh sorry its always the little things i miss

@kidmakesreal
Copy link
Author

Thank you for helping me make my script better

@kidmakesreal
Copy link
Author

I've fixed all the issues (that i know of) it should work now

@kidmakesreal
Copy link
Author

Hello anybody there?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants