Fedora Linux Support Community & Resources Center
  #1  
Old 28th June 2006, 11:55 AM
electroconvulsi Offline
Registered User
 
Join Date: May 2006
Location: Sydney Australia (GMT +10)
Age: 43
Posts: 123
How do you create scripts or automation tasks?

Hi ive just recently installed nicotine on my system and I can only start it by browsing to the folder in terminal and then executing a command to start it. I tried to create an RPM as advised by the install help document that came with it but it only created a new install tree rather than an RPM. The question is can I make a script that will execute these 2 commands
cd /usr/bin/nicotine+-1.2.2
python ./nicotine

for me and then link it to an item on my menu so I dont have to go into terminal and run the commands everytime I want to start the program?

Or does anyone know what it takes to create an RPM from the source tree?
__________________
electroconvulsive :cool:
Reply With Quote
  #2  
Old 28th June 2006, 01:24 PM
multescugeorge@ Offline
Registered User
 
Join Date: Jun 2005
Posts: 722
about the script, use these comands in the terminal:
cat >> /home/nicotine
#!/bin/sh
cd /usr/bin/nicotine+-1.2.2
python ./nicotine
press ctrl-C
chmod 755 /home/nicotine
now you can take that script and execute it at will.
Never tried to create a rpm, and can't give advice there
Reply With Quote
  #3  
Old 28th June 2006, 01:27 PM
multescugeorge@ Offline
Registered User
 
Join Date: Jun 2005
Posts: 722
Kde has a easy way edit, just right-clik on the kmenu button in the taskbar, and select edit.
The comand to execute the script is:
/home/./nicotine
Reply With Quote
  #4  
Old 28th June 2006, 01:31 PM
electroconvulsi Offline
Registered User
 
Join Date: May 2006
Location: Sydney Australia (GMT +10)
Age: 43
Posts: 123
Thanks for the advice multescugeorge@. But I want to know what the commands mean. The first command seems to not want to execute so I need to know what i'm doing. Just so I can get it going and for educational purposes as well.
__________________
electroconvulsive :cool:
Reply With Quote
  #5  
Old 28th June 2006, 02:27 PM
Jongi Offline
Registered User
 
Join Date: Oct 2005
Posts: 1,952
you'll also probably need to do a:

# chmod +x /home/nicotine
Reply With Quote
  #6  
Old 28th June 2006, 03:24 PM
electroconvulsi Offline
Registered User
 
Join Date: May 2006
Location: Sydney Australia (GMT +10)
Age: 43
Posts: 123
The command cat >> /home/nicotine does not seem to execute. Terminal hangs when this command is used. Is this becauase you are using KDE and not gnome as I am. I am also executiing this from the root account. What does this command do? does it create a file? if it does I can create it manually.
__________________
electroconvulsive :cool:
Reply With Quote
  #7  
Old 28th June 2006, 03:36 PM
electroconvulsi Offline
Registered User
 
Join Date: May 2006
Location: Sydney Australia (GMT +10)
Age: 43
Posts: 123
Thanks I got it happening sorry about the superphelous question. I just thought that without the username etc. in terminal it wouldnt work but that is what the CTRL+C was for to finish the command. AHA. Now if i substitute home for another directory in the first line it will create the shell script in that directory and will still work wont it? Or can I move the shell script to any folder of my choice?

Thankyou so much. The information was invaluable.
__________________
electroconvulsive :cool:
Reply With Quote
Reply

Tags
automation, create, scripts, tasks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
F8 keyring automation in KDE? Frank616 Installation, Upgrades and Live Media 5 22nd December 2007 09:11 AM
Batch Automation/Scripts in GIMP Logik Using Fedora 3 14th December 2007 12:38 AM
Automation of modprobe/dhclient mijokijo Using Fedora 0 19th June 2005 04:03 AM
Nvidia graphics automation jameson Using Fedora 8 24th August 2004 06:58 AM


Current GMT-time: 19:38 (Wednesday, 23-04-2014)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat