Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/little-buddy/hexo
Hexo demo.
https://github.com/little-buddy/hexo
Last synced: about 1 month ago
JSON representation
Hexo demo.
- Host: GitHub
- URL: https://github.com/little-buddy/hexo
- Owner: little-buddy
- Created: 2020-08-28T07:54:47.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2020-08-31T02:26:25.000Z (over 4 years ago)
- Last Synced: 2024-10-29T20:11:26.309Z (3 months ago)
- Size: 20.5 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# Little Buddy Hexo [![Netlify Status](https://api.netlify.com/api/v1/badges/07bf91b1-1d21-42d4-89ea-0a1ef5326223/deploy-status)](https://app.netlify.com/sites/obuddy/deploys)
```
git clone https://github.com/little-buddy/hexo.git
git submodule init && git submodule update# 下面这一句效果和上面三条命令的效果是一样的,多加了个参数 "--recursive"
git clone https://github.com/little-buddy/hexo.git --recursive
```## Netlify
```
Netlify's deployment infrastructure(基础设施) knows how to avoid uploading the same file twice,
even between different deploys, so we get your changes ready without duplicating content.We've built Netlify's core around [Merkle trees], the same structures used in Git, ZFS file systems,
and blockchain technology.A Merkle tree is a structure where each node is labeled with the cryptographic
hash of the labels of all the nodes under it.When we finish processing new deploys, we only swap the tree to serve.
Having immutable trees also prevents us from showing mixed content.Another interesting advantage of immutable deploys is that we can point any name you want to any content you want.
This is the base for what we call Deploy Previews and Branch Deploys.Can this be cached, and if so by whom?
cache-control - private / public
How long can it be cached for
cache-control - max-age
How can I tell if it's been changed?
etag通过设置 max-age=0 来使每次请求都不被缓存
然后通过 etag a version hash来让服务器判断 hash是否变更而决定是否返回304来让浏览器读取本地缓存you can override these caching settings with our custom headers feature
```#### Definitions
```
- Production branch
yoursitename.netlify.app
- Production deploy
enabled, each new production deploy will update what is published at your site's main URL.
- Branch deploy
a deploy generated from a branch that is not your production branch.
deploy-url branchName--yoursitename.netlify.app
- deploy preview
a deploy generated from a pull request or merge requests
deploy-url deploy-preview-prNumber--yoursitename.netlify.app
```### Deploy contexts
```
production
deploy-preview
branch-deploy
```### File-based configuration
```
base = ""
publish = ""
comman = ""
```### Netlify configuration variables
```
NODE_VERSION
NODE_ENV
NPM_VERSION
NPM_FLAGS
NPM_TOKEN -> fetching private npm modulesYARN_VERSION -> Yarn version
YARN_FLAGRUBY_VERSION
PHP_VERSION
HUGO_VERSION
GO_VERSION
GO_IMPORT_PATH
AWS_LAMBDA_JS_RUNTIME
CI
GIT_LFS_ENABLED
GIT_LFS_FETCH_INCLUDE预定义只读变量
NETFLIY
BUILD_ID
CONTEXT
_system_arch
_system_versionREPOSITORY_URL
BRANCH
HEAD
COMMIT_REF
CACHED_COMMIT_REF
PULL_REQUEST
REVIEW_IDURL
DEPLOY_URL
DEPLOY_PRIME_URL
DEPLOY_ID
SITE_NAME
SITE_ID
NETLIFY_IMAGES_CDN_DOMAIN -> 构建过程中打开压缩才有效INCOMING_HOOK_TITLE
INCOMING_HOOK_URL
INCOMING_HOOK_BODY
```