Skip to main content
added 5 characters in body
Source Link
Kira
  • 4.9k
  • 3
  • 22
  • 35

This onlinerone-liner should work:

find httpdocs -mindepth 2 -name In | xargs ls -1 | awk '$0 ~ /httpdocs.*In/{name=$0; start=NR} (NR-start)==50{print name;}'

It will first find all In directories, then list all its files, and, finally, filter those with more than 50 files.

Adjust -mindepth according to your start folder.

This onliner should work:

find httpdocs -mindepth 2 -name In | xargs ls -1 | awk '$0 ~ /httpdocs.*In/{name=$0; start=NR} (NR-start)==50{print name;}'

It will first find all In directories, then list all its files and finally filter those with more than 50 files.

Adjust -mindepth according to your start folder.

This one-liner should work:

find httpdocs -mindepth 2 -name In | xargs ls -1 | awk '$0 ~ /httpdocs.*In/{name=$0; start=NR} (NR-start)==50{print name;}'

It will first find all In directories, then list all its files, and, finally, filter those with more than 50 files.

Adjust -mindepth according to your start folder.

added 192 characters in body
Source Link
Kira
  • 4.9k
  • 3
  • 22
  • 35

This onliner should work:

find httpdocs -mindepth 2 -name In | xargs ls -1 | awk '$0 ~ /httpdocs.*In/{name=$0; start=NR} (NR-start)==50{print name;}'

It will first find all In directories, then list all its files and finally filter those with more than 50 files.

Adjust -mindepth according to your start folder.

This should work:

find httpdocs -name In | xargs ls -1 | awk '$0 ~ /httpdocs.*In/{name=$0; start=NR} (NR-start)==50{print name;}'

This onliner should work:

find httpdocs -mindepth 2 -name In | xargs ls -1 | awk '$0 ~ /httpdocs.*In/{name=$0; start=NR} (NR-start)==50{print name;}'

It will first find all In directories, then list all its files and finally filter those with more than 50 files.

Adjust -mindepth according to your start folder.

Source Link
Kira
  • 4.9k
  • 3
  • 22
  • 35

This should work:

find httpdocs -name In | xargs ls -1 | awk '$0 ~ /httpdocs.*In/{name=$0; start=NR} (NR-start)==50{print name;}'