Created
December 20, 2017 11:05
-
-
Save Peranikov/2bc0a94e422abd41294d14b3729335c0 to your computer and use it in GitHub Desktop.
5–7-2 ファイルの操作
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ファイル名の変更 | |
File.renaem 'src', 'dest' | |
# ファイルの移動 | |
File.rename 'src', 'dir/dest' | |
# ファイルの削除 | |
File.unlink 'fname' | |
# シンボリックリンク | |
File.symlink 'origin', 'sym' | |
# ハードリンク | |
File.link 'origin', 'sym' | |
# ファイルモードの指定 | |
File.chmod 0600, 'fname' | |
# オーナー・グループの変更 | |
File.chown 216, 216, 'fname' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment