actions-gh-pages icon indicating copy to clipboard operation
actions-gh-pages copied to clipboard

proposal: Include files not directory

Open apis3445 opened this issue 3 years ago • 1 comments

Checklist

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

Describe your proposal

I want to deploy to github pages but only the .html pages. I only saw optins to exclude but not to include.

Describe the solution you'd like

pulish_dir: path/*.html

Describe alternatives you've considered

I consider exclude but I have a lot of files to exclude

Additional context

No response

apis3445 avatar Mar 27 '22 02:03 apis3445

I like using Coreutils for that case.

- name: Prepare public
  run: |
    mkdir ./public
    find ./your_path -name "*.html" -exec cp {} ./public \;
- name: Deploy
  uses: peaceiris/actions-gh-pages@v3
  with:
    github_token: ${{ secrets.GITHUB_TOKEN }}
    publish_dir: ./public

I think that there is no advantage to this type of feature more than using Coreutils. So we have no plan to add such an option.

peaceiris avatar Mar 27 '22 03:03 peaceiris