04-10-2002
If you need to list only top 10 files in an directory, then -
ls -l | head -11
you can also use - "ls -lt | head -11" for viewing 10 recently modified files.
Hope this is useful.
9 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
i would like to see an unix screen shot if anyone could take a screen shot of unix (7 Replies)
Discussion started by: royal
7 Replies
2. Shell Programming and Scripting
Hi,
I need to get some files from a server via ftp. normaly I use following scrip, it is worrking fine.
cd dir_name
ftp -v -n "10.76.170.17" << cmd
user "rbi" "rbi"
cd recordreceive
prompt... (0 Replies)
Discussion started by: maheshsri
0 Replies
3. Shell Programming and Scripting
i have a file called file1
cat file1
i am namish
namish lives in India
India and namish both are good.
I want to delete all the occurences of namish in one shot,if i do it with sed i guess all the lines will be deleted containing the pattern.Suggest me any idea without AWK.
Thanks... (6 Replies)
Discussion started by: namishtiwari
6 Replies
4. AIX
can any one give me a script which take a snap shot of Topas at a fix interval of 15min and save it in a perticular file!!!!!!!! (6 Replies)
Discussion started by: abhishek27
6 Replies
5. Shell Programming and Scripting
Okay, so im setting up a script to start my internet dependent scripts once I am connected to the net. It got complicated because of the different networks I frequent but it goes something like this:
n=1
iwconfig wlan0 > wireless.txt
m= grep -c MGHS /home/jake/Scripts/wireless.txt
o= grep -c... (7 Replies)
Discussion started by: arcnsparc
7 Replies
6. Shell Programming and Scripting
i have a dir called logs. In it i have some 350 files how to move all those files from directory logs to a new dir called archive
I want to do it in single shot
Below the command i m trying but not getting
find . -name "CurrentCollector*" -exec mv {} archive \;... (2 Replies)
Discussion started by: ali560045
2 Replies
7. Shell Programming and Scripting
i have a directory in which i have Multiple files:
Following are they====
-rw-r--r-- 1 root root 886 Jan 21 16:38 trunkn.xsd
-rw-r--r-- 1 root root 244 Jan 21 16:38 trunknameCache.xml
-rw-r--r-- 1 root root 1240 Jan 21 16:38 subscribercache.xsd
-rw-r--r-- 1 root ... (1 Reply)
Discussion started by: Aditya.Gurgaon
1 Replies
8. Shell Programming and Scripting
Is this possible?
#!/bin/ksh
for file in `*.idlesince`
do
while read inter time
do
printf "%s %s\n" "${inter}" "$(perl -e 'print scalar localtime('"${time}"') . "\n";')" >> "${file}.done"
done < "${file}"
done
The error I get is
line 9: router.idlesince: command not... (1 Reply)
Discussion started by: mrlayance
1 Replies
9. Shell Programming and Scripting
Hi All,
requirement is to find and remove the files from sub directories but it should exclude the files from parent directory.
At present i am using the below one but it finds and remove files from both parent and sub directories.
find ${PATH} -type f \( -name securitas\* -o -name \*gz... (1 Reply)
Discussion started by: Naveenkk
1 Replies
LEARN ABOUT DEBIAN
git-cherry
GIT-CHERRY(1) Git Manual GIT-CHERRY(1)
NAME
git-cherry - Find commits not merged upstream
SYNOPSIS
git cherry [-v] [<upstream> [<head> [<limit>]]]
DESCRIPTION
The changeset (or "diff") of each commit between the fork-point and <head> is compared against each commit between the fork-point and
<upstream>. The commits are compared with their patch id, obtained from the git patch-id program.
Every commit that doesn't exist in the <upstream> branch has its id (sha1) reported, prefixed by a symbol. The ones that have equivalent
change already in the <upstream> branch are prefixed with a minus (-) sign, and those that only exist in the <head> branch are prefixed
with a plus (+) symbol:
__*__*__*__*__> <upstream>
/
fork-point
\__+__+__-__+__+__-__+__> <head>
If a <limit> has been given then the commits along the <head> branch up to and including <limit> are not reported:
__*__*__*__*__> <upstream>
/
fork-point
\__*__*__<limit>__-__+__> <head>
Because git cherry compares the changeset rather than the commit id (sha1), you can use git cherry to find out if a commit you made locally
has been applied <upstream> under a different commit id. For example, this will happen if you're feeding patches <upstream> via email
rather than pushing or pulling commits directly.
OPTIONS
-v
Verbose.
<upstream>
Upstream branch to compare against. Defaults to the first tracked remote branch, if available.
<head>
Working branch; defaults to HEAD.
<limit>
Do not report commits up to (and including) limit.
SEE ALSO
git-patch-id(1)
GIT
Part of the git(1) suite
Git 1.7.10.4 11/24/2012 GIT-CHERRY(1)