linux - Is there a command to return the owner of a file? -



linux - Is there a command to return the owner of a file? -

is there shell command print owner of file?

i guess do:

ls -l | awk '{print $3}'

but feels there more straightforward reply problem.

try using stat(1)

[cnicutar@fresh ~]$ stat -c %u file.c cnicutar

there lots of format sequences available: user id, total size, etc.

linux shell scripting

Comments

Popular posts from this blog

delphi - blogger via idHTTP : error 400 bad request -

c++ - compiler errors when initializing EXPECT_CALL with function which has program_options::variables_map as parameter -

How do I check if an insert was successful with MySQLdb in Python? -