網路管理語言 Perl 入門與實作: | ||
---|---|---|
<<< Previous | 6. 檔案處理 | Next >>> |
stat 這個函式可以取得檔案 13 個屬性資料。用法如下:
$file = "index.html"; @attr=stat($file); print @attr[4,5], "\n\n"; # 印出 index.html 的 uid, gid |
stat 13 個屬性,請參考:stat.html
<<< Previous | Home | Next >>> |
6.7 改變檔案擁有者 | Up | 6.9 拷貝檔案 |