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

.nojekyll file added to publish_branch other than master or gh-pages #660

Closed
3 tasks done
dhimmel opened this issue Oct 8, 2021 · 4 comments · Fixed by #661
Closed
3 tasks done

.nojekyll file added to publish_branch other than master or gh-pages #660

dhimmel opened this issue Oct 8, 2021 · 4 comments · Fixed by #661
Assignees
Labels
support User support

Comments

@dhimmel
Copy link
Contributor

dhimmel commented Oct 8, 2021

Checklist

  • I am using the latest version of this action.
  • I have read the latest README and followed the instructions.
  • I have read the latest GitHub Actions official documentation and learned the basic spec and concepts.

Describe your question

From the README

By default, this action signals to GitHub Pages that the site shall not be processed with Jekyll. This is done by adding an empty .nojekyll file when publishing to the master or gh-pages branch. When a .nojekyll file already exists, this action does nothing.

Using peaceiris/actions-gh-pages@v3 with publish_branch: output-104, I noticed a .nojekyll file was added. So perhaps the documentation doesn't match the behavior? It seems like .nojekyll is added regardless of the branch.

Relevant links

Repo is currently private but here is the deploy step

    - name: Deploy
      if: github.event_name == 'workflow_dispatch'
      uses: peaceiris/actions-gh-pages@v3
      with:
        github_token: ${{ secrets.GITHUB_TOKEN }}
        publish_branch: output-${{ github.event.inputs.release }}
        publish_dir: output/${{ github.event.inputs.release }}

Relevant log output

2021-10-07T21:18:50.4172620Z ##[group]Run peaceiris/actions-gh-pages@v3
2021-10-07T21:18:50.4173764Z with:
2021-10-07T21:18:50.4175633Z   github_token: ***
2021-10-07T21:18:50.4176167Z   publish_branch: output-104
2021-10-07T21:18:50.4176718Z   publish_dir: output/104
2021-10-07T21:18:50.4177972Z   allow_empty_commit: false
2021-10-07T21:18:50.4178408Z   keep_files: false
2021-10-07T21:18:50.4180398Z   force_orphan: false
2021-10-07T21:18:50.4180933Z   enable_jekyll: false
2021-10-07T21:18:50.4181415Z   disable_nojekyll: false
2021-10-07T21:18:50.4182428Z   exclude_assets: .github
2021-10-07T21:18:50.4182906Z env:
2021-10-07T21:18:50.4183523Z   pythonLocation: /opt/hostedtoolcache/Python/3.9.7/x64
2021-10-07T21:18:50.4184334Z   LD_LIBRARY_PATH: /opt/hostedtoolcache/Python/3.9.7/x64/lib
2021-10-07T21:18:50.4184938Z ##[endgroup]
2021-10-07T21:18:50.5211509Z [INFO] Usage https://github.com/peaceiris/actions-gh-pages#readme
2021-10-07T21:18:50.5225177Z ##[group]Dump inputs
2021-10-07T21:18:50.5225804Z [INFO] GithubToken: true
2021-10-07T21:18:50.5226812Z [INFO] PublishBranch: output-104
2021-10-07T21:18:50.5227525Z [INFO] PublishDir: output/104
2021-10-07T21:18:50.5228082Z [INFO] DestinationDir: 
2021-10-07T21:18:50.5228663Z [INFO] ExternalRepository: 
2021-10-07T21:18:50.5236809Z [INFO] AllowEmptyCommit: false
2021-10-07T21:18:50.5238005Z [INFO] KeepFiles: false
2021-10-07T21:18:50.5238551Z [INFO] ForceOrphan: false
2021-10-07T21:18:50.5239046Z [INFO] UserName: 
2021-10-07T21:18:50.5239511Z [INFO] UserEmail: 
2021-10-07T21:18:50.5241965Z [INFO] CommitMessage: 
2021-10-07T21:18:50.5243474Z [INFO] FullCommitMessage: 
2021-10-07T21:18:50.5244021Z [INFO] TagName: 
2021-10-07T21:18:50.5244490Z [INFO] TagMessage: 
2021-10-07T21:18:50.5245107Z [INFO] EnableJekyll (DisableNoJekyll): false
2021-10-07T21:18:50.5245704Z [INFO] CNAME: 
2021-10-07T21:18:50.5246209Z [INFO] ExcludeAssets .github
2021-10-07T21:18:50.5246579Z 
2021-10-07T21:18:50.5247719Z ##[endgroup]
2021-10-07T21:18:50.5249017Z ##[group]Setup auth token
2021-10-07T21:18:50.5249639Z [INFO] setup GITHUB_TOKEN
2021-10-07T21:18:50.5262359Z ##[endgroup]
2021-10-07T21:18:50.5266545Z ##[group]Prepare publishing assets
2021-10-07T21:18:50.5268081Z [INFO] ForceOrphan: false
2021-10-07T21:18:50.5321096Z [command]/usr/bin/git clone --depth=1 --single-branch --branch output-104 ***github.com/related-sciences/ensembl-genes.git /home/runner/actions_github_pages_1633641530525
2021-10-07T21:18:50.5363785Z Cloning into '/home/runner/actions_github_pages_1633641530525'...
2021-10-07T21:18:51.0538012Z warning: Could not find remote branch output-104 to clone.
2021-10-07T21:18:51.0539594Z fatal: Remote branch output-104 not found in upstream origin
2021-10-07T21:18:51.0588633Z [INFO] first deployment, create new branch output-104
2021-10-07T21:18:51.0589533Z [INFO] The process '/usr/bin/git' failed with exit code 128
2021-10-07T21:18:51.0596509Z [INFO] chdir /home/runner/actions_github_pages_1633641530525
2021-10-07T21:18:51.0623336Z [command]/usr/bin/git init
2021-10-07T21:18:51.0659709Z hint: Using 'master' as the name for the initial branch. This default branch name
2021-10-07T21:18:51.0660577Z hint: is subject to change. To configure the initial branch name to use in all
2021-10-07T21:18:51.0661390Z hint: of your new repositories, which will suppress this warning, call:
2021-10-07T21:18:51.0661976Z hint: 
2021-10-07T21:18:51.0662692Z hint: 	git config --global init.defaultBranch <name>
2021-10-07T21:18:51.0663358Z hint: 
2021-10-07T21:18:51.0665488Z hint: Names commonly chosen instead of 'master' are 'main', 'trunk' and
2021-10-07T21:18:51.0666791Z hint: 'development'. The just-created branch can be renamed via this command:
2021-10-07T21:18:51.0667644Z hint: 
2021-10-07T21:18:51.0668232Z hint: 	git branch -m <name>
2021-10-07T21:18:51.0675647Z Initialized empty Git repository in /home/runner/actions_github_pages_1633641530525/.git/
2021-10-07T21:18:51.0702729Z [command]/usr/bin/git checkout --orphan output-104
2021-10-07T21:18:51.0731017Z Switched to a new branch 'output-104'
2021-10-07T21:18:51.0737306Z [INFO] prepare publishing assets
2021-10-07T21:18:51.0739069Z [INFO] copy /home/runner/work/ensembl-genes/ensembl-genes/output/104 to /home/runner/actions_github_pages_1633641530525
2021-10-07T21:18:51.1285695Z cp: no such file or directory: /home/runner/work/ensembl-genes/ensembl-genes/output/104/.*
2021-10-07T21:18:51.1287501Z [INFO] delete excluded assets
2021-10-07T21:18:51.1328504Z rm: no paths given
2021-10-07T21:18:51.1330802Z [INFO] Created /home/runner/actions_github_pages_1633641530525/.nojekyll
2021-10-07T21:18:51.1332176Z ##[endgroup]

Additional context.

None

@dhimmel dhimmel added the support User support label Oct 8, 2021
@dhimmel
Copy link
Contributor Author

dhimmel commented Oct 8, 2021

The workaround would be for me to set disable_nojekyll: true or enable_jekyll: true.

dhimmel added a commit to related-sciences/ensembl-genes that referenced this issue Oct 8, 2021
@peaceiris
Copy link
Owner

Nice catch! The current README has the old description on the enable_jekyll section. I will update that. Thanks!

See also #438.

@peaceiris
Copy link
Owner

disable_nojekyll will be deprecated in v4, please use enable_jekyll.

@peaceiris
Copy link
Owner

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
support User support
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants