Reputation: 1
When trying to use hexo to submit blog content, many warnings suddenly occurred, and at the end it prompted that it could not connect to github.
warning: in the working copy of 'atom.xml', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'css/hbe.style.css', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'css/main.css', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'css/noscript.css', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'js/FunnyTitle.js', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'js/bookmark.js', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'js/clicklove.js', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'js/comments-buttons.js', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'js/comments.js', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'js/config.js', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'js/crypto-js.js', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'js/dytitle.js', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'js/excanvas.js', LF will be replaced by CRLF the next time Git touches it
fatal: unable to access 'https://github.com/zuquanzhi/myname.github.io.git/': Failed to connect to github.com port 443 after 21102 ms: Couldn't connect to server
FATAL Something's wrong. Maybe you can find the solution here: https://hexo.io/docs/troubleshooting.html
Error: Spawn failed
at ChildProcess.<anonymous> (D:\blog\myblog\node_modules\hexo-util\lib\spawn.js:51:21)
at ChildProcess.emit (node:events:517:28)
at cp.emit (D:\blog\myblog\node_modules\cross-spawn\lib\enoent.js:34:29)
at ChildProcess._handle.onexit (node:internal/child_process:292:12)
Network Connection Stability:
I began by verifying the stability of my internet connection to ensure that it remained active and robust. GitHub SSH Key Configuration:
I checked and confirmed the accurate configuration of my GitHub SSH keys. I considered generating new SSH keys and incorporating them into my GitHub account for enhanced security. I used the ssh -vT [email protected] command to assess SSH connection verbosity, providing intricate details regarding connection attempts. Firewall and Antivirus Checks:
I investigated whether my firewall or antivirus software could be impeding the connection. Temporarily disabling these applications helped me discern if they contributed to the issue. Hexo Configuration Assessment:
I scrutinized my Hexo _config.yml file to guarantee precise configuration, including the correct repository URL and SSH URL since I was using SSH. GitHub Repository Settings Review:
I confirmed that my GitHub repository settings permitted SSH connections and validated that my SSH key was successfully associated with my GitHub account. Hexo Version and Dependencies Inspection:
I ensured compatibility by confirming that I was using a Hexo version that aligned with my system requirements and that all dependencies were updated. GitHub Status Verification:
I visited the GitHub Status page (https://www.githubstatus.com/) to ascertain whether any ongoing issues were affecting GitHub services. Error Messages Examination:
I paid close attention to specific error messages or warnings encountered during the process, as this information was pivotal for targeted issue resolution. Hexo Plugins Evaluation:
If deployment involved Hexo plugins, I scrutinized their configurations to ensure accuracy and compatibility with my Hexo version. Git Configuration Review:
I examined my Git configuration to ensure correctness, encompassing details such as my configured name and email.
Upvotes: 0
Views: 155
Reputation: 5640
This is not an SSH problem: you told that system to connect to GitHub using HTTPS (evidence is in the error, which mentions https://github.com/zuquanzhi/myname.github.io.git
and not [email protected]:zuquanzhi/myname.github.io.git
or ssh://[email protected]/zuquanzhi/myname.github.io.git
). For whatever reason (most likely a firewall or proxy issue), that HTTPS request is timing out.
(Also: the user.name
and user.email
parameters in your Git config have nothing to do with authentication. They are only there to indicate the author of a commit. Changing those will not affect how you connect to GitHub or any other service.)
You can change the remote URL in that repository with git remote set-url origin [email protected]:zuquanzhi/myname.github.io.git
- that will update the origin
remote to use SSH for that GitHub repository.
Upvotes: 1