Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Thu 23 Oct 2014, 02:57
All times are UTC - 4
 Forum index » Off-Topic Area » Programming
Add script to puninstall Manna SOLVED
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [3 Posts]  
Author Message
oldyeller


Joined: 15 Nov 2011
Posts: 812
Location: Mishawaka IN

PostPosted: Fri 29 Mar 2013, 17:02    Post subject:  Add script to puninstall Manna SOLVED  

Hello Everyone,

I have made an puninstall script for Manna, But I need to add to this script so that if people want to uninstall it but want to keep the notes made with the Editor I am putting in Manna. they will have the option to keep or remove the files that will be in my-documents/Manna.

Here is the script:

Code:

#!/bin/sh

rm -f /root/Startup/Manna-Menu
rm -r /root/my-documents/Manna 
rm -f /usr/local/bin/Apocrypha
rm -f /usr/local/bin/Deepsleep
rm -f /usr/local/bin/HolyTrinity
rm -f /usr/local/bin/jasher
rm -f /usr/local/bin/kjv
rm -f /usr/local/bin/lifetimes
rm -f /usr/local/bin/Manna-Menu
rm -f /usr/local/bin/repentence
rm -f /usr/local/bin/rrj
rm -f /usr/local/bin/Surrender
rm -f /usr/local/bin/twelve
rm -f /usr/local/bin/wfg
rm -f /usr/local/bin/rmds
rm -f /usr/local/bin/rmht
rm -f /usr/local/bin/rmrep
rm -f /usr/local/bin/rmrrj
rm -f /usr/local/bin/rms
rm -r /usr/local/Manna
rm -f /usr/share/applications/manna.desktop
rm -f /usr/share/icons/hicolor/48x48/apps/Apocrypha.png
rm -f /usr/share/icons/hicolor/48x48/apps/Bible.png
rm -f /usr/share/icons/hicolor/48x48/apps/Book.png
rm -f /usr/share/icons/hicolor/48x48/apps/Book2.png
rm -f /usr/share/icons/hicolor/48x48/apps/Com.png
rm -f /usr/share/icons/hicolor/48x48/apps/jasher.png
rm -f /usr/share/icons/hicolor/48x48/apps/manna.png
rm -f /usr/share/icons/hicolor/scalable/apps/xiphos.svg
rm -f /usr/share/pixmaps/bibletime.xpm


Any help would be great Thanks

Last edited by oldyeller on Fri 29 Mar 2013, 23:19; edited 1 time in total
Back to top
View user's profile Send private message 
SFR


Joined: 26 Oct 2011
Posts: 1078

PostPosted: Fri 29 Mar 2013, 18:15    Post subject:  

Hey Oldyeller

Is Xdialog ok?
Code:
Xdialog -title="Uninstalling" --yesno "Remove contents of /root/my-documents/Manna?" 0 0
if [ $? -eq 0 ]; then
  rm -r /root/my-documents/Manna 
fi

If you'd like to ask an opposite question (to keep contents), just change the if coondition to:
if [ $? -eq 1 ]; then

(0 = yes, 1 = no, 255 = window's_been_closed)

BTW, you can also change the default yes/no buttons' labels:
Code:
Xdialog --ok-label="Keep" --cancel-label="Remove" --yesno "What to do with those files?" 0 0

Greetings!

_________________
[O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource
Omnia mea mecum porto.
Back to top
View user's profile Send private message 
oldyeller


Joined: 15 Nov 2011
Posts: 812
Location: Mishawaka IN

PostPosted: Fri 29 Mar 2013, 23:18    Post subject:  

Hi SFR,

Thanks this worked out just fine.


Cheers
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [3 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Off-Topic Area » Programming
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0502s ][ Queries: 12 (0.0087s) ][ GZIP on ]