Skip to content

Add a gitattributes file with export-ignore to be used for generating excludes in the release script #1453

@kbendick

Description

@kbendick

After some back and forth between myself and @rdblue on this PR for improving the release script to detect the archive list automatically, #1227, we've come up with some working solutons.

However, in my opinion, the working solutions that I've offered are potentially a little too cute (read: hacky).

Having looked into it further, the proper way to exclude certain files from a git archive is to use the .gitattributes file and then mark the given files to be excluded from a release as export-ignore.

Since I don't have the ability to push to that branch, I'm going to add a .gitattributes file which has the excludes in it. This should simplify the several lines of shell scripts (with many pipes) into one simple git archive command that simply archives based off of a tag. That tag is already generated, pushed to github, and available for reference in the release script.

This way of doing it should make the release script much more maintainable, while also making the release process much more standardized for release engineers who are likely aware of concepts like those found in `.gitattributes.

I will open a PR as a POC for the appropriate .gitattributes file.

See this documentation for further information on the gitattributes file, specifically this section as it relates to generating releases: https://git-scm.com/docs/gitattributes#_creating_an_archive

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions