The 05-VuePress line to deploy to build your exclusive blog

1, the project generates a default blog

  

 2, package upload github

1)yarn build

2) to the directory  E: \ myOwn \ test \ vuepress02 \ blog \ .vuepress \ dist

3)git init

4)git add -A

5)git commit -m 'deploy'

6) set the mailbox and username

7)git push -f [email protected]:pfSlight/myblog.git master:gh-pages

8) I had to generate rsa key ,, there is no need to regenerate, you can lower only need to configure , if you need to generate and configuration, please refer to this blog  https://blog.csdn.net/weixin_39340288/article/details/81541817

9) Click on the link below you can see the settings ,, project deployment

10) you can see the page without style , open the console error  Failed to load resource: the server responded with a status of 404 ()

 11) If you intend to publish https://<USERNAME or GROUP>.github.io/<REPO>/ (that is to say your warehouse  https://github.com/<USERNAME>/<REPO>), will be  base set  "/<REPO>/".

  So we need to set base properties in config.js file

module.exports = {
  title: 'VuePress Blog Example',
  description: 'This is a blog example built by VuePress',
  theme: '@vuepress/theme-blog', // OR shortcut: @vuepress/blog
  base: "/myblog/",
  themeConfig: {},
}

 12) repackaged, and the re-Push ,, normal show

 

 13) the code needs to be synchronized to a remote repository to

  # Link remote repository
  git remote add origin https://github.com/pfSlight/myblog.git

  # Got me to a remote repository file
  git pull --rebase origin master

  # Sync update code
  git push -u origin master

 

This is to get away with it ,,, I wish smooth

Guess you like

Origin www.cnblogs.com/slightFly/p/12635591.html