Solved

Bash Shell ls command to list directory

Posted on 2008-10-30
1
939 Views
Last Modified: 2013-12-26
I use the "ls" command to list the directory and get the output as below.
AAA.BB-1  
AAA.BB-10
AAA.BB-2  
AAA.BB-3  
AAA.BB-4  
AAA.BB-5  
AAA.BB-6  
AAA.BB-7  
AAA.BB-8  
AAA.BB-9  
I was wondering how I can list the directory in ascending order based on the last number of each file? The desired output should be looked as below.
AAA.BB-1  
AAA.BB-2  
AAA.BB-3  
AAA.BB-4  
AAA.BB-5  
AAA.BB-6  
AAA.BB-7  
AAA.BB-8  
AAA.BB-9  
AAA.BB-10
Any suggestions?
0
Comment
Question by:bin571
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 

Accepted Solution

by:
bin571 earned 0 total points
ID: 22844896
ls -U
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Over the years I've spent many an hour playing on hardened, DMZ'd servers, with only a sub-set of the usual GNU toy's to keep me company; frequently I've needed to save and send log or data extracts from these server back to my PC, or to others, and…
Whether you’re a college noob or a soon-to-be pro, these tips are sure to help you in your journey to becoming a programming ninja and stand out from the crowd.
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

632 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question