aa09
![]() |
|
|
|
|
|||||||
| General General questions about the FreeBSD operating system. Ask here if your question does not fit elsewhere. |
![]() |
|
|
Thread Tools | Display Modes |
|
#1
|
|||
|
|||
|
Hello,
I would like to know how can I make a custom command for FreeBSD 8.2? For example: I need to type : /usr/cst/no then sh open.sh. 1. how can I make a simple command for executing the file from that folder? for example : start command will execute the open.sh from /no/ folder. 2.How to set a default path when I open FreeBSD? 3.How to learn FreeBSD? I want to learn and understand the FreeBSD system, creating scripts and so on.. Thanks Last edited by SirDice; August 15th, 2012 at 11:41. Reason: It's 'FreeBSD', no exceptions: http://forums.freebsd.org/showthread.php?t=18043#FreeBSD |
|
#2
|
||||
|
||||
|
Quote:
Quote:
alias mycommand (cd /usr/cst/no && sh ./open.sh)Quote:
Code:
set path = (/sbin /bin /usr/sbin /usr/bin /usr/games /usr/local/sbin /usr/local/bin $HOME/bin)
__________________
Senior UNIX Engineer at Unix Support Nederland Experience is something you don't get until just after you need it. |
|
#3
|
|||
|
|||
|
As you see at the end of the path command above is $HOME/bin. What this means is if you
$ mkdir bin from your user's home dir, then any script you place in the bin directory will exec when you enter it on the command line. So create your self scripts containing any combination of commands you want, save to your /home/accountname/bin, rehash and then enter script on command line and it will run.
Last edited by phoenix; August 22nd, 2012 at 00:57. Reason: Please format your posts! |
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| [Solved] Show the full path in the command line | ccc | General | 11 | August 26th, 2011 00:53 |
| [Solved] Changing the default baud for cu command | bsdnewb | Embedded | 5 | March 4th, 2011 08:25 |
| make install /path/ arguments | sossego | Installation and Maintenance of FreeBSD Ports or Packages | 0 | June 6th, 2010 20:50 |
| [Solved] Custom command in install.cfg | FreddieB | Installing & Upgrading | 4 | June 1st, 2010 08:09 |
| It is possible to make a recovery disc or custom dvd | ericturgeon | Installing & Upgrading | 3 | March 26th, 2009 16:55 |