Notes
1.0.0
1.0.0
  • Introduction
  • Commands
    • cd
    • df
    • du
    • fc-cahe
    • ifconfig
    • ip
    • ls
    • lsb_release
    • mkdir
    • mksquashfs
    • mount
    • ping
    • pwd
    • rm
    • sar
    • sudo
  • Linux C
    • Preprocessor
    • Keywords
    • Kernel
      • Ftrace
      • Watchdog
  • Python
    • general
      • Decorator
      • Generator
      • Iterator
      • Lambda
    • Download
    • NIC
  • Network
    • Protocol
      • Link layer
      • IP
      • ARP
      • ICMP
    • Proxy
      • Cntlm
      • Proxychains4
      • ShadowSocks
    • Tools
      • iperf
      • tc
      • Wireshark
    • Apps
      • samba
      • tftp
  • Software
    • Atom
    • Chrome
    • Docker
    • Git
    • Gitbook
    • Hexo
    • Nodejs
    • Teraterm
    • Tex
    • Tmux
    • VIM
    • VSCode
  • Database
    • MongoDB
  • Web
    • CSS
    • LNMP
  • Tools
    • common
    • programming
  • Ubuntu
    • Add user
    • AWS EC2
    • FAQ
    • Installer
    • Shell
    • Shell scripts
    • Themes
    • VPS
  • Windows
    • PowerShell
    • CMD
    • FAQ
  • Aphorisms
  • Book List
  • Favorites
  • Appendix
    • ASCII
    • GSM
Powered by GitBook
On this page
  • 更新gitbook电子书
  • 更新个人博客

Was this helpful?

  1. Ubuntu

Shell scripts

更新gitbook电子书

push.sh

#!/bin/zsh

git add .
git commit -m "update notes"
git push

# notes: exec cmd "chmod u+x push.sh" before "./push.sh"

当更新完Notes后,执行./push.sh可以自动完成代码提交和上传的操作,执行结束后,远程github仓库文件将会更新,与github绑定的gitbook自动获取更新内容,进而更新电子书所在站点的内容。

更新个人博客

push.sh

#!/bin/zsh

# push all the changed files and untracked files of blog
git add .
git commit -m "update blog files"
git push

# generate website files and deploy it to www.litreily.top
hexo clean
hexo g -d

执行./push.sh可以自动完成博客网站的更新。

PreviousShellNextThemes

Last updated 5 years ago

Was this helpful?