touch and permission

Hi All,

I have requirement to give permission to empty file. I do it in two steps.
But is it possible using touch command with some option for providing permission for a file.

Regards,
gehlnar

I dont think that is possible bcos the default umask value is 022... so the files that you create will be of 644 permission...but am not sure is there a way where you can change ur umask value...

can someone help????

umask value can be change.

umask {new value}

for example.

umask 222
  • nilesh

Thanks whiteboard/nilesh,

I don't want to change umask value and Looks like we cannot give permission while creating empty file.

Cheers,
gehlnar