[Bug]: GitHub Integration does not obey .gitignore
Please confirm that you have:
- [X] Searched existing issues to see if your issue is a duplicate. (If you’ve found a duplicate issue, feel free to add additional information in a comment on it.)
- [X] Reproduced the issue in the latest CLI version.
In which of these areas are you experiencing a problem?
Theme
Expected behavior
The GitHub integration does not obey .gitignore files. This has the side effect of files that should not be in the git repo being committed by Shopify. Examples of this type of file are built assets. The expected behaviour is that any file in a repo's .gitignore file should not be forced back into the repo if it exists in the theme (and not in the repo).
There are numerous community posts reporting the same issue: https://community.shopify.com/c/technical-q-a/github-integration-doesn-t-support-the-gitignore-file/m-p/1253056 https://community.shopify.com/c/technical-q-a/github-integration-ignores-shopifyignore/td-p/2407792 Not sure if this is the right place to report this, but I don't see an alternative, so hopefully it ends up with the right team.
Actual behavior
Shopify GitHub integration forces ignored files to be tracked.
Verbose output
n/a
Reproduction steps
- Create a .gitignore file and add some entries to it
- Hook up your branch to Shopify via GitHub integration
- Deploy an (or create) an ignored file to the connected theme
- Watch the integration force the file to be tracked in git
Operating System
Mac OS Ventura
Shopify CLI version (check your project's package.json if you're not sure)
3.50.0
Shell
zsh
Node version (run node -v if you're not sure)
v18.16.0
What language and version are you using in your application?
No response
This issue seems inactive. If it's still relevant, please add a comment saying so. Otherwise, take no action. → If there's no activity within a week, then a bot will automatically close this. Thanks for helping to improve Shopify's dev tooling and experience.
P.S. You can learn more about why we stale issues here.
@gonzaloriestra This is still an issue, hoping there may be a resolution for it in the future!
Hi @nboliver-ventureweb! Thank you for reporting this issue. However, the fix for this problem can't be addressed through the Shopify CLI.
The best and most effective way to resolve this issue is by contacting Shopify support, as they can engage the team involved with GitHub integration to handle this.
Thanks again for reporting!