Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

umask #178

Open
bacinsky opened this issue Jul 2, 2015 · 2 comments
Open

umask #178

bacinsky opened this issue Jul 2, 2015 · 2 comments

Comments

@bacinsky
Copy link

bacinsky commented Jul 2, 2015

Hi, the umask is used to set right file permissions of cached files in the FilePathCache

but I'm using the Assetc's FilesystemCache also but there is no umask fix, so I wonder if it will be good to provide that fix within the AssetManager or I have to handle it by myself. I think it's kind of a common issue, but maybe there is a better solution I dont' know.

class FilesystemCache extends \Assetic\Cache\FilesystemCache
{
    /**
     * {@inheritdoc}
     */
    public function set($key, $value)
    {
        $umask = umask(0);
        parent::set($key, $value);
        umask($umask);
    }
}
@RWOverdijk
Copy link
Owner

Hey :)

If this is a real issue with Assetic I think you should post your issue there.

@bacinsky
Copy link
Author

bacinsky commented Jul 3, 2015

I went through their issues and they recommend to set umask on a system level, but I don't think that is the best option. Anyways I'm using asset manager only for a development so I noticed this package is using umask to fix that behaviour so I assumed it will be nice ho have it here. But if this is not a case I will leave that fix in my development package.

kriswallsmith/assetic#599

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants