如何使用“部署”;ghpages+;https";windows上的lektor方法?获取推拉错误:

如何使用“部署”;ghpages+;https";windows上的lektor方法?获取推拉错误:,windows,github,deployment,lektor,Windows,Github,Deployment,Lektor,我一直在不懈地尝试解决以下问题,同时将一个朋友的网页部署到使用。但我总是会遇到类似的错误: λ lektor deploy production Deploying to production Build cache: C:\Users\user\AppData\Roaming\Lektor\Cache\builds\6edf4ce4c35ce53180e6c7f3b6a081ae Target: ghpages+https://user/user.github.io Initial

我一直在不懈地尝试解决以下问题,同时将一个朋友的网页部署到使用。但我总是会遇到类似的错误:

λ lektor deploy production
Deploying to production
  Build cache: C:\Users\user\AppData\Roaming\Lektor\Cache\builds\6edf4ce4c35ce53180e6c7f3b6a081ae
  Target: ghpages+https://user/user.github.io
  Initialized empty Git repository in C:/Users/user/repos/repo/temp/.deploytempswkcet/scratch/.git/
  Fetching origin
  fatal: Couldn't find remote ref refs/heads/master
  error: Could not fetch origin
  warning: LF will be replaced by CRLF in about/index.html.
  The file will have its original line endings in your working directory.
  warning: LF will be replaced by CRLF in blog/first-post/index.html.
  The file will have its original line endings in your working directory.
  warning: LF will be replaced by CRLF in blog/index.html.
  The file will have its original line endings in your working directory.
  warning: LF will be replaced by CRLF in index.html.
  The file will have its original line endings in your working directory.
  warning: LF will be replaced by CRLF in projects/index.html.
  The file will have its original line endings in your working directory.
  bash: /dev/tty: No such device or address
  error: failed to execute prompt script (exit code 1)
  fatal: could not read Username for 'https://github.com': Invalid argument
Done!

我的配置当前设置如下:

[project]
name = repo

[servers.production]
target = ghpages+https://user/user.github.io
user = user
password = pass

解决此问题的另一种尝试是键入以下内容:

lektor deplot --username user --password password production
呈现以下结果:

Deploying to production
  Build cache: C:\Users\Aperez\AppData\Roaming\Lektor\Cache\builds\6edf4ce4c35ce53180e6c7f3b6a081ae
  Target: ghpages+https://johnmanruz/johnmanruz.github.io
  Initialized empty Git repository in C:/Users/Aperez/repos/profejohnruz/temp/.deploytempcvsfya/scratch/.git/
  fatal: bad config line 12 in file .git/config
  fatal: bad config line 12 in file .git/config
  fatal: bad config line 12 in file .git/config
  fatal: bad config line 12 in file .git/config
Done!
如果我的设置有问题,请告诉我。

查看以下内容时:

Fetching origin
  fatal: Couldn't find remote ref refs/heads/master
您可以尝试将第一个提交从本地回购推送到远程回购。

然后重试部署生产的
lektor

第一个错误已正确解决,现在剩下的唯一问题是第二个错误“无法读取用户名”。@AperezC您使用的是什么版本的Git?当您键入
git config-l
时,是否看到有关
credential.helper
的任何信息?不,不是这样的。我认为lektor的代码中有一个嵌入式git,因为它独立于我安装的git工作,或者至少看起来是这样。@AperezC您试图用ssh更改本地repo的源远程吗<代码>git远程设置url源git@github.com:username/repo.git@AperezC可能您已经为该GitHub用户帐户激活了2FA?()首先,我没有在文件.git/config中看到致命的:错误的配置第12行:第12行是什么?