Bug 551679 - Executable flag vanishes when using staging views diff view
Summary: Executable flag vanishes when using staging views diff view
Status: RESOLVED FIXED
Alias: None
Product: EGit
Classification: Technology
Component: Core (show other bugs)
Version: 5.5   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: 5.6   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-10-01 11:14 EDT by Marcel Sauer CLA
Modified: 2019-10-04 04:46 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Marcel Sauer CLA 2019-10-01 11:14:05 EDT
Staging partial changes to an executable script removes executable flag.

Reproduced by:
  1) Having a executable script in a git repository inside an eclipse project
  2) Do multiple changes to the script
  3) Double click file in staging view
  4) Add one change and save

Result:
# git diff --staged
diff --git a/test.sh b/test.sh
old mode 100755
new mode 100644
index e5224d5..07e1aa0
--- a/test.sh
+++ b/test.sh
@@ -1 +1,2 @@
 foo
+bar

Expected:
No mode change.

Version:
Build id: 20190917-1200
EGit  5.5.0.201909110433-r
Comment 1 Eclipse Genie CLA 2019-10-01 16:35:49 EDT
New Gerrit change created: https://git.eclipse.org/r/150457
Comment 2 Andrey Loskutov CLA 2019-10-01 16:37:42 EDT
Is this a regression in 5.5?
Comment 3 Marcel Sauer CLA 2019-10-02 04:12:55 EDT
I also observed this behavior in:
eclipse 20190314-1200
EGit 5.3.0.201903130848-r
Comment 4 Thomas Wolf CLA 2019-10-02 08:40:23 EDT
(In reply to Andrey Loskutov from comment #2)
> Is this a regression in 5.5?

No. Previous code was there since 2013.
Comment 5 Andrey Loskutov CLA 2019-10-02 08:44:45 EDT
(In reply to Thomas Wolf from comment #4)
> (In reply to Andrey Loskutov from comment #2)
> > Is this a regression in 5.5?
> 
> No. Previous code was there since 2013.

Thanks, good to know.
Comment 6 Eclipse Genie CLA 2019-10-04 04:26:05 EDT
Gerrit change https://git.eclipse.org/r/150457 was merged to [master].
Commit: http://git.eclipse.org/c/egit/egit.git/commit/?id=a5cd7803c4fb1f38e682fb8133f8c28605d0e9d8