Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deploying the source files via `hexo-git-deployer` #4128

cmp0xff opened this issue Feb 14, 2020 · 0 comments

Deploying the source files via `hexo-git-deployer` #4128

cmp0xff opened this issue Feb 14, 2020 · 0 comments


Copy link

@cmp0xff cmp0xff commented Feb 14, 2020

Check List

Please check followings before submitting a new issue.

  • I have already read Docs page & Troubleshooting page
  • I have already searched existing issues and they are not help to me
  • I examined error or warning messages and it's difficult to solve
  • Using the latest version of Hexo (run hexo version to check)
  • Node.js is higher than 8.6.0


I would like to deploy the source files to an additional src branch so that I can maintain my website on different machines. I was basically following this answer on Stackoverflow. However, I got problem with permissions of a specific file. Only if I run $ hexo deploy with root privilege can I deploy the source successfully.

I cannot write a comment on Stackoverflow because I do not have sufficient reputation there. Also the person who wrote the answer seems not to be active since months ago.

Environment & Settings

Node.js & npm version


Your site _config.yml (Optional)

  - type: git
    branch: master
  - type: git
    branch: src
    extend_dirs: /
    ignore_hidden: false
        public: .

Your theme _config.yml (Optional)

Hexo and Plugin version(npm ls --depth 0)

hexo-site@0.0.0 <local repo path>/<username>/<username>
├── hexo@4.2.0
├── hexo-deployer-git@2.1.0
├── hexo-generator-archive@1.0.0
├── hexo-generator-category@1.0.0
├── hexo-generator-index@1.0.0
├── hexo-generator-tag@1.0.0
├── hexo-renderer-ejs@1.0.0
├── hexo-renderer-marked@2.0.0
├── hexo-renderer-stylus@1.1.0
└── hexo-server@1.0.0

Your package.json package.json

  "name": "hexo-site",
  "version": "0.0.0",
  "private": true,
  "scripts": {
    "build": "hexo generate",
    "clean": "hexo clean",
    "deploy": "hexo deploy",
    "server": "hexo server"
  "hexo": {
    "version": "4.2.0"
  "dependencies": {
    "hexo": "^4.0.0",
    "hexo-deployer-git": "^2.1.0",
    "hexo-generator-archive": "^1.0.0",
    "hexo-generator-category": "^1.0.0",
    "hexo-generator-index": "^1.0.0",
    "hexo-generator-tag": "^1.0.0",
    "hexo-renderer-ejs": "^1.0.0",
    "hexo-renderer-marked": "^2.0.0",
    "hexo-renderer-stylus": "^1.1.0",
    "hexo-server": "^1.0.0"


If I run $ hexo deploy without root privilege, the error message reads

FATAL Something's wrong. Maybe you can find the solution here:
Error: EACCES: permission denied, copyfile '<local repo path>/<username>/<username>' -> '<local repo path>/<username>/<username>'
@SukkaW SukkaW added the question label Feb 14, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.