Sto cercando di capire come ordinare un elenco di file per nome e dimensione.
Come faccio a ordinare per nome e dimensione del file utilizzando "du -a" e non visualizzare le directory?
Bash - Elenca e ordina i file e le loro dimensioni e per nome e dimensione
Utilizzando "du -a"
1 ./locatedFiles
0 ./testDir/j.smith.c
0 ./testDir/j.smith
1 ./testDir/sampleFunc/arrays
2 ./testDir/sampleFunc
0 ./testDir/j.smith.txt
0 ./testDir/testing
0 ./testDir/test2
0 ./testDir/test3
0 ./testDir/test1
0 ./testDir/first/j.smith
0 ./testDir/first/test
1 ./testDir/first
1 ./testDir/second
1 ./testDir/third
6 ./testDir
Come posso elencare tutti i file senza directory, aggiungere le dimensioni dei file, e ordinare i file nome, poi in base alle dimensioni?
Grazie per il vostro aiuto
Vuoi ordinarlo per nome file? o percorso? – thekbb