Skip to content

Selecting specific files to archive requires additional steps #28

Open
@cyberf1y

Description

@cyberf1y

I want to archive a specific subset of the files in my repository.
Currenty, I must use the following steps, to achieve this:

steps:
  - name: Create a site directory
    run: |
      shopt -s globstar &&
      tar -cvf site.tar **/*.html &&
      mkdir site &&
      tar -xf site.tar --directory site
      
  - name: Upload artifact
    uses: actions/upload-pages-artifact@v1
    with:
      path: 'site'

This, apart from being error-prone, is not efficient, because of the unnecessary calls to tar.

I think, that this could be achieved with the following:

steps:
  - name: Upload artifact
    uses: actions/upload-pages-artifact@v1
    with:
     path: '**/*.html'

with very little changes to action.yml.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestinclusion/exclusionRelated to file inclusion/exclusion and symlinks

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions