Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7170609
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T15:14:50+00:00 2026-05-28T15:14:50+00:00

List all the files in /usr/bin whose filenames contain lowercase English alphabet characters only

  • 0

List all the files in /usr/bin whose filenames contain lowercase English alphabet
characters
only and also contain the word file as a (contiguous) substring.

For example, file and profiles are such files, but git-ls-files is not.

This is the exact question I have and I can only use grep, ls, cat and wc for it.

ls /usr/bin/ | grep '[^-]*file'

This is what I got so far and output is below. I dont know how to display for example just file since * is zero or more occurences. And no idea how to put lowercase thing in the regex as well..

check-binary-files
clean-binary-files
desktop-file-install
desktop-file-validate
ecryptfs-rewrite-file
file
filep
git-cat-file
git-diff-files
git-ls-files
git-merge-file
git-merge-one-file
git-unpack-file
lockfile
nsrfile
pamfile
pcprofiledump
pnmfile
ppufiles
profiles
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T15:14:50+00:00Added an answer on May 28, 2026 at 3:14 pm
    ls /usr/bin/ | grep --regex '^[[:lower:]]*file[[:lower:]]*$'
    

    The ^ and $ match the beginning and end of the string, respectively.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I need to list all files with size > 0 under a directory (where
I want to list all files in a directory Using PyroCMS. Using the Files
I want to list all files on an FTP server using PHP. According to
I hope to list all files in document directory using codes below for(NSString *path
I tried to write a script to list all files in directories and subdirectories
I'm making a script to list all files within a folder. The intention is
I'm trying to figure out how to list all files of an FTP folder
When I run echo `nslookup 100.100.100.100` in bash, it list all files (independent of
I want to list all .xml files in a dir and its subdir. I
How to recursively list all the files in a directory and child directories in

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.