helaili / jekyll-action

A GitHub Action to publish Jekyll based content as a GitHub Pages site
MIT License
250 stars 120 forks source link

Breaking change to the `bundle build` command, output folder path changed and can't access #127

Closed Ligengxin96 closed 2 years ago

Ligengxin96 commented 2 years ago

This is git action output on Jan 14 2022.

picture 1

picture 1

And this is git action output on Mar 2 2022.

picture 2

picture 2

We can see (line 56 in picture 1 and line 57 in picture 2), the build command output folder path changed from /github/workspace/build to /github/jekyll_build

And I check the git action output info, the docker mount folders are -v "/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/_temp/_runner_file_commands":"/github/file_commands" -v "/home/runner/work/BlogSrc/BlogSrc":"/github/workspace"

So, we can access /github/workspace/build because the /github/workspace folder has been mounted. But /github folder not. So we can't access the /github/jekyll_build folder. But we expect to access the output folder.

Ligengxin96 commented 2 years ago

Ok, I read the doc. And I found the solution to change the output folder. Add jekyll_build_options param.

    # Standard usage
    - uses: helaili/jekyll-action@v2
      with:
        token: ${{ secrets.JEKYLL_PAT }}
        jekyll_build_options: "--destination ./build"

Then the output folder will become /github/workspace/build

remil1000 commented 2 years ago

nice catch @Ligengxin96

maybe the version could be bumped to v3 as this is quite a breaking change

helaili commented 2 years ago

As per https://github.com/helaili/jekyll-action/pull/138 it is now possible to set the build folder.