A GitHub Action for comparing compiled assets between branches.
Required Path to file or directory for file sizes analysis.
Optional Path to another directory against which to perform file comparisons.
Optional GitHub token for accessing the GitHub API. Defaults to ${{ github.token }}
.
Optional Glob pattern for selecting files to compare. Defaults to dist/*
.
Optional If true, add a comment on the pull request with the results of the comparison. Defaults to true
.
Optional Header content for the comment. Markdown is supported. Defaults to ## File metrics
.
True if the overall file size has changed, false otherwise.
Total size of all files for this branch in bytes.
name: Compare compiled output file size
uses: "spectrum-tools/gh-action-file-diff"
with:
head-path: ${{ github.workspace }}/pull-request
base-path: ${{ github.workspace }}/base-branch
file-glob-pattern: |
components/*/dist/*.{css,json}
components/*/dist/themes/*.css