summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/file-CHMOD/CHMOD-write-only.cmake
blob: 1289efc1034f1305e04312bb2b4fbde9c54aed03 (plain)
1
2
3
4
5
6
file(REMOVE_RECURSE ${CMAKE_CURRENT_BINARY_DIR}/chmod-tests)
file(MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/chmod-tests)

file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/chmod-tests/a "CONTENT")
file(CHMOD ${CMAKE_CURRENT_BINARY_DIR}/chmod-tests/a PERMISSIONS OWNER_WRITE)
file(READ ${CMAKE_CURRENT_BINARY_DIR}/chmod-tests/a content)