Closed
Description
Describe the bug
After cloning OpenSearch, git shows random files (mostly binaries) as diffs, even though its a freshly checked out repository.
saratvemulapalli~> % git clone https://github.com/opensearch-project/OpenSearch.git opensearch-main
Cloning into 'opensearch-main'...
remote: Enumerating objects: 1374824, done.
remote: Counting objects: 100% (13283/13283), done.
remote: Compressing objects: 100% (6682/6682), done.
remote: Total 1374824 (delta 5264), reused 11345 (delta 4721), pack-reused 1361541
Receiving objects: 100% (1374824/1374824), 501.67 MiB | 5.27 MiB/s, done.
Resolving deltas: 100% (772438/772438), done.
Updating files: 100% (10061/10061), done.
saratvemulapalli~> % cd opensearch-main
saratvemulapalli~> opensearch-main % ls
ADMINS.md NOTICE.txt benchmarks doc-tools licenses sandbox
CODE_OF_CONDUCT.md README.md build.gradle gradle modules server
CONTRIBUTING.md RELEASING.md buildSrc gradle.properties plugins settings.gradle
DEVELOPER_GUIDE.md SECURITY.md client gradlew qa test
LICENSE.txt TESTING.md dev-tools gradlew.bat release-notes whitesource.config
MAINTAINERS.md Vagrantfile distribution libs rest-api-spec
saratvemulapalli~> opensearch-main % git status
On branch main
Your branch is up to date with 'origin/main'.
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
modified: server/src/test/resources/indices/bwc/unsupported-2.4.5.zip
I haven't dug deeper but very likely its because of .gitattributes
.
I see this happening on multiple platforms.
Coming from #1696 (comment)
To Reproduce
Steps to reproduce the behavior:
- Clone OpenSearch from https://github.com/opensearch-project/OpenSearch.git
- Run
git status
Expected behavior
No changes in files in different environments.
Host/Environment:
- OS: MacOS BigSur (x64), Linux (x64)