Linux学习之路我用 Linux实用Linux

在github上部署静态网页

2018-11-12  本文已影响3人  黄一倚

在github上部署静态网页其实用的是github pages。至于这个是什么东西可以自行百度。也可以看官方文档
github pages其实也是一个仓库,所以首先我们要去github上新建一个仓库。并且初始化readme文件。


保存之后就可以看到你的仓库可以通过刚才的仓库名称进行访问了。
但是还没有readme文件。

huanyu@ubuntu:~/Documents/github.pages$ git init
Initialized empty Git repository in /home/huanyu/Documents/github.pages/.git/
huanyu@ubuntu:~/Documents/github.pages$ git clone git@github.com:HarryHq/HarryHq.github.io.git
Cloning into 'HarryHq.github.io'...
remote: Enumerating objects: 10, done.
remote: Counting objects: 100% (10/10), done.
remote: Compressing objects: 100% (8/8), done.
remote: Total 10 (delta 2), reused 0 (delta 0), pack-reused 0
Receiving objects: 100% (10/10), 14.20 KiB | 14.00 KiB/s, done.
Resolving deltas: 100% (2/2), done.
huanyu@ubuntu:~/Documents/github.pages/HarryHq.github.io$ git add .
huanyu@ubuntu:~/Documents/github.pages/HarryHq.github.io$ git commit -m "love page"
[master 26523f9] love page
 11 files changed, 3604 insertions(+), 1 deletion(-)
 create mode 100755 file/default.css
 create mode 100755 file/functions.js
 create mode 100755 file/jquery.min.js
 create mode 100755 file/jscex-async-powerpack.min.js
 create mode 100755 file/jscex-async.min.js
 create mode 100755 file/jscex-builderbase.min.js
 create mode 100755 file/jscex-jit.js
 create mode 100755 file/jscex-parser.js
 create mode 100755 file/jscex.min.js
 create mode 100755 file/love.js
 rewrite index.html (100%)
 mode change 100644 => 100755
huanyu@ubuntu:~/Documents/github.pages/HarryHq.github.io$ git push -u origin master
Counting objects: 14, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (14/14), done.
Writing objects: 100% (14/14), 63.43 KiB | 5.29 MiB/s, done.
Total 14 (delta 1), reused 0 (delta 0)
remote: Resolving deltas: 100% (1/1), completed with 1 local object.
To github.com:HarryHq/HarryHq.github.io.git
   b8f46bb..26523f9  master -> master
Branch 'master' set up to track remote branch 'master' from 'origin'.

表面页面的实现

参考教程

上一篇下一篇

猜你喜欢

热点阅读