vberlier / mudkip

A friendly Sphinx wrapper.
https://vberlier.github.io/mudkip/
MIT License
9 stars 2 forks source link

Mudkip fails to use repo specific git config #232

Open RitikShah opened 1 year ago

RitikShah commented 1 year ago

Since mudkip creates a git repo in a temp directory, it only listens to the --global git config. This means any values in the repo specific (or local) git config don't work which is either unexpected behavior or forces the command to fail (mostly when using it locally).

@ mudkip build --update-gh-pages 
Updating GitHub Pages with "docs"...
Initialized empty Git repository in /private/var/folders/6q/ybrmmgj52znd2g6xrm4w68sw0000gn/T/tmp10jw9dl6/.git/
Switched to a new branch 'gh-pages'
Author identity unknown

*** Please tell me who you are.

Run

  git config --global user.email "you@example.com"
  git config --global user.name "Your Name"

to set your account's default identity.
Omit --global to set the identity only in this repository.

Even though the message indicates that you can "omit" --global, it's incorrectly show since the git repo's location is in a different location.

vberlier commented 1 year ago

The temporary directory is kinda required to avoid messing up the user's workspace. I guess the temporary git repo could copy the settings over from the original though.