Skip to content

Instantly share code, notes, and snippets.

@ericdorsey
Last active September 10, 2017 17:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ericdorsey/e0164fb46f8acb16a9f39c7f2f9b15a3 to your computer and use it in GitHub Desktop.
Save ericdorsey/e0164fb46f8acb16a9f39c7f2f9b15a3 to your computer and use it in GitHub Desktop.
(Linux) List only hidden files, and only the file name

In Linux, list only hidden files, and only the file name (no owner, perms, etc)

$ ls -1d1 .!(|.)

This was useful in the context of creating an exclude list for some rsync jobs, where I only wanted to capture things like .bashrc and .vimrc, but didn't care bout a lot of the other profile config in the backup.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment