<!--more-->前端
Just Do It!!!git
网址 https://github.com/login 点击直接注册github
注册好了以后打开页面 点击右上角的 + 号,选择 News repositorynpm
回到首页,选择右下角的 Your repositories 下面 以您的用户名开头的连接打开。 vim
OK👌 在用户界面上选择 Settings ,选择 **SSH and GPG keys ** 缓存
先别急着输入 key ,,等到后面解决
ssh-keygen
,3个回车,跳出一长串代码,这时候输入 vim ~/.ssh/id_rsa.pub
,此时复制 ssh开头到local 的全部字符串,复制好了以后,填入 上面的 key 里面。 Add SSH key!:q
很完美!bash
git config -global user.name “Your Name”
,服务器
git config -global user.email “email@example.com”
,网络
e.g git config -global user.name “CracKerMe” git config -global user.email “1160948478@qq.com”
本地配置结束!!!hexo
git clone "git@github.com:XXXXXXXXXX"
注意哟,xxxxxxxx是那一长串字符
xxxxx是SSH下的 " git@github.com: " 开头的一串内容
当您的下载的文件有修改后想从新传回git 服务器端, 输入如下命令,检查 本地与服务器的差别
git status
git add .
git commit -m 'i upload something new'
git remote add origin git@github.com:yourname/learngit.git
git push -u origin master
一次文件的下载、上传完成
npm install hexo-deployer-git —save
hexo g
then
hexo d
---没了么?
---是的。
---真没了?
---真没了!
hexo g
then
hexo d