简体   繁体   English

在Unix中解压缩创建具有000权限的文件

[英]Unzip in Unix create Files with 000 permission

I have created a zip in Windows. 我在Windows中创建了一个zip。 Transferred it into Unix. 将其转移到Unix中。 Used the unzip command to unzip the zip. 使用unzip命令解压缩zip。 It results in the files getting created with no permission. 这将导致在没有权限的情况下创建文件。 Something like "---------- 1 root root 10930 Nov 23 07:54 a.txt" 例如“ ---------- 1 root root 10930 Nov 23 07:54 a.txt”

This results in file permission issues. 这导致文件权限问题。 Is there any way i can unzip the zip to default umask value of the Operating system 有什么方法可以将zip解压缩为操作系统的默认umask值

What i came to know is unzip doesn't play much of a part in the file permissions. 我了解到的是,解压缩在文件权限中的作用并不大。 Whatever comes in us from the zip is unzipped in unix. 从zip中提取的所有内容都将在unix中解压缩。 The issue was related to Cygwin wherein the files when zipped comes with 000 permissions. 问题与Cygwin有关,其中压缩后的文件具有000权限。 cygwin.1069669.n5.nabble.com/… – Anand Builders cygwin.1069669.n5.nabble.com/…– Anand Builders

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM