Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
hexo-deployer-git
Advanced tools
Git deployer plugin for Hexo.
Update Git for Windows to the latest version. (Details)
$ npm install hexo-deployer-git --save
You can configure this plugin in _config.yml
.
# You can use this:
deploy:
type: git
repo: <repository url>
branch: [branch]
token: ''
message: [message]
name: [git user]
email: [git email]
extend_dirs: [extend directory]
ignore_hidden: false # default is true
ignore_pattern: regexp # whatever file that matches the regexp will be ignored when deploying
# or this:
deploy:
type: git
message: [message]
repo: <repository url>[,branch]
extend_dirs:
- [extend directory]
- [another extend directory]
ignore_hidden:
public: false
[extend directory]: true
[another extend directory]: false
ignore_pattern:
[folder]: regexp # or you could specify the ignore_pattern under a certain directory
# Multiple repositories
deploy:
repo:
# Either syntax is supported
[repo_name]: <repository url>[,branch]
[repo_name]:
url: <repository url>
branch: [branch]
gh-pages
on GitHub.coding-pages
on Coding.net.master
.$
to read token from environment variable (recommended). Repo must be a http(s) url. More details.deploy:
repo:
# Either syntax is supported
github: https://github.com/user/project.git,branch
gitee:
url: https://gitee.com/user/project.git
branch: branch_name
repo:
takes priority.Site updated: {{ now("yyyy-MM-dd HH:mm:ss") }}
.demo
, examples
.nojekyll
in root.
public
: the public dir defaults.# _config.yaml
deploy:
- type: git
repo: git@github.com:<username>/<username>.github.io.git
branch: master
- type: git
repo: git@github.com:<username>/<username>.github.io.git
branch: src
extend_dirs: /
ignore_hidden: false
ignore_pattern:
public: .
While this plugin can parse authentication token from the config, only use this method if you are sure the config will not be committed, including to a private repo. A more secure approach is to add it to the CI as an environment variable, then simply add the name of the environment variable to this plugin's config (e.g. $GITHUB_TOKEN
).
Additional guides:
hexo-deployer-git
works by generating the site in .deploy_git
and force pushing to the repo(es) in config.
If .deploy_git
does not exist, a repo will initialized (git init
).
Otherwise the curent repo (with its commit history) will be used.
Users can clone the deployed repo to .deploy_git
to keep the commit history.
git clone <gh-pages repo> .deploy_git
Remove .deploy_git
folder.
$ rm -rf .deploy_git
MIT
FAQs
Git deployer plugin of Hexo.
The npm package hexo-deployer-git receives a total of 8,761 weekly downloads. As such, hexo-deployer-git popularity was classified as popular.
We found that hexo-deployer-git demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 8 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.