Skip to content

Commit

Permalink
Wrote perms script iiitl#6
Browse files Browse the repository at this point in the history
  • Loading branch information
sanchitapatel29 committed Mar 16, 2024
1 parent 96850b2 commit 5bcb547
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions scripts/perms
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,13 @@
# 775 weather
# 664 ../README.md



for file in "$@";
do
# Getting octal permissions using stat
permissions=$(stat -c "%a" "$file")

# Displaying filename and permissions
echo "$permissions $file"
done

0 comments on commit 5bcb547

Please sign in to comment.