Fix problem with creating home from skel dir
Created by: stavamichal
Fix problem with creating home from skel dir
- command "cp -r" on directory copies also directory itself. If the destination of copying is also directory (in this case it is temp directory prepared for creating a new home) it copies whole target to the destination instead of copying only content of target to the destination. For this reason this behavior was changed to prevent this.
- added preservation of ACLs and links from the target directory. Command "cp -ar" instead of "cp -r". Command "chmod" is now called only on the target directory, not recursively.