3

Deploying to github pages with gh-pages

 2 years ago
source link: https://www.kevinhooke.com/2022/09/12/deploying-to-github-pages-with-gh-pages/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

Deploying to github pages with gh-pages

Using gh-pages npm module to build and deploy a React app to github pages I get this 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).

According to this answer to an issue logged on the project, gh-pages expects your remote repo to be named ‘origin’ and doesn’t work if you use any other name when you ‘get remote add’ you repo for a project. Add the same repo with the name ‘origin’ and then it works as expected.

CategoriesKev's BlogTagsgit, github, github pages

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Comment *

Name *

Email *

Website

Save my name, email, and website in this browser for the next time I comment.

Notify me of follow-up comments by email.

Notify me of new posts by email.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Post navigation


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK