]> git.ipfire.org Git - thirdparty/git.git/commitdiff
Merge branch 'tg/add-chmod+x-fix'
authorJunio C Hamano <gitster@pobox.com>
Mon, 26 Sep 2016 23:09:20 +0000 (16:09 -0700)
committerJunio C Hamano <gitster@pobox.com>
Mon, 26 Sep 2016 23:09:20 +0000 (16:09 -0700)
"git add --chmod=+x <pathspec>" added recently only toggled the
executable bit for paths that are either new or modified. This has
been corrected to flip the executable bit for all paths that match
the given pathspec.

* tg/add-chmod+x-fix:
  t3700-add: do not check working tree file mode without POSIXPERM
  t3700-add: create subdirectory gently
  add: modify already added files when --chmod is given
  read-cache: introduce chmod_index_entry
  update-index: add test for chmod flags

1  2 
builtin/checkout.c
builtin/commit.c
builtin/update-index.c
cache.h
read-cache.c

Simple merge
Simple merge
Simple merge
diff --cc cache.h
Simple merge
diff --cc read-cache.c
index 31eddec5f751b2c8d8abda0698869bca133b606a,c2b2e970bc0388b8984fbb7883fedb6c94faeb27..38d67faf708d7b88f208f10dad23f893dd16f587
@@@ -624,10 -627,10 +624,10 @@@ void set_object_name_for_intent_to_add_
        unsigned char sha1[20];
        if (write_sha1_file("", 0, blob_type, sha1))
                die("cannot create an empty blob in the object database");
 -      hashcpy(ce->sha1, sha1);
 +      hashcpy(ce->oid.hash, sha1);
  }
  
- int add_to_index(struct index_state *istate, const char *path, struct stat *st, int flags, int force_mode)
+ int add_to_index(struct index_state *istate, const char *path, struct stat *st, int flags)
  {
        int size, namelen, was_same;
        mode_t st_mode = st->st_mode;