LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Games
User Name
Password
Linux - Games This forum is for all discussion relating to gaming in Linux.

Notices


Reply
  Search this Thread
Old 07-15-2005, 09:31 AM   #1
jaakkop
Member
 
Registered: Aug 2004
Posts: 433

Rep: Reputation: 30
running Angband with one command


When playing Angband, I need to go to the directory where it's located and do the command ./angband. Can I somehow just play it with one command, like typing command angband <enter> and it starts? Distro is Slackware and Angband was compiled from source.
 
Old 07-16-2005, 10:02 AM   #2
csb
LQ Newbie
 
Registered: Jul 2005
Distribution: Debain
Posts: 5

Rep: Reputation: Disabled
There are many ways to do this, I'll try to explain a few, first you can type the directory and filename like so...
Code:
/home/you/wherever/it/is/installed/angband
or you can make a symbolic link
Code:
[cs@cacuts ~]$ln -s /home/you/wherever/it/is/installed/angband pie
so whenever you are at your home diretory, all you have to type is ./pie. ln will make symbolic link (think 'shortcut' in windows)
Code:
ln -s [file to link to] [file to be the link]
In your home directory, there is a file named .profile
(yours will look different, but something like mine)
Code:
[cs@cactus ~]$cat .profile
PATH=$HOME/bin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:/usr/games:.
export PATH HOME TERM
PS1="[\u@\h \W]\$"
note the "PATH=" line
It is a list of directories, all seperated by the ":". When you type 'ls' the shell looks for the ls program in all thoese directories. So you could change your PATH= to
Code:
PATH=$HOME/bin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:/usr/games:/home/you/wherever/it/is/installed/:.
This seems to be the solution that fits how you want to run your game the best.

Last edited by csb; 07-16-2005 at 10:05 AM.
 
Old 07-16-2005, 10:50 AM   #3
jaakkop
Member
 
Registered: Aug 2004
Posts: 433

Original Poster
Rep: Reputation: 30
Got it now. Made a small shell script.
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
sh command running as nobody chongluo Linux - Security 1 12-01-2004 06:03 AM
Angband help corbis_demon Linux - Games 1 09-17-2004 09:21 AM
Running a command from anywhere tez Linux - Newbie 5 02-27-2004 10:07 PM
command running on cd in Daem0hn Linux - General 3 07-22-2003 03:13 AM
auto running command.... / what have i done :| Gear_freak2000 Linux - General 13 06-12-2003 03:47 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Games

All times are GMT -5. The time now is 04:55 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration