Title: Permissions error
Last modified: August 22, 2016

---

# Permissions error

 *  Resolved [ssirag](https://wordpress.org/support/users/ssirag/)
 * (@ssirag)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/permissions-error-10/)
 * I’m trying my first pull after installing the plugin, but I’m getting an error“
   Revisr requires write permissions to the repository. The recommended settings
   are 755 for directories, and 644 for files.”
 * I’ve set the .git directory permissions as follows (www-data is the WordPress
   administrative account). What am I missing?
 * drwxr-sr-x 8 root www-data 4.0K Jan 7 16:37 .
    drwxr-sr-x 4 root www-data 4.0K
   Oct 17 14:47 .. drwxr-sr-x 2 root www-data 4.0K Oct 17 14:47 branches -rwxr-xr-
   x 1 root www-data 13 Dec 5 10:49 COMMIT_EDITMSG -rwxr-xr-x 1 root www-data 255
   Dec 5 10:49 config -rwxr-xr-x 1 root www-data 73 Dec 5 10:49 description -rwxr-
   xr-x 1 root www-data 203 Dec 5 10:49 FETCH_HEAD -rwxr-xr-x 1 root www-data 20
   Dec 5 10:49 HEAD drwxr-sr-x 2 root www-data 4.0K Oct 17 14:47 hooks -rw-r–r– 
   1 root www-data 23 Jan 7 16:37 .htaccess -rwxr-xr-x 1 root www-data 399K Dec 
   5 10:49 index drwxr-sr-x 2 root www-data 4.0K Oct 17 14:47 info drwxr-sr-x 3 
   root www-data 4.0K Oct 17 14:48 logs drwxr-sr-x 260 root www-data 4.0K Oct 17
   14:51 objects drwxr-sr-x 5 root www-data 4.0K Oct 17 14:48 refs
 * [https://wordpress.org/plugins/revisr/](https://wordpress.org/plugins/revisr/)

Viewing 11 replies - 1 through 11 (of 11 total)

 *  Plugin Author [Expanded Fronts](https://wordpress.org/support/users/expandedfronts/)
 * (@expandedfronts)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/permissions-error-10/#post-5646724)
 * Hello,
 * Is the parent “.git” directory writeable by www-data as well?
 *  Thread Starter [ssirag](https://wordpress.org/support/users/ssirag/)
 * (@ssirag)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/permissions-error-10/#post-5646936)
 * OK…I’ve resolved the local permissions issue…now however it seems to be having
   a remote authentication issue. I get “Error pushing to the remote repository.
   The remote repository could be ahead, or there may be an authentication issue.”
 * From the root command prompt, however, I can run a full commit and push cycle
   with no issues.
 * I’ve added the private key that authenticates this server with bitbucket in the/
   var/www/vhosts/.ssh directory. Is that the right location?
 *  Plugin Author [Expanded Fronts](https://wordpress.org/support/users/expandedfronts/)
 * (@expandedfronts)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/permissions-error-10/#post-5646982)
 * Hello,
 * For the sake of troubleshooting, can you please confirm if the HTTPS method as
   mentioned [here](https://revisr.io/documentation/#remote) works for you?
 *  Thread Starter [ssirag](https://wordpress.org/support/users/ssirag/)
 * (@ssirag)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/permissions-error-10/#post-5646985)
 * Same error when using the https URL of the repo.
 *  Plugin Author [Expanded Fronts](https://wordpress.org/support/users/expandedfronts/)
 * (@expandedfronts)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/permissions-error-10/#post-5646988)
 * Hi,
 * Was this repo created within Revisr, or was it created manually?
 * Sorry for all of the questions, but there are a few possible reasons for this
   occurring and the answers will hopefully point us in the right direction.
 * Let me know, thanks!
 *  Thread Starter [ssirag](https://wordpress.org/support/users/ssirag/)
 * (@ssirag)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/permissions-error-10/#post-5646997)
 * The local repo was created via command line.
 *  Plugin Author [Expanded Fronts](https://wordpress.org/support/users/expandedfronts/)
 * (@expandedfronts)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/permissions-error-10/#post-5647008)
 * Hi ssirag,
 * If you’re having issues with Revisr and it’s working normally via command line,
   99% of the time it’s because of either permissions (and it sounds like you resolved
   that) or the enivronment path to isn’t available to Apache (or NGINX if you’re
   using that).
 * If possible, I’d create a test file with the below:
    `<?php echo exec( 'which
   git' ); ?>`
 * And add it to your WordPress install, then visit in the browser. If it returns
   nothing, then it’s a path issue.
 * I wonder if having all of those files owned by root could be causing the issue,
   or did you change that?
 *  Thread Starter [ssirag](https://wordpress.org/support/users/ssirag/)
 * (@ssirag)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/permissions-error-10/#post-5647013)
 * Everything is owned by www-data…
 * the ‘which git’ function returns:
 * /usr/bin/git
 *  Thread Starter [ssirag](https://wordpress.org/support/users/ssirag/)
 * (@ssirag)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/permissions-error-10/#post-5647016)
 * OK, we got it working. Found 2 specific issues:
 * 1. I had an “@” in my bitbucket password, which is why the https config was failing.
 * 2. As we were dealing with an existing repo, we had to run this on the local 
   server repo in order to get it working first time:
 * git fetch –all
    git reset –hard origin/master
 *  Plugin Author [Expanded Fronts](https://wordpress.org/support/users/expandedfronts/)
 * (@expandedfronts)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/permissions-error-10/#post-5647017)
 * Hi,
 * Glad you were able to get this resolved. Will definitely look further into the“
   @” character causing an issue with your password, and I’ve created an issue [here](https://github.com/ExpandedFronts/Revisr/issues/23)
   to make sure it’ll be addressed for next release.
 * Will also look further into #2, as I normally don’t have to do that and a “Pull
   Changes” from within Revisr normally is sufficient to get the local even with
   the remote. Did you try that first by any chance and it still didn’t work?
 *  Thread Starter [ssirag](https://wordpress.org/support/users/ssirag/)
 * (@ssirag)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/permissions-error-10/#post-5647021)
 * Yes, I tried to pull first but it wouldn’t overwrite the local files until i 
   did the hard reset.

Viewing 11 replies - 1 through 11 (of 11 total)

The topic ‘Permissions error’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/revisr_ecf0f1.svg)
 * [Revisr](https://wordpress.org/plugins/revisr/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/revisr/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/revisr/)
 * [Active Topics](https://wordpress.org/support/plugin/revisr/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/revisr/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/revisr/reviews/)

 * 11 replies
 * 2 participants
 * Last reply from: [ssirag](https://wordpress.org/support/users/ssirag/)
 * Last activity: [11 years, 4 months ago](https://wordpress.org/support/topic/permissions-error-10/#post-5647021)
 * Status: resolved