📜  python 文件隐藏 - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:28.219000             🧑  作者: Mango

代码示例1
# os module
import os

# you can use the current directory you are in
fileName = "myFile.txt"

# or a different one with a path
fileName = "C:/Windows/myFile.txt"

# send in cmd
os.system("attrib +h " + fileName)
# +h for hidden
# -h for unhidden