fileMode

package
v1.30.16 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 3, 2023 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// FileModeA -rw-------: 只有拥有者有读写权限
	FileModeA = os.FileMode(0600)

	// FileModeB -rw-r--r--: 只有拥有者有读写权限;而属组用户和其他用户只有读权限
	FileModeB = os.FileMode(0644)

	// FileModeC -rwx------: 只有拥有者有读、写、执行权限
	FileModeC = os.FileMode(0700)

	// FileModeD -rwxr-xr-x: 拥有者有读、写、执行权限;而属组用户和其他用户只有读、执行权限
	FileModeD = os.FileMode(0755)

	// FileModeE -rwx--x--x: 拥有者有读、写、执行权限;而属组用户和其他用户只有执行权限
	FileModeE = os.FileMode(0711)

	// FileModeAllReadWrite -rw-rw-rw-: 所有用户 有 读、写权限
	FileModeAllReadWrite = os.FileMode(0666)

	// FileModeAll -rwxrwxrwx: 所有用户 有 读、写、执行权限
	FileModeAll = os.FileMode(0777)
)

参考:https://blog.csdn.net/qq_39131177/article/details/85060694

!!!:0开头,即八进制.

r: 读权限(4) w: 写权限(2) x: 执行权限(1) -: 无权限(0)

Variables

This section is empty.

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL