opt `--no-jekyll` should place `.nojekyll` under `--prefix` directory
achekery opened this issue · 3 comments
achekery commented
Summary
We would expect opt --no-jekyll
should place .nojekyll
in gh-pages
branch under --prefix
directory. However, it instead places the file at the root directory. GitHub Pages deployment seems to ignore the .nojekyll
file unless it is exactly at the web serving directory (i.e. /docs
in my case)
Related source code section:
Lines 157 to 160 in 5bf63c4
Commands:
$ ghp-import --version
2.0.2
$ ghp-import \
--no-jekyll \
--push \
--prefix=docs \
--force \
--no-history \
${BOOK_DIR}/_build/html
$ git checkout gh-pages ; git pull ; cd $(git rev-parse --show-toplevel); find . -name .nojekyll
./.nojekyll
achekery commented
Current workaround for user
# https://github.com/c-w/ghp-import/issues/106
# move .nojekyll under --prefix directory in gh-pages branch
cd $(git rev-parse --show-toplevel) \
&& git add -A && git stash push \
&& git checkout gh-pages && git pull \
&& git mv ./.nojekyll ./docs/.nojekyll \
&& git commit -m "move .nojekyll file into place" && git push \
&& git checkout - && git stash pop
c-w commented
Good catch! Should be a fairly straight forward fix. Would you mind
submitting a pull request?
…On Tue, Mar 22, 2022 at 8:33 PM achekerylla ***@***.***> wrote:
Current workaround for user
# #106
# move .nojekyll under --prefix directory in gh-pages branch
cd $(git rev-parse --show-toplevel) \
&& git add -A && git stash push \
&& git checkout gh-pages && git pull \
&& git mv ./.nojekyll ./docs/.nojekyll \
&& git commit -m "move .nojekyll file into place" && git push \
&& git checkout - && git stash pop
—
Reply to this email directly, view it on GitHub
<#106 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAIJHVPV32X7V6QYHX7XHLLVBJRHHANCNFSM5RMN6XBA>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>