Sponsored Content
Homework and Emergencies Homework & Coursework Questions Need some help with my homework Post 302494314 by ghostdog74 on Sunday 6th of February 2011 09:09:40 PM
Old 02-06-2011
Quote:
Originally Posted by ilikecows
1. Because the PATH variable defines the directories your shell looks in for commands you type that aren't built into the shell. For instance if you type ls, and ls isn't an internal shell command, it looks through the directories in PATH for an executable file with the same name as the command you typed and tries to execure it. /bin and /usr/bin are used to store commonly used executable files such as ls, grep, chmod, etc.

2. Because the `` quotes are command substitution quotes. the shell will execute the command between them and then substitute is ouput in place of `command` as if you had typed it. `date` tries to run a command named whatever date outputs on your system.

3. Its easiest to use three seperate commands. If it takes longer to figure out how to do something in one command than it takes to type 3 and computing resources aren't an issue because you are only going to do it once or you have a tiny amount of data, why waste your time trying to figure out how to make a complex command work?
Code:
cat foo1 > newfile
somecommand >> newfile
cat foo2 >> newfile

4. ${d-*} means if d is unset then assign * to d. see the parameter expansion section of the ksh, sh, or bash man page for more info.

5. yes
why are you doing his homework in full ?
This User Gave Thanks to ghostdog74 For This Post:
 

7 More Discussions You Might Find Interesting

1. Post Here to Contact Site Administrators and Moderators

Homework?

https://www.unix.com/shell-programming-scripting/113946-scripts.html Looks like an assignment or homework to me, does it to you? (5 Replies)
Discussion started by: TonyFullerMalv
5 Replies

2. UNIX for Dummies Questions & Answers

Homework :(

1. You have a very large file, named 'ColMe', tab-delimited, you are asked to process. You are told that each line in 'ColMe' has 7 columns, and that the values in the 5th column are integers. Using shell functions (and standard LINUX/UNIX filters), indicate how you would verify that these... (1 Reply)
Discussion started by: mb774
1 Replies

3. Homework & Coursework Questions

Homework Help.

Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted! 1. The problem statement, all variables and given/known data: Hello, My name is Jordan and studying at the New Bulgarian University in Sofiya. This is my homework but can... (2 Replies)
Discussion started by: freestar
2 Replies

4. Shell Programming and Scripting

Homework

1. Write a shell script to print the file names of all files having .txt extension of a given directory after converting to uppercase letters. The input (directory name) should be given as command line argument. The script will also check whether sufficient arguments are passed or not and whether... (1 Reply)
Discussion started by: aninda1989
1 Replies

5. Homework & Coursework Questions

Please help me with my homework!!!

A shell script is a script written for the shell, or command line interpreter, of an operating system. Typical operations performed by shell scripts include file manipulation, program execution, printing text etc. Shell : In computing, a shell is a piece of software that provides an interface for... (1 Reply)
Discussion started by: ubun
1 Replies

6. Homework & Coursework Questions

Homework

plz i need code to search about numbers like this : 962785785698 962795565488 962785321565 962777321684 962795979515 i need code to detect just numbers start with "96278" i need it in awk !! thanks (1 Reply)
Discussion started by: eyad mohammad
1 Replies

7. Homework & Coursework Questions

Homework Help

Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted! 1. The problem statement, all variables and given/known data: 2. Relevant commands, code, scripts, algorithms: Write a command to display lines ending with the... (1 Reply)
Discussion started by: elh009
1 Replies
DROP TEXT SEARCH 
TEMPLATE(7) PostgreSQL 9.2.7 Documentation DROP TEXT SEARCH TEMPLATE(7) NAME
DROP_TEXT_SEARCH_TEMPLATE - remove a text search template SYNOPSIS
DROP TEXT SEARCH TEMPLATE [ IF EXISTS ] name [ CASCADE | RESTRICT ] DESCRIPTION
DROP TEXT SEARCH TEMPLATE drops an existing text search template. You must be a superuser to use this command. PARAMETERS
IF EXISTS Do not throw an error if the text search template does not exist. A notice is issued in this case. name The name (optionally schema-qualified) of an existing text search template. CASCADE Automatically drop objects that depend on the text search template. RESTRICT Refuse to drop the text search template if any objects depend on it. This is the default. EXAMPLES
Remove the text search template thesaurus: DROP TEXT SEARCH TEMPLATE thesaurus; This command will not succeed if there are any existing text search dictionaries that use the template. Add CASCADE to drop such dictionaries along with the template. COMPATIBILITY
There is no DROP TEXT SEARCH TEMPLATE statement in the SQL standard. SEE ALSO
ALTER TEXT SEARCH TEMPLATE (ALTER_TEXT_SEARCH_TEMPLATE(7)), CREATE TEXT SEARCH TEMPLATE (CREATE_TEXT_SEARCH_TEMPLATE(7)) PostgreSQL 9.2.7 2014-02-17 DROP TEXT SEARCH TEMPLATE(7)
All times are GMT -4. The time now is 03:10 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy