Sponsored Content
Full Discussion: find and head -1
Top Forums UNIX for Dummies Questions & Answers find and head -1 Post 302417660 by tjmannonline on Friday 30th of April 2010 08:39:29 AM
Old 04-30-2010
find and head -1

i have lots of files in /law/prod and /law/dev, such as AP20PD, AP20WS, AP20.scr, AP20.rpt

if i am in /law DIR

Code:
find . -name AP20PD, found in /law/prod and /law/dev

i want to head -1 AP20PD from both location and >> /tmp/test.log


can i use find and head in one line ?

---------- Post updated at 08:39 AM ---------- Previous update was at 07:57 AM ----------

never mine. find . -name filename > /tmp/test.log and then i use while loop to head -1 does the trick for me. thank you anyway.

Last edited by zaxxon; 04-30-2010 at 10:25 AM.. Reason: use code tags please, ty
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

help.. I am in way over my head !!!!

my boss has done it again I have been sent to fix a unix issue and I ma hoping you can help three issues 1st. I have a printer that when you try to print to it the print job comes out on a diffrent printer. If I take the printer ( dot matrix thourgh a serail connection) to a diffrent local the... (3 Replies)
Discussion started by: oberon42
3 Replies

2. UNIX for Dummies Questions & Answers

simple 'head' question

I'm sorry, but the example in the man pages was no help. I know head -5 fileName will give you the first 5 lines of the file but how do you get like the 6th-13th lines only or one line before the end of the file? Sorry I just started learning the basics..... =( (3 Replies)
Discussion started by: terms5
3 Replies

3. Shell Programming and Scripting

head command

Hi All, How can the head command be used to extract only a particular line. By default head -n filename displays the first n lines. I want only the nth line. I couldn't get it from forum search. Thanks, Sumesh (6 Replies)
Discussion started by: sumesh.abraham
6 Replies

4. Programming

http HEAD reuest

I have written a c socket programe which can send the http GET request.But it dont work for HEAD reuest.can anyone help me.I am connected to internet via a proxy and the port/ip in the programe are proxies ones -------------------------------------------------- #include <stdlib.h> #include... (3 Replies)
Discussion started by: chamaraHe
3 Replies

5. Shell Programming and Scripting

head usage

$ct=1 head -n $ct file. When i used like this, i got an error , Bad usage of head Cant we use variables in place of number in HEAD. In my requirement for every iteration i should increase the number in Head and tail the last one. HOw can i achieve this (5 Replies)
Discussion started by: vasuarjula
5 Replies

6. UNIX for Dummies Questions & Answers

alternative for head command

Hi friends,I am new to unix and this is really a dummy question.but please help me out. How to simulate head command without using head command??? also tail command too,also more command. it is given as a homework to do....please tell me how to do (2 Replies)
Discussion started by: nikhilneela
2 Replies

7. Shell Programming and Scripting

head followed by variable??

I know that the common use of head is for example head -3 etc.Is there any possibility that,if i have a variable that equals to an integer(i=5),i can write head -i?? If not,what syntax or commands should i write down in order to have the same result? //maybe something lik head -"$variable" ? (2 Replies)
Discussion started by: bashuser2
2 Replies

8. Shell Programming and Scripting

Remove head for all the files

Hi all, i need to remove the header for all the files which is ending with .csv and append into one file example, test1.csv test2.csv test3.csv i tried with the below command, sed '1d' test*.csv> appendnew.csv but it deletes only the first file header. and appending all the... (11 Replies)
Discussion started by: baskivs
11 Replies

9. Homework & Coursework Questions

Unix find and head command 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: I've been stuck on this problem for 2 days now What command would you enter to list the first lines of all text... (11 Replies)
Discussion started by: partieboi37
11 Replies

10. HP-UX

How to find the head cleaning history on HP HP MSL4048 1 LT0-4 Ultrium 1840?

Please guide me how to get the head cleaning history on HP HP MSL4048 1 LT0-4 Ultrium 1840. (0 Replies)
Discussion started by: marunmeera
0 Replies
mlib_SignalLinear2uLaw(3MLIB)				    mediaLib Library Functions				     mlib_SignalLinear2uLaw(3MLIB)

NAME
mlib_SignalLinear2uLaw - ITU G.711 m-law and A-law compression and decompression SYNOPSIS
cc [ flag... ] file... -lmlib [ library... ] #include <mlib.h> mlib_status mlib_SignalLinear2uLaw(mlib_u8 *ucode, const mlib_s16 *pcm, mlib_s32 n); DESCRIPTION
The mlib_SignalLinear2uLaw() function performs ITU G.711 m-law and A-law compression and decompression in compliance with the ITU (Former CCITT) G.711 specification. PARAMETERS
The function takes the following arguments: ucode m-law code array. pcm Linear PCM sample array. n Number of samples in the source array. RETURN VALUES
The function returns MLIB_SUCCESS if successful. Otherwise it returns MLIB_FAILURE. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Interface Stability |Committed | +-----------------------------+-----------------------------+ |MT-Level |MT-Safe | +-----------------------------+-----------------------------+ SEE ALSO
mlib_SignalALaw2Linear(3MLIB), mlib_SignalALaw2uLaw(3MLIB), mlib_SignalLinear2ALaw(3MLIB), mlib_SignaluLaw2ALaw(3MLIB), mlib_Signalu- Law2Linear(3MLIB), attributes(5) SunOS 5.11 2 Mar 2007 mlib_SignalLinear2uLaw(3MLIB)
All times are GMT -4. The time now is 01:21 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy