hi,
i'm creating a little menu for some users.
i'm running the command:
du -a /apps | sort -n -r | head -n 10 | nl
i then get the top 10 files by size in the /apps directory
the output is like this:
1 101415752 /apps
2 89188064 /apps/userA
3 74521335 /apps/userA/export
4 47999710 /apps/UserB
how do I assign a these outputs to variables?
so if the user selects 4, they move (cd) to /apps/UserB ??
thanks for any help