You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In my case, my repo is in the external drive.
And git adds new policy after version 2.35.2 that will prevent git command executes in repo on external drive until add a exception for that directory in git config.
When deploying, gh-pages will clone a repo to node_modules/.cache/gh-pages , but running git command in that repo are blocked by the policy.
So when gh-pages try to run git config --get remote.$REMOTE.url in that cloned repo to get the remote setting will get exit code 1 from git command.
By default, gh-pages consider that remote dosen't exists and throw error
Failed to get remote.origin.url (task must either be run in a git repository with a configured origin remote or must be configured with the "repo" option).
Workaround
add that cache repo path or * to git global config safe.directory
Bro, You are amazing
Thanks a lot
This issue also happens to me.
What I found
In my case, my repo is in the external drive.
And git adds new policy after version 2.35.2 that will prevent git command executes in repo on external drive until add a exception for that directory in git config.
When deploying, gh-pages will clone a repo to
node_modules/.cache/gh-pages
, but running git command in that repo are blocked by the policy.So when gh-pages try to run
git config --get remote.$REMOTE.url
in that cloned repo to get the remote setting will get exit code 1 fromgit
command.By default, gh-pages consider that remote dosen't exists and throw error
Workaround
add that cache repo path or
*
to git global configsafe.directory
Originally posted by @nyraa in #443 (comment)
The text was updated successfully, but these errors were encountered: