summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Documentation/CodingGuidelines42
-rw-r--r--Documentation/Makefile2
-rw-r--r--Documentation/RelNotes/1.8.5.6.txt34
-rw-r--r--Documentation/RelNotes/1.9.5.txt34
-rw-r--r--Documentation/RelNotes/2.0.5.txt34
-rw-r--r--Documentation/RelNotes/2.1.4.txt34
-rw-r--r--Documentation/RelNotes/2.2.1.txt34
-rw-r--r--Documentation/RelNotes/2.2.2.txt63
-rw-r--r--Documentation/RelNotes/2.3.0.txt230
-rw-r--r--Documentation/RelNotes/2.3.1.txt52
-rw-r--r--Documentation/SubmittingPatches22
-rw-r--r--Documentation/config.txt71
-rw-r--r--Documentation/diff-format.txt3
-rw-r--r--Documentation/git-add.txt2
-rw-r--r--Documentation/git-am.txt12
-rw-r--r--Documentation/git-check-ignore.txt3
-rw-r--r--Documentation/git-clone.txt11
-rw-r--r--Documentation/git-imap-send.txt27
-rw-r--r--Documentation/git-mailinfo.txt5
-rw-r--r--Documentation/git-p4.txt6
-rw-r--r--Documentation/git-pack-objects.txt7
-rw-r--r--Documentation/git-push.txt25
-rw-r--r--Documentation/git-remote.txt20
-rw-r--r--Documentation/git-rev-list.txt3
-rw-r--r--Documentation/git-send-email.txt28
-rw-r--r--Documentation/git-send-pack.txt7
-rw-r--r--Documentation/git-stripspace.txt1
-rw-r--r--Documentation/git-update-index.txt18
-rw-r--r--Documentation/git.txt26
-rw-r--r--Documentation/githooks.txt30
-rw-r--r--Documentation/gitignore.txt4
-rw-r--r--Documentation/pretty-options.txt10
-rw-r--r--Documentation/rev-list-options.txt23
-rw-r--r--Documentation/technical/api-credentials.txt5
-rw-r--r--Documentation/technical/api-error-handling.txt75
-rw-r--r--Documentation/technical/api-string-list.txt4
-rw-r--r--Documentation/technical/index-format.txt2
-rw-r--r--Documentation/technical/protocol-capabilities.txt13
-rwxr-xr-xGIT-VERSION-GEN2
-rw-r--r--INSTALL15
-rw-r--r--Makefile57
-rw-r--r--[l---------]RelNotes172
-rw-r--r--advice.c2
-rw-r--r--archive.c38
-rw-r--r--attr.c47
-rw-r--r--bisect.c2
-rw-r--r--builtin/add.c4
-rw-r--r--builtin/apply.c50
-rw-r--r--builtin/blame.c21
-rw-r--r--builtin/branch.c21
-rw-r--r--builtin/cat-file.c10
-rw-r--r--builtin/check-attr.c4
-rw-r--r--builtin/check-ignore.c4
-rw-r--r--builtin/check-mailmap.c2
-rw-r--r--builtin/check-ref-format.c2
-rw-r--r--builtin/checkout-index.c18
-rw-r--r--builtin/checkout.c16
-rw-r--r--builtin/clean.c2
-rw-r--r--builtin/clone.c22
-rw-r--r--builtin/column.c2
-rw-r--r--builtin/commit-tree.c4
-rw-r--r--builtin/commit.c94
-rw-r--r--builtin/config.c2
-rw-r--r--builtin/describe.c4
-rw-r--r--builtin/diff-files.c2
-rw-r--r--builtin/diff-index.c2
-rw-r--r--builtin/diff-tree.c2
-rw-r--r--builtin/fetch-pack.c2
-rw-r--r--builtin/fmt-merge-msg.c5
-rw-r--r--builtin/for-each-ref.c15
-rw-r--r--builtin/fsck.c2
-rw-r--r--builtin/gc.c2
-rw-r--r--builtin/grep.c2
-rw-r--r--builtin/hash-object.c2
-rw-r--r--builtin/help.c11
-rw-r--r--builtin/index-pack.c4
-rw-r--r--builtin/init-db.c19
-rw-r--r--builtin/log.c10
-rw-r--r--builtin/ls-files.c2
-rw-r--r--builtin/ls-remote.c2
-rw-r--r--builtin/ls-tree.c20
-rw-r--r--builtin/mailinfo.c22
-rw-r--r--builtin/merge-base.c8
-rw-r--r--builtin/merge-file.c7
-rw-r--r--builtin/merge-index.c2
-rw-r--r--builtin/merge.c31
-rw-r--r--builtin/mv.c2
-rw-r--r--builtin/name-rev.c6
-rw-r--r--builtin/notes.c24
-rw-r--r--builtin/pack-objects.c7
-rw-r--r--builtin/pack-redundant.c2
-rw-r--r--builtin/pack-refs.c2
-rw-r--r--builtin/prune-packed.c2
-rw-r--r--builtin/push.c5
-rw-r--r--builtin/receive-pack.c280
-rw-r--r--builtin/reflog.c259
-rw-r--r--builtin/remote.c77
-rw-r--r--builtin/repack.c4
-rw-r--r--builtin/rerere.c2
-rw-r--r--builtin/rev-parse.c8
-rw-r--r--builtin/revert.c4
-rw-r--r--builtin/rm.c2
-rw-r--r--builtin/send-pack.c6
-rw-r--r--builtin/shortlog.c2
-rw-r--r--builtin/show-branch.c7
-rw-r--r--builtin/show-ref.c2
-rw-r--r--builtin/symbolic-ref.c4
-rw-r--r--builtin/tag.c4
-rw-r--r--builtin/unpack-objects.c2
-rw-r--r--builtin/update-index.c2
-rw-r--r--builtin/update-ref.c20
-rw-r--r--builtin/verify-commit.c2
-rw-r--r--builtin/verify-pack.c2
-rw-r--r--builtin/verify-tag.c2
-rw-r--r--cache.h21
-rwxr-xr-xcheck-builtins.sh2
-rw-r--r--color.c173
-rw-r--r--color.h8
-rw-r--r--commit.c75
-rw-r--r--commit.h11
-rw-r--r--compat/stat.c48
-rw-r--r--config.c23
-rw-r--r--config.mak.uname4
-rw-r--r--configure.ac62
-rw-r--r--connect.c2
-rw-r--r--contrib/completion/git-completion.bash21
-rw-r--r--contrib/completion/git-completion.zsh2
-rw-r--r--contrib/completion/git-prompt.sh36
-rw-r--r--contrib/credential/wincred/git-credential-wincred.c25
-rw-r--r--contrib/diff-highlight/README41
-rwxr-xr-xcontrib/diff-highlight/diff-highlight62
-rw-r--r--contrib/subtree/git-subtree.txt194
-rwxr-xr-xcontrib/workdir/git-new-workdir53
-rw-r--r--credential-store.c2
-rw-r--r--credential.c5
-rw-r--r--credential.h1
-rw-r--r--date.c21
-rw-r--r--diff-lib.c8
-rw-r--r--diffcore-break.c7
-rw-r--r--environment.c10
-rw-r--r--ewah/ewok.h3
-rw-r--r--exec_cmd.c7
-rw-r--r--exec_cmd.h2
-rw-r--r--fsck.c8
-rw-r--r--gettext.h24
-rwxr-xr-xgit-add--interactive.perl6
-rwxr-xr-xgit-am.sh21
-rwxr-xr-xgit-bisect.sh13
-rw-r--r--git-compat-util.h56
-rwxr-xr-xgit-p4.py22
-rw-r--r--git-rebase--interactive.sh21
-rwxr-xr-xgit-remote-testgit.sh8
-rwxr-xr-xgit-send-email.perl108
-rw-r--r--git-sh-setup.sh2
-rwxr-xr-xgit-submodule.sh2
-rwxr-xr-xgit-svn.perl55
-rw-r--r--git.c5
-rw-r--r--grep.c4
-rw-r--r--http-push.c3
-rw-r--r--http.c223
-rw-r--r--http.h2
-rw-r--r--imap-send.c206
-rw-r--r--line-log.c2
-rw-r--r--line-log.h2
-rw-r--r--list-objects.c4
-rw-r--r--lockfile.c14
-rw-r--r--mailmap.c20
-rw-r--r--merge-recursive.c17
-rw-r--r--notes-merge.c2
-rw-r--r--notes-utils.c3
-rw-r--r--notes.c4
-rw-r--r--pack-bitmap.c30
-rw-r--r--pack-bitmap.h1
-rw-r--r--pager.c8
-rw-r--r--path.c33
-rw-r--r--perl/Git/SVN.pm2
-rw-r--r--perl/Git/SVN/Editor.pm38
-rw-r--r--pkt-line.c37
-rw-r--r--po/ca.po3425
-rw-r--r--po/de.po1880
-rw-r--r--po/fr.po1813
-rw-r--r--po/git.pot1771
-rw-r--r--po/sv.po1815
-rw-r--r--po/vi.po2139
-rw-r--r--po/zh_CN.po1902
-rw-r--r--prompt.c21
-rw-r--r--prompt.h1
-rw-r--r--quote.c21
-rw-r--r--quote.h2
-rw-r--r--read-cache.c10
-rw-r--r--refs.c409
-rw-r--r--refs.h85
-rw-r--r--remote-curl.c4
-rw-r--r--remote.c46
-rw-r--r--remote.h4
-rw-r--r--rerere.c16
-rw-r--r--revision.c120
-rw-r--r--revision.h15
-rw-r--r--run-command.c17
-rw-r--r--run-command.h4
-rw-r--r--send-pack.c68
-rw-r--r--send-pack.h3
-rw-r--r--sequencer.c34
-rw-r--r--sequencer.h1
-rw-r--r--server-info.c2
-rw-r--r--sha1_file.c46
-rw-r--r--sha1_name.c4
-rw-r--r--shallow.c4
-rw-r--r--strbuf.c3
-rw-r--r--string-list.c12
-rw-r--r--string-list.h14
-rw-r--r--submodule.c2
-rw-r--r--t/README3
-rwxr-xr-xt/lib-gpg.sh39
-rw-r--r--t/lib-gpg/keyring.gpg142
-rw-r--r--t/lib-gpg/ownertrust4
-rw-r--r--t/lib-gpg/pubring.gpgbin2359 -> 0 bytes
-rw-r--r--t/lib-gpg/random_seedbin600 -> 0 bytes
-rw-r--r--t/lib-gpg/secring.gpgbin3734 -> 0 bytes
-rw-r--r--t/lib-gpg/trustdb.gpgbin1360 -> 0 bytes
-rw-r--r--t/lib-httpd/apache.conf1
-rw-r--r--t/lib-terminal.sh2
-rwxr-xr-xt/t0006-date.sh3
-rwxr-xr-xt/t0027-auto-crlf.sh82
-rwxr-xr-xt/t0030-stripspace.sh6
-rwxr-xr-xt/t0050-filesystem.sh2
-rwxr-xr-xt/t0090-cache-tree.sh2
-rwxr-xr-xt/t0300-credentials.sh9
-rwxr-xr-xt/t1014-read-tree-confusing.sh62
-rwxr-xr-xt/t1050-large.sh12
-rwxr-xr-xt/t1301-shared-repo.sh11
-rwxr-xr-xt/t1307-config-blob.sh9
-rwxr-xr-xt/t1400-update-ref.sh92
-rwxr-xr-xt/t1410-reflog.sh30
-rwxr-xr-xt/t1450-fsck.sh82
-rwxr-xr-xt/t2004-checkout-cache-temp.sh400
-rwxr-xr-xt/t2024-checkout-dwim.sh18
-rwxr-xr-xt/t2107-update-index-basic.sh15
-rwxr-xr-xt/t3102-ls-tree-wildcards.sh22
-rwxr-xr-xt/t3200-branch.sh14
-rwxr-xr-xt/t3301-notes.sh2
-rwxr-xr-xt/t3404-rebase-interactive.sh7
-rwxr-xr-xt/t3507-cherry-pick-conflict.sh42
-rwxr-xr-xt/t3700-add.sh8
-rwxr-xr-xt/t4008-diff-break-rewrite.sh4
-rwxr-xr-xt/t4023-diff-rename-typechange.sh3
-rwxr-xr-xt/t4026-color.sh19
-rwxr-xr-xt/t4122-apply-symlink-inside.sh11
-rwxr-xr-xt/t4138-apply-ws-expansion.sh121
-rwxr-xr-xt/t4150-am.sh23
-rwxr-xr-xt/t4202-log.sh15
-rwxr-xr-xt/t4255-am-submodule.sh72
-rwxr-xr-xt/t5000-tar-tree.sh2
-rwxr-xr-xt/t5100-mailinfo.sh4
-rw-r--r--t/t5100/info0012--message-id5
-rw-r--r--t/t5100/msg0012--message-id8
-rw-r--r--t/t5100/patch0012--message-id30
-rwxr-xr-xt/t5304-prune.sh8
-rwxr-xr-xt/t5400-send-pack.sh16
-rwxr-xr-xt/t5505-remote.sh5
-rwxr-xr-xt/t5516-fetch-push.sh167
-rwxr-xr-xt/t5527-fetch-odd-refs.sh33
-rwxr-xr-xt/t5543-atomic-push.sh194
-rwxr-xr-xt/t5550-http-fetch-dumb.sh60
-rwxr-xr-xt/t5700-clone-reference.sh17
-rwxr-xr-xt/t5801-remote-helpers.sh24
-rwxr-xr-xt/t6023-merge-file.sh3
-rwxr-xr-xt/t6030-bisect-porcelain.sh9
-rwxr-xr-xt/t6300-for-each-ref.sh13
-rwxr-xr-xt/t7004-tag.sh14
-rwxr-xr-xt/t7400-submodule-basic.sh17
-rwxr-xr-xt/t7513-interpret-trailers.sh34
-rwxr-xr-xt/t9001-send-email.sh644
-rwxr-xr-xt/t9148-git-svn-propset.sh95
-rwxr-xr-xt/t9817-git-p4-exclude.sh71
-rwxr-xr-xt/t9903-bash-prompt.sh106
-rw-r--r--t/test-lib.sh101
-rwxr-xr-xtemplates/hooks--pre-push.sample1
-rw-r--r--test-hashmap.c2
-rw-r--r--trace.c6
-rw-r--r--trailer.c32
-rw-r--r--transport-helper.c15
-rw-r--r--transport.c9
-rw-r--r--transport.h1
-rw-r--r--tree.c16
-rw-r--r--tree.h3
-rw-r--r--unpack-trees.c10
-rwxr-xr-xupdate_unicode.sh17
-rw-r--r--upload-pack.c4
-rw-r--r--urlmatch.c6
-rw-r--r--urlmatch.h1
-rw-r--r--utf8.c72
-rw-r--r--utf8.h8
-rw-r--r--walker.c2
-rw-r--r--wt-status.c2
295 files changed, 14066 insertions, 9412 deletions
diff --git a/Documentation/CodingGuidelines b/Documentation/CodingGuidelines
index 894546d..7636199 100644
--- a/Documentation/CodingGuidelines
+++ b/Documentation/CodingGuidelines
@@ -328,9 +328,14 @@ For C programs:
- When you come up with an API, document it.
- - The first #include in C files, except in platform specific
- compat/ implementations, should be git-compat-util.h or another
- header file that includes it, such as cache.h or builtin.h.
+ - The first #include in C files, except in platform specific compat/
+ implementations, must be either "git-compat-util.h", "cache.h" or
+ "builtin.h". You do not have to include more than one of these.
+
+ - A C file must directly include the header files that declare the
+ functions and the types it uses, except for the functions and types
+ that are made available to it by including one of the header files
+ it must include by the previous rule.
- If you are planning a new command, consider writing it in shell
or perl first, so that changes in semantics can be easily
@@ -413,6 +418,29 @@ Error Messages
- Say what the error is first ("cannot open %s", not "%s: cannot open")
+Externally Visible Names
+
+ - For configuration variable names, follow the existing convention:
+
+ . The section name indicates the affected subsystem.
+
+ . The subsection name, if any, indicates which of an unbounded set
+ of things to set the value for.
+
+ . The variable name describes the effect of tweaking this knob.
+
+ The section and variable names that consist of multiple words are
+ formed by concatenating the words without punctuations (e.g. `-`),
+ and are broken using bumpyCaps in documentation as a hint to the
+ reader.
+
+ When choosing the variable namespace, do not use variable name for
+ specifying possibly unbounded set of things, most notably anything
+ an end user can freely come up with (e.g. branch names). Instead,
+ use subsection names or variable values, like the existing variable
+ branch.<name>.description does.
+
+
Writing Documentation:
Most (if not all) of the documentation pages are written in the
@@ -441,6 +469,10 @@ Writing Documentation:
--sort=<key>
--abbrev[=<n>]
+ If a placeholder has multiple words, they are separated by dashes:
+ <new-branch-name>
+ --template=<template-directory>
+
Possibility of multiple occurrences is indicated by three dots:
<file>...
(One or more of <file>.)
@@ -457,12 +489,12 @@ Writing Documentation:
(Zero or more of <patch>. Note that the dots are inside, not
outside the brackets.)
- Multiple alternatives are indicated with vertical bar:
+ Multiple alternatives are indicated with vertical bars:
[-q | --quiet]
[--utf8 | --no-utf8]
Parentheses are used for grouping:
- [(<rev>|<range>)...]
+ [(<rev> | <range>)...]
(Any number of either <rev> or <range>. Parens are needed to make
it clear that "..." pertains to both <rev> and <range>.)
diff --git a/Documentation/Makefile b/Documentation/Makefile
index 2f6b6aa..3e39e28 100644
--- a/Documentation/Makefile
+++ b/Documentation/Makefile
@@ -103,7 +103,7 @@ ASCIIDOC_HTML = xhtml11
ASCIIDOC_DOCBOOK = docbook
ASCIIDOC_CONF = -f asciidoc.conf
ASCIIDOC_COMMON = $(ASCIIDOC) $(ASCIIDOC_EXTRA) $(ASCIIDOC_CONF) \
- -agit-version=$(GIT_VERSION)
+ -agit_version=$(GIT_VERSION)
TXT_TO_HTML = $(ASCIIDOC_COMMON) -b $(ASCIIDOC_HTML)
TXT_TO_XML = $(ASCIIDOC_COMMON) -b $(ASCIIDOC_DOCBOOK)
MANPAGE_XSL = manpage-normal.xsl
diff --git a/Documentation/RelNotes/1.8.5.6.txt b/Documentation/RelNotes/1.8.5.6.txt
new file mode 100644
index 0000000..92ff92b
--- /dev/null
+++ b/Documentation/RelNotes/1.8.5.6.txt
@@ -0,0 +1,34 @@
+Git v1.8.5.6 Release Notes
+==========================
+
+Fixes since v1.8.5.5
+--------------------
+
+ * We used to allow committing a path ".Git/config" with Git that is
+ running on a case sensitive filesystem, but an attempt to check out
+ such a path with Git that runs on a case insensitive filesystem
+ would have clobbered ".git/config", which is definitely not what
+ the user would have expected. Git now prevents you from tracking
+ a path with ".Git" (in any case combination) as a path component.
+
+ * On Windows, certain path components that are different from ".git"
+ are mapped to ".git", e.g. "git~1/config" is treated as if it were
+ ".git/config". HFS+ has a similar issue, where certain unicode
+ codepoints are ignored, e.g. ".g\u200cit/config" is treated as if
+ it were ".git/config". Pathnames with these potential issues are
+ rejected on the affected systems. Git on systems that are not
+ affected by this issue (e.g. Linux) can also be configured to
+ reject them to ensure cross platform interoperability of the hosted
+ projects.
+
+ * "git fsck" notices a tree object that records such a path that can
+ be confused with ".git", and with receive.fsckObjects configuration
+ set to true, an attempt to "git push" such a tree object will be
+ rejected. Such a path may not be a problem on a well behaving
+ filesystem but in order to protect those on HFS+ and on case
+ insensitive filesystems, this check is enabled on all platforms.
+
+A big "thanks!" for bringing this issue to us goes to our friends in
+the Mercurial land, namely, Matt Mackall and Augie Fackler.
+
+Also contains typofixes, documentation updates and trivial code clean-ups.
diff --git a/Documentation/RelNotes/1.9.5.txt b/Documentation/RelNotes/1.9.5.txt
new file mode 100644
index 0000000..8d6ac0c
--- /dev/null
+++ b/Documentation/RelNotes/1.9.5.txt
@@ -0,0 +1,34 @@
+Git v1.9.5 Release Notes
+========================
+
+Fixes since v1.9.4
+------------------
+
+ * We used to allow committing a path ".Git/config" with Git that is
+ running on a case sensitive filesystem, but an attempt to check out
+ such a path with Git that runs on a case insensitive filesystem
+ would have clobbered ".git/config", which is definitely not what
+ the user would have expected. Git now prevents you from tracking
+ a path with ".Git" (in any case combination) as a path component.
+
+ * On Windows, certain path components that are different from ".git"
+ are mapped to ".git", e.g. "git~1/config" is treated as if it were
+ ".git/config". HFS+ has a similar issue, where certain unicode
+ codepoints are ignored, e.g. ".g\u200cit/config" is treated as if
+ it were ".git/config". Pathnames with these potential issues are
+ rejected on the affected systems. Git on systems that are not
+ affected by this issue (e.g. Linux) can also be configured to
+ reject them to ensure cross platform interoperability of the hosted
+ projects.
+
+ * "git fsck" notices a tree object that records such a path that can
+ be confused with ".git", and with receive.fsckObjects configuration
+ set to true, an attempt to "git push" such a tree object will be
+ rejected. Such a path may not be a problem on a well behaving
+ filesystem but in order to protect those on HFS+ and on case
+ insensitive filesystems, this check is enabled on all platforms.
+
+A big "thanks!" for bringing this issue to us goes to our friends in
+the Mercurial land, namely, Matt Mackall and Augie Fackler.
+
+Also contains typofixes, documentation updates and trivial code clean-ups.
diff --git a/Documentation/RelNotes/2.0.5.txt b/Documentation/RelNotes/2.0.5.txt
new file mode 100644
index 0000000..3a16f69
--- /dev/null
+++ b/Documentation/RelNotes/2.0.5.txt
@@ -0,0 +1,34 @@
+Git v2.0.5 Release Notes
+========================
+
+Fixes since v2.0.4
+------------------
+
+ * We used to allow committing a path ".Git/config" with Git that is
+ running on a case sensitive filesystem, but an attempt to check out
+ such a path with Git that runs on a case insensitive filesystem
+ would have clobbered ".git/config", which is definitely not what
+ the user would have expected. Git now prevents you from tracking
+ a path with ".Git" (in any case combination) as a path component.
+
+ * On Windows, certain path components that are different from ".git"
+ are mapped to ".git", e.g. "git~1/config" is treated as if it were
+ ".git/config". HFS+ has a similar issue, where certain unicode
+ codepoints are ignored, e.g. ".g\u200cit/config" is treated as if
+ it were ".git/config". Pathnames with these potential issues are
+ rejected on the affected systems. Git on systems that are not
+ affected by this issue (e.g. Linux) can also be configured to
+ reject them to ensure cross platform interoperability of the hosted
+ projects.
+
+ * "git fsck" notices a tree object that records such a path that can
+ be confused with ".git", and with receive.fsckObjects configuration
+ set to true, an attempt to "git push" such a tree object will be
+ rejected. Such a path may not be a problem on a well behaving
+ filesystem but in order to protect those on HFS+ and on case
+ insensitive filesystems, this check is enabled on all platforms.
+
+A big "thanks!" for bringing this issue to us goes to our friends in
+the Mercurial land, namely, Matt Mackall and Augie Fackler.
+
+Also contains typofixes, documentation updates and trivial code clean-ups.
diff --git a/Documentation/RelNotes/2.1.4.txt b/Documentation/RelNotes/2.1.4.txt
new file mode 100644
index 0000000..d16e5f0
--- /dev/null
+++ b/Documentation/RelNotes/2.1.4.txt
@@ -0,0 +1,34 @@
+Git v2.1.4 Release Notes
+========================
+
+Fixes since v2.1.3
+------------------
+
+ * We used to allow committing a path ".Git/config" with Git that is
+ running on a case sensitive filesystem, but an attempt to check out
+ such a path with Git that runs on a case insensitive filesystem
+ would have clobbered ".git/config", which is definitely not what
+ the user would have expected. Git now prevents you from tracking
+ a path with ".Git" (in any case combination) as a path component.
+
+ * On Windows, certain path components that are different from ".git"
+ are mapped to ".git", e.g. "git~1/config" is treated as if it were
+ ".git/config". HFS+ has a similar issue, where certain unicode
+ codepoints are ignored, e.g. ".g\u200cit/config" is treated as if
+ it were ".git/config". Pathnames with these potential issues are
+ rejected on the affected systems. Git on systems that are not
+ affected by this issue (e.g. Linux) can also be configured to
+ reject them to ensure cross platform interoperability of the hosted
+ projects.
+
+ * "git fsck" notices a tree object that records such a path that can
+ be confused with ".git", and with receive.fsckObjects configuration
+ set to true, an attempt to "git push" such a tree object will be
+ rejected. Such a path may not be a problem on a well behaving
+ filesystem but in order to protect those on HFS+ and on case
+ insensitive filesystems, this check is enabled on all platforms.
+
+A big "thanks!" for bringing this issue to us goes to our friends in
+the Mercurial land, namely, Matt Mackall and Augie Fackler.
+
+Also contains typofixes, documentation updates and trivial code clean-ups.
diff --git a/Documentation/RelNotes/2.2.1.txt b/Documentation/RelNotes/2.2.1.txt
new file mode 100644
index 0000000..d5a3cd9
--- /dev/null
+++ b/Documentation/RelNotes/2.2.1.txt
@@ -0,0 +1,34 @@
+Git v2.2.1 Release Notes
+========================
+
+Fixes since v2.2
+----------------
+
+ * We used to allow committing a path ".Git/config" with Git that is
+ running on a case sensitive filesystem, but an attempt to check out
+ such a path with Git that runs on a case insensitive filesystem
+ would have clobbered ".git/config", which is definitely not what
+ the user would have expected. Git now prevents you from tracking
+ a path with ".Git" (in any case combination) as a path component.
+
+ * On Windows, certain path components that are different from ".git"
+ are mapped to ".git", e.g. "git~1/config" is treated as if it were
+ ".git/config". HFS+ has a similar issue, where certain unicode
+ codepoints are ignored, e.g. ".g\u200cit/config" is treated as if
+ it were ".git/config". Pathnames with these potential issues are
+ rejected on the affected systems. Git on systems that are not
+ affected by this issue (e.g. Linux) can also be configured to
+ reject them to ensure cross platform interoperability of the hosted
+ projects.
+
+ * "git fsck" notices a tree object that records such a path that can
+ be confused with ".git", and with receive.fsckObjects configuration
+ set to true, an attempt to "git push" such a tree object will be
+ rejected. Such a path may not be a problem on a well behaving
+ filesystem but in order to protect those on HFS+ and on case
+ insensitive filesystems, this check is enabled on all platforms.
+
+A big "thanks!" for bringing this issue to us goes to our friends in
+the Mercurial land, namely, Matt Mackall and Augie Fackler.
+
+Also contains typofixes, documentation updates and trivial code clean-ups.
diff --git a/Documentation/RelNotes/2.2.2.txt b/Documentation/RelNotes/2.2.2.txt
new file mode 100644
index 0000000..b19a35d
--- /dev/null
+++ b/Documentation/RelNotes/2.2.2.txt
@@ -0,0 +1,63 @@
+Git v2.2.2 Release Notes
+========================
+
+Fixes since v2.2.1
+------------------
+
+ * "git checkout $treeish $path", when $path in the index and the
+ working tree already matched what is in $treeish at the $path,
+ still overwrote the $path unnecessarily.
+
+ * "git config --get-color" did not parse its command line arguments
+ carefully.
+
+ * open() emulated on Windows platforms did not give EISDIR upon
+ an attempt to open a directory for writing.
+
+ * A few code paths used abs() when they should have used labs() on
+ long integers.
+
+ * "gitweb" used to depend on a behaviour recent CGI.pm deprecated.
+
+ * "git init" (hence "git clone") initialized the per-repository
+ configuration file .git/config with x-bit by mistake.
+
+ * Git 2.0 was supposed to make the "simple" mode for the default of
+ "git push", but it didn't.
+
+ * "Everyday" document had a broken link.
+
+ * The build procedure did not bother fixing perl and python scripts
+ when NO_PERL and NO_PYTHON build-time configuration changed.
+
+ * The code that reads the reflog from the newer to the older entries
+ did not handle an entry that crosses a boundary of block it uses to
+ read them correctly.
+
+ * "git apply" was described in the documentation to take --ignore-date
+ option, which it does not.
+
+ * Traditionally we tried to avoid interpreting date strings given by
+ the user as future dates, e.g. GIT_COMMITTER_DATE=2014-12-10 when
+ used early November 2014 was taken as "October 12, 2014" because it
+ is likely that a date in the future, December 10, is a mistake.
+ This heuristics has been loosened to allow people to express future
+ dates (most notably, --until=<date> may want to be far in the
+ future) and we no longer tiebreak by future-ness of the date when
+
+ (1) ISO-like format is used, and
+ (2) the string can make sense interpreted as both y-m-d and y-d-m.
+
+ Git may still have to use the heuristics to tiebreak between dd/mm/yy
+ and mm/dd/yy, though.
+
+ * The code to abbreviate an object name to its short unique prefix
+ has been optimized when no abbreviation was requested.
+
+ * "git add --ignore-errors ..." did not ignore an error to
+ give a file that did not exist.
+
+ * Git did not correctly read an overlong refname from a packed refs
+ file.
+
+Also contains typofixes, documentation updates and trivial code clean-ups.
diff --git a/Documentation/RelNotes/2.3.0.txt b/Documentation/RelNotes/2.3.0.txt
index 880c062..e3c639c 100644
--- a/Documentation/RelNotes/2.3.0.txt
+++ b/Documentation/RelNotes/2.3.0.txt
@@ -1,12 +1,24 @@
Git v2.3 Release Notes
======================
+This one ended up to be a release with lots of small corrections and
+improvements without big uncomfortably exciting features. The recent
+security fix that went to 2.2.1 and older maintenance tracks is also
+contained in this update.
+
+
Updates since v2.2
------------------
Ports
- *
+ * Recent gcc toolchain on Cygwin started throwing compilation warning,
+ which has been squelched.
+
+ * A few updates to build on platforms that lack tv_nsec,
+ clock_gettime, CLOCK_MONOTONIC and HMAC_CTX_cleanup (e.g. older
+ RHEL) have been added.
+
UI, Workflows & Features
@@ -18,10 +30,106 @@ UI, Workflows & Features
note from the object but with --allow-empty we will store a
(surprise!) note that is empty.
+ * "git interpret-trailers" learned to properly handle the
+ "Conflicts:" block at the end.
+
+ * "git am" learned "--message-id" option to copy the message ID of
+ the incoming e-mail to the log message of resulting commit.
+
+ * "git clone --reference=<over there>" learned the "--dissociate"
+ option to go with it; it borrows objects from the reference object
+ store while cloning only to reduce network traffic and then
+ dissociates the resulting clone from the reference by performing
+ local copies of borrowed objects.
+
+ * "git send-email" learned "--transfer-encoding" option to force a
+ non-fault Content-Transfer-Encoding header (e.g. base64).
+
+ * "git send-email" normally identifies itself via X-Mailer: header in
+ the message it sends out. A new command line flag --no-xmailer
+ allows the user to squelch the header.
+
+ * "git push" into a repository with a working tree normally refuses
+ to modify the branch that is checked out. The command learned to
+ optionally do an equivalent of "git reset --hard" only when there
+ is no change to the working tree and the index instead, which would
+ be useful to "deploy" by pushing into a repository.
+
+ * "git new-workdir" (in contrib/) can be used to populate an empty
+ and existing directory now.
+
+ * Credential helpers are asked in turn until one of them give
+ positive response, which is cumbersome to turn off when you need to
+ run Git in an automated setting. The credential helper interface
+ learned to allow a helper to say "stop, don't ask other helpers."
+ Also GIT_TERMINAL_PROMPT environment can be set to false to disable
+ our built-in prompt mechanism for passwords.
+
+ * "git branch -d" (delete) and "git branch -m" (move) learned to
+ honor "-f" (force) flag; unlike many other subcommands, the way to
+ force these have been with separate "-D/-M" options, which was
+ inconsistent.
+
+ * "diff-highlight" filter (in contrib/) allows its color output to be
+ customized via configuration variables.
+
+ * "git imap-send" learned to take "-v" (verbose) and "-q" (quiet)
+ command line options.
+
+ * "git remote add $name $URL" is now allowed when "url.$URL.insteadOf"
+ is already defined.
+
+ * "git imap-send" now can be built to use cURL library to talk to
+ IMAP servers (if the library is recent enough, of course).
+ This allows you to use authenticate method other than CRAM-MD5,
+ among other things.
+
+ * "git imap-send" now allows GIT_CURL_VERBOSE environment variable to
+ control the verbosity when talking via the cURL library.
+
+ * The prompt script (in contrib/) learned to optionally hide prompt
+ when in an ignored directory by setting GIT_PS1_HIDE_IF_PWD_IGNORED
+ shell variable.
+
Performance, Internal Implementation, Development Support etc.
- *
+ * Earlier we made "rev-list --object-edge" more aggressively list the
+ objects at the edge commits, in order to reduce number of objects 
+ fetched into a shallow repository, but the change affected cases
+ other than "fetching into a shallow repository" and made it
+ unusably slow (e.g. fetching into a normal repository should not
+ have to suffer the overhead from extra processing). Limit it to a
+ more specific case by introducing --objects-edge-aggressive, a new
+ option to rev-list.
+
+ * Squelched useless compiler warnings on Mac OS X regarding the
+ crypto API.
+
+ * The procedure to generate unicode table has been simplified.
+
+ * Some filesystems assign filemodes in a strange way, fooling then
+ automatic "filemode trustability" check done during a new
+ repository creation. The initialization codepath has been hardened
+ against this issue.
+
+ * The codepath in "git remote update --prune" to drop many refs has
+ been optimized.
+
+ * The API into get_merge_bases*() family of functions was easy to
+ misuse, which has been corrected to make it harder to do so.
+
+ * Long overdue departure from the assumption that S_IFMT is shared by
+ everybody made in 2005, which was necessary to port to z/OS.
+
+ * "git push" and "git fetch" did not communicate an overlong refname
+ correctly. Now it uses 64kB sideband to accommodate longer ones.
+
+ * Recent GPG changes the keyring format and drops support for RFC1991
+ formatted signatures, breaking our existing tests.
+
+ * "git-prompt" (in contrib/) used a variable from the global scope,
+ possibly contaminating end-user's namespace.
Also contains various documentation updates and code clean-ups.
@@ -34,6 +142,112 @@ Unless otherwise noted, all the fixes since v2.2 in the maintenance
track are contained in this release (see the maintenance releases'
notes for details).
+ * "git http-push" over WebDAV (aka dumb http-push) was broken in
+ v2.2.2 when parsing a symbolic ref, resulting in a bogus request
+ that gets rejected by recent versions of cURL library.
+ (merge f6786c8 jk/http-push-symref-fix later to maint).
+
+ * The logic in "git bisect bad HEAD" etc. to avoid forcing the test
+ of the common ancestor of bad and good commits was broken.
+ (merge 07913d5 cc/bisect-rev-parsing later to maint).
+
+ * "git checkout-index --temp=$target $path" did not work correctly
+ for paths outside the current subdirectory in the project.
+ (merge 74c4de5 es/checkout-index-temp later to maint).
+
+ * The report from "git checkout" on a branch that builds on another
+ local branch by setting its branch.*.merge to branch name (not a
+ full refname) incorrectly said that the upstream is gone.
+ (merge 05e7368 jc/checkout-local-track-report later to maint).
+
+ * With The git-prompt support (in contrib/), using the exit status of
+ the last command in the prompt, e.g. PS1='$(__git_ps1) $? ', did
+ not work well, because the helper function stomped on the exit
+ status.
+ (merge 6babe76 tf/prompt-preserve-exit-status later to maint).
+
+ * Recent update to "git commit" broke amending an existing commit
+ with bogus author/committer lines without a valid e-mail address.
+ (merge c83a509 jk/commit-date-approxidate later to maint).
+
+ * The lockfile API used to get confused which file to clean up when
+ the process moved the $cwd after creating a lockfile.
+ (merge fa137f6 nd/lockfile-absolute later to maint).
+
+ * Traditionally we tried to avoid interpreting date strings given by
+ the user as future dates, e.g. GIT_COMMITTER_DATE=2014-12-10 when
+ used early November 2014 was taken as "October 12, 2014" because it
+ is likely that a date in the future, December 10, is a mistake.
+ This heuristics has been loosened to allow people to express future
+ dates (most notably, --until=<date> may want to be far in the
+ future) and we no longer tiebreak by future-ness of the date when
+
+ (1) ISO-like format is used, and
+ (2) the string can make sense interpreted as both y-m-d and y-d-m.
+
+ Git may still have to use the heuristics to tiebreak between dd/mm/yy
+ and mm/dd/yy, though.
+ (merge d372395 jk/approxidate-avoid-y-d-m-over-future-dates later to maint).
+
+ * Git did not correctly read an overlong refname from a packed refs
+ file.
+ (merge ea41783 jk/read-packed-refs-without-path-max later to maint).
+
+ * "git apply" was described in the documentation to take --ignore-date
+ option, which it does not.
+ (merge 0cef4e7 rw/apply-does-not-take-ignore-date later to maint).
+
+ * "git add -i" did not notice when the interactive command input
+ stream went away and kept asking the same question.
+ (merge a8bec7a jk/add-i-read-error later to maint).
+
+ * "git send-email" did not handle RFC 2047 encoded headers quite
+ right.
+ (merge ab47e2a rd/send-email-2047-fix later to maint).
+
+ * New tag object format validation added in 2.2 showed garbage after
+ a tagname it reported in its error message.
+ (merge a1e920a js/fsck-tag-validation later to maint).
+
+ * The code that reads the reflog from the newer to the older entries
+ did not handle an entry that crosses a boundary of block it uses to
+ read them correctly.
+ (merge 69216bf jk/for-each-reflog-ent-reverse later to maint).
+
+ * "git diff -B -M" after making a new copy B out of an existing file
+ A and then editing A extensively ought to report that B was created
+ by copying A and A was modified, which is what "git diff -C"
+ reports, but it instead said A was renamed to B and A was edited
+ heavily in place. This was not just incoherent but also failed to
+ apply with "git apply". The report has been corrected to match what
+ "git diff -C" produces for this case.
+ (merge 6936b58 jc/diff-b-m later to maint).
+
+ * In files we pre-populate for the user to edit with commented hints,
+ a line of hint that is indented with a tab used to show as '#' (or
+ any comment char), ' ' (space), and then the hint text that began
+ with the tab, which some editors flag as an indentation error (tab
+ following space). We now omit the space after the comment char in
+ such a case.
+ (merge d55aeb7 jc/strbuf-add-lines-avoid-sp-ht-sequence later to maint).
+
+ * "git ls-tree" does not support path selection based on negative
+ pathspecs, but did not error out when negative pathspecs are given.
+ (merge f1f6224 nd/ls-tree-pathspec later to maint).
+
+ * The function sometimes returned a non-freeable memory and some
+ other times returned a piece of memory that must be freed, leading
+ to inevitable leaks.
+ (merge 59362e5 jc/exec-cmd-system-path-leak-fix later to maint).
+
+ * The code to abbreviate an object name to its short unique prefix
+ has been optimized when no abbreviation was requested.
+ (merge 61e704e mh/find-uniq-abbrev later to maint).
+
+ * "git add --ignore-errors ..." did not ignore an error to
+ give a file that did not exist.
+ (merge 1d31e5a mg/add-ignore-errors later to maint).
+
* "git checkout $treeish $path", when $path in the index and the
working tree already matched what is in $treeish at the $path,
still overwrote the $path unnecessarily.
@@ -59,6 +273,10 @@ notes for details).
configuration file .git/config with x-bit by mistake.
(merge 1f32ecf mh/config-flip-xbit-back-after-checking later to maint).
+ * Recent update in Git 2.2 started creating objects/info/packs and
+ info/refs files with permission bits tighter than user's umask.
+ (merge d91175b jk/prune-packed-server-info later to maint).
+
* Git 2.0 was supposed to make the "simple" mode for the default of
"git push", but it didn't.
(merge 00a6fa0 jk/push-simple later to maint).
@@ -72,3 +290,11 @@ notes for details).
* The build procedure did not bother fixing perl and python scripts
when NO_PERL and NO_PYTHON build-time configuration changed.
(merge ca2051d jk/rebuild-perl-scripts-with-no-perl-seting-change later to maint).
+
+ * The usage string of "git log" command was marked incorrectly for
+ l10n.
+ (merge e66dc0c km/log-usage-string-i18n later to maint).
+
+ * "git for-each-ref" mishandled --format="%(upstream:track)" when a
+ branch is marked to have forked from a non-existing branch.
+ (merge b6160d9 rc/for-each-ref-tracking later to maint).
diff --git a/Documentation/RelNotes/2.3.1.txt b/Documentation/RelNotes/2.3.1.txt
new file mode 100644
index 0000000..cf96186
--- /dev/null
+++ b/Documentation/RelNotes/2.3.1.txt
@@ -0,0 +1,52 @@
+Git v2.3.1 Release Notes
+========================
+
+Fixes since v2.3
+----------------
+
+ * The interactive "show a list and let the user choose from it"
+ interface "add -i" used showed and prompted to the user even when
+ the candidate list was empty, against which the only "choice" the
+ user could have made was to choose nothing.
+
+ * "git apply --whitespace=fix" used to under-allocate the memory
+ when the fix resulted in a longer text than the original patch.
+
+ * "git log --help" used to show rev-list options that are irrelevant
+ to the "log" command.
+
+ * The error message from "git commit", when a non-existing author
+ name was given as value to the "--author=" parameter, has been
+ reworded to avoid misunderstanding.
+
+ * A broken pack .idx file in the receiving repository prevented the
+ dumb http transport from fetching a good copy of it from the other
+ side.
+
+ * The documentation incorrectly said that C(opy) and R(ename) are the
+ only ones that can be followed by the score number in the output in
+ the --raw format.
+
+ * Fix a misspelled conditional that is always true.
+
+ * Code to read branch name from various files in .git/ directory
+ would have misbehaved if the code to write them left an empty file.
+
+ * The "git push" documentation made the "--repo=<there>" option
+ easily misunderstood.
+
+ * After attempting and failing a password-less authentication
+ (e.g. kerberos), libcURL refuses to fall back to password based
+ Basic authentication without a bit of help/encouragement.
+
+ * Setting diff.submodule to 'log' made "git format-patch" produce
+ broken patches.
+
+ * "git rerere" (invoked internally from many mergy operations) did
+ not correctly signal errors when told to update the working tree
+ files and failed to do so for whatever reason.
+
+ * "git blame HEAD -- missing" failed to correctly say "HEAD" when it
+ tried to say "No such path 'missing' in HEAD".
+
+Also contains typofixes, documentation updates and trivial code clean-ups.
diff --git a/Documentation/SubmittingPatches b/Documentation/SubmittingPatches
index fa71b5f..ef0eeb4 100644
--- a/Documentation/SubmittingPatches
+++ b/Documentation/SubmittingPatches
@@ -57,7 +57,8 @@ change, the approach taken by the change, and if relevant how this
differs substantially from the prior version, are all good things
to have.
-Make sure that you have tests for the bug you are fixing.
+Make sure that you have tests for the bug you are fixing. See
+t/README for guidance.
When adding a new feature, make sure that you have new tests to show
the feature triggers the new behaviour when it should, and to show the
@@ -175,8 +176,11 @@ message starts, you can put a "From: " line to name that person.
You often want to add additional explanation about the patch,
other than the commit message itself. Place such "cover letter"
-material between the three dash lines and the diffstat. Git-notes
-can also be inserted using the `--notes` option.
+material between the three-dash line and the diffstat. For
+patches requiring multiple iterations of review and discussion,
+an explanation of changes between each iteration can be kept in
+Git-notes and inserted automatically following the three-dash
+line via `git format-patch --notes`.
Do not attach the patch as a MIME attachment, compressed or not.
Do not let your e-mail client send quoted-printable. Do not let
@@ -254,15 +258,15 @@ pretty simple: if you can certify the below:
person who certified (a), (b) or (c) and I have not modified
it.
- (d) I understand and agree that this project and the contribution
- are public and that a record of the contribution (including all
- personal information I submit with it, including my sign-off) is
- maintained indefinitely and may be redistributed consistent with
- this project or the open source license(s) involved.
+ (d) I understand and agree that this project and the contribution
+ are public and that a record of the contribution (including all
+ personal information I submit with it, including my sign-off) is
+ maintained indefinitely and may be redistributed consistent with
+ this project or the open source license(s) involved.
then you just add a line saying
- Signed-off-by: Random J Developer <random@developer.example.org>
+ Signed-off-by: Random J Developer <random@developer.example.org>
This line can be automatically added by Git if you run the git-commit
command with the -s option.
diff --git a/Documentation/config.txt b/Documentation/config.txt
index f615a5c..440784c 100644
--- a/Documentation/config.txt
+++ b/Documentation/config.txt
@@ -246,6 +246,17 @@ core.precomposeunicode::
When false, file names are handled fully transparent by Git,
which is backward compatible with older versions of Git.
+core.protectHFS::
+ If set to true, do not allow checkout of paths that would
+ be considered equivalent to `.git` on an HFS+ filesystem.
+ Defaults to `true` on Mac OS, and `false` elsewhere.
+
+core.protectNTFS::
+ If set to true, do not allow checkout of paths that would
+ cause problems with the NTFS filesystem, e.g. conflict with
+ 8.3 "short" names.
+ Defaults to `true` on Windows, and `false` elsewhere.
+
core.trustctime::
If false, the ctime differences between the index and the
working tree are ignored; useful when the inode change time
@@ -364,14 +375,19 @@ This is useful for excluding servers inside a firewall from
proxy use, while defaulting to a common proxy for external domains.
core.ignoreStat::
- If true, commands which modify both the working tree and the index
- will mark the updated paths with the "assume unchanged" bit in the
- index. These marked files are then assumed to stay unchanged in the
- working tree, until you mark them otherwise manually - Git will not
- detect the file changes by lstat() calls. This is useful on systems
- where those are very slow, such as Microsoft Windows.
- See linkgit:git-update-index[1].
- False by default.
+ If true, Git will avoid using lstat() calls to detect if files have
+ changed by setting the "assume-unchanged" bit for those tracked files
+ which it has updated identically in both the index and working tree.
++
+When files are modified outside of Git, the user will need to stage
+the modified files explicitly (e.g. see 'Examples' section in
+linkgit:git-update-index[1]).
+Git will not normally detect changes to those files.
++
+This is useful on systems where lstat() calls are very slow, such as
+CIFS/Microsoft Windows.
++
+False by default.
core.preferSymlinkRefs::
Instead of the default "symref" format for HEAD
@@ -667,14 +683,13 @@ core.abbrev::
for abbreviated object names to stay unique for sufficiently long
time.
-add.ignore-errors::
add.ignoreErrors::
+add.ignore-errors (deprecated)::
Tells 'git add' to continue adding files when some files cannot be
added due to indexing errors. Equivalent to the '--ignore-errors'
- option of linkgit:git-add[1]. Older versions of Git accept only
- `add.ignore-errors`, which does not follow the usual naming
- convention for configuration variables. Newer versions of Git
- honor `add.ignoreErrors` as well.
+ option of linkgit:git-add[1]. `add.ignore-errors` is deprecated,
+ as it does not follow the usual naming convention for configuration
+ variables.
alias.*::
Command aliases for the linkgit:git[1] command wrapper - e.g.
@@ -838,11 +853,13 @@ accepted are `normal`, `black`, `red`, `green`, `yellow`, `blue`,
`magenta`, `cyan` and `white`; the attributes are `bold`, `dim`, `ul`,
`blink` and `reverse`. The first color given is the foreground; the
second is the background. The position of the attribute, if any,
-doesn't matter.
+doesn't matter. Attributes may be turned off specifically by prefixing
+them with `no` (e.g., `noreverse`, `noul`, etc).
+
Colors (foreground and background) may also be given as numbers between
0 and 255; these use ANSI 256-color mode (but note that not all
-terminals may support this).
+terminals may support this). If your terminal supports it, you may also
+specify 24-bit RGB values as hex, like `#ff0ab3`.
color.diff::
Whether to use ANSI escape sequences to add color to patches.
@@ -1942,7 +1959,7 @@ pack.useBitmaps::
true. You should not generally need to turn this off unless
you are debugging pack bitmaps.
-pack.writebitmaps::
+pack.writebitmaps (deprecated)::
This is a deprecated synonym for `repack.writeBitmaps`.
pack.writeBitmapHashCache::
@@ -2076,6 +2093,11 @@ rebase.autostash::
successful rebase might result in non-trivial conflicts.
Defaults to false.
+receive.advertiseatomic::
+ By default, git-receive-pack will advertise the atomic push
+ capability to its clients. If you don't want to this capability
+ to be advertised, set this variable to false.
+
receive.autogc::
By default, git-receive-pack will run "git-gc --auto" after
receiving data from git-push and updating refs. You can stop
@@ -2133,6 +2155,17 @@ receive.denyCurrentBranch::
print a warning of such a push to stderr, but allow the push to
proceed. If set to false or "ignore", allow such pushes with no
message. Defaults to "refuse".
++
+Another option is "updateInstead" which will update the working
+tree if pushing into the current branch. This option is
+intended for synchronizing working directories when one side is not easily
+accessible via interactive ssh (e.g. a live web site, hence the requirement
+that the working directory be clean). This mode also comes in handy when
+developing inside a VM to test and fix code on different Operating Systems.
++
+By default, "updateInstead" will refuse the push if the working tree or
+the index have any difference from the HEAD, but the `push-to-checkout`
+hook can be used to customize this. See linkgit:githooks[5].
receive.denyNonFastForwards::
If set to true, git-receive-pack will deny a ref update which is
@@ -2272,7 +2305,7 @@ sendemail.smtpencryption::
See linkgit:git-send-email[1] for description. Note that this
setting is not subject to the 'identity' mechanism.
-sendemail.smtpssl::
+sendemail.smtpssl (deprecated)::
Deprecated alias for 'sendemail.smtpencryption = ssl'.
sendemail.smtpsslcertpath::
@@ -2307,10 +2340,12 @@ sendemail.smtpserverport::
sendemail.smtpserveroption::
sendemail.smtpuser::
sendemail.thread::
+sendemail.transferencoding::
sendemail.validate::
+sendemail.xmailer::
See linkgit:git-send-email[1] for description.
-sendemail.signedoffcc::
+sendemail.signedoffcc (deprecated)::
Deprecated alias for 'sendemail.signedoffbycc'.
showbranch.default::
diff --git a/Documentation/diff-format.txt b/Documentation/diff-format.txt
index 15c7e79..85b0890 100644
--- a/Documentation/diff-format.txt
+++ b/Documentation/diff-format.txt
@@ -66,7 +66,8 @@ be committed)
Status letters C and R are always followed by a score (denoting the
percentage of similarity between the source and target of the move or
-copy), and are the only ones to be so.
+copy). Status letter M may be followed by a score (denoting the
+percentage of dissimilarity) for file rewrites.
<sha1> is shown as all 0's if a file is new on the filesystem
and it is out of sync with the index.
diff --git a/Documentation/git-add.txt b/Documentation/git-add.txt
index 9631526..1c74907 100644
--- a/Documentation/git-add.txt
+++ b/Documentation/git-add.txt
@@ -8,7 +8,7 @@ git-add - Add file contents to the index
SYNOPSIS
--------
[verse]
-'git add' [-n] [-v] [--force | -f] [--interactive | -i] [--patch | -p]
+'git add' [--verbose | -v] [--dry-run | -n] [--force | -f] [--interactive | -i] [--patch | -p]
[--edit | -e] [--[no-]all | --[no-]ignore-removal | [--update | -u]]
[--intent-to-add | -N] [--refresh] [--ignore-errors] [--ignore-missing]
[--] [<pathspec>...]
diff --git a/Documentation/git-am.txt b/Documentation/git-am.txt
index 9adce37..f4eea28 100644
--- a/Documentation/git-am.txt
+++ b/Documentation/git-am.txt
@@ -57,6 +57,17 @@ OPTIONS
--no-scissors::
Ignore scissors lines (see linkgit:git-mailinfo[1]).
+-m::
+--message-id::
+ Pass the `-m` flag to 'git mailinfo' (see linkgit:git-mailinfo[1]),
+ so that the Message-ID header is added to the commit message.
+ The `am.messageid` configuration variable can be used to specify
+ the default behaviour.
+
+--no-message-id::
+ Do not add the Message-ID header to the commit message.
+ `no-message-id` is useful to override `am.messageid`.
+
-q::
--quiet::
Be quiet. Only print error messages.
@@ -83,7 +94,6 @@ default. You can use `--no-utf8` to override this.
it is supposed to apply to and we have those blobs
available locally.
---ignore-date::
--ignore-space-change::
--ignore-whitespace::
--whitespace=<option>::
diff --git a/Documentation/git-check-ignore.txt b/Documentation/git-check-ignore.txt
index ee2e091..788a011 100644
--- a/Documentation/git-check-ignore.txt
+++ b/Documentation/git-check-ignore.txt
@@ -21,6 +21,9 @@ the exclude mechanism) that decides if the pathname is excluded or
included. Later patterns within a file take precedence over earlier
ones.
+By default, tracked files are not shown at all since they are not
+subject to exclude rules; but see `--no-index'.
+
OPTIONS
-------
-q, --quiet::
diff --git a/Documentation/git-clone.txt b/Documentation/git-clone.txt
index 0363d00..f1f2a3f 100644
--- a/Documentation/git-clone.txt
+++ b/Documentation/git-clone.txt
@@ -12,7 +12,7 @@ SYNOPSIS
'git clone' [--template=<template_directory>]
[-l] [-s] [--no-hardlinks] [-q] [-n] [--bare] [--mirror]
[-o <name>] [-b <name>] [-u <upload-pack>] [--reference <repository>]
- [--separate-git-dir <git dir>]
+ [--dissociate] [--separate-git-dir <git dir>]
[--depth <depth>] [--[no-]single-branch]
[--recursive | --recurse-submodules] [--] <repository>
[<directory>]
@@ -98,7 +98,14 @@ objects from the source repository into a pack in the cloned repository.
require fewer objects to be copied from the repository
being cloned, reducing network and local storage costs.
+
-*NOTE*: see the NOTE for the `--shared` option.
+*NOTE*: see the NOTE for the `--shared` option, and also the
+`--dissociate` option.
+
+--dissociate::
+ Borrow the objects from reference repositories specified
+ with the `--reference` options only to reduce network
+ transfer and stop borrowing from them after a clone is made
+ by making necessary local copies of borrowed objects.
--quiet::
-q::
diff --git a/Documentation/git-imap-send.txt b/Documentation/git-imap-send.txt
index c7c0d21..77aacf1 100644
--- a/Documentation/git-imap-send.txt
+++ b/Documentation/git-imap-send.txt
@@ -9,7 +9,7 @@ git-imap-send - Send a collection of patches from stdin to an IMAP folder
SYNOPSIS
--------
[verse]
-'git imap-send'
+'git imap-send' [-v] [-q] [--[no-]curl]
DESCRIPTION
@@ -26,6 +26,27 @@ Typical usage is something like:
git format-patch --signoff --stdout --attach origin | git imap-send
+OPTIONS
+-------
+
+-v::
+--verbose::
+ Be verbose.
+
+-q::
+--quiet::
+ Be quiet.
+
+--curl::
+ Use libcurl to communicate with the IMAP server, unless tunneling
+ into it. Ignored if Git was built without the USE_CURL_FOR_IMAP_SEND
+ option set.
+
+--no-curl::
+ Talk to the IMAP server using git's own IMAP routines instead of
+ using libcurl.
+
+
CONFIGURATION
-------------
@@ -75,7 +96,9 @@ imap.preformattedHTML::
imap.authMethod::
Specify authenticate method for authentication with IMAP server.
- Current supported method is 'CRAM-MD5' only. If this is not set
+ If Git was built with the NO_CURL option, or if your curl version is older
+ than 7.34.0, or if you're running git-imap-send with the `--no-curl`
+ option, the only supported method is 'CRAM-MD5'. If this is not set
then 'git imap-send' uses the basic IMAP plaintext LOGIN command.
Examples
diff --git a/Documentation/git-mailinfo.txt b/Documentation/git-mailinfo.txt
index 164a3c6..0947084 100644
--- a/Documentation/git-mailinfo.txt
+++ b/Documentation/git-mailinfo.txt
@@ -66,6 +66,11 @@ conversion, even with this flag.
-n::
Disable all charset re-coding of the metadata.
+-m::
+--message-id::
+ Copy the Message-ID header at the end of the commit message. This
+ is useful in order to associate commits with mailing list discussions.
+
--scissors::
Remove everything in body before a scissors line. A line that
mainly consists of scissors (either ">8" or "8<") and perforation
diff --git a/Documentation/git-p4.txt b/Documentation/git-p4.txt
index 6ab5f94..a1664b9 100644
--- a/Documentation/git-p4.txt
+++ b/Documentation/git-p4.txt
@@ -241,6 +241,9 @@ Git repository:
Use a client spec to find the list of interesting files in p4.
See the "CLIENT SPEC" section below.
+-/ <path>::
+ Exclude selected depot paths when cloning or syncing.
+
Clone options
~~~~~~~~~~~~~
These options can be used in an initial 'clone', along with the 'sync'
@@ -254,9 +257,6 @@ options described above.
--bare::
Perform a bare clone. See linkgit:git-clone[1].
--/ <path>::
- Exclude selected depot paths when cloning.
-
Submit options
~~~~~~~~~~~~~~
These options can be used to modify 'git p4 submit' behavior.
diff --git a/Documentation/git-pack-objects.txt b/Documentation/git-pack-objects.txt
index d2d8f47..c2f76fb 100644
--- a/Documentation/git-pack-objects.txt
+++ b/Documentation/git-pack-objects.txt
@@ -13,7 +13,7 @@ SYNOPSIS
[--no-reuse-delta] [--delta-base-offset] [--non-empty]
[--local] [--incremental] [--window=<n>] [--depth=<n>]
[--revs [--unpacked | --all]] [--stdout | base-name]
- [--keep-true-parents] < object-list
+ [--shallow] [--keep-true-parents] < object-list
DESCRIPTION
@@ -190,6 +190,11 @@ required objects and is thus unusable by Git without making it
self-contained. Use `git index-pack --fix-thin`
(see linkgit:git-index-pack[1]) to restore the self-contained property.
+--shallow::
+ Optimize a pack that will be provided to a client with a shallow
+ repository. This option, combined with \--thin, can result in a
+ smaller pack at the cost of speed.
+
--delta-base-offset::
A packed archive can express the base object of a delta as
either a 20-byte object name or as an offset in the
diff --git a/Documentation/git-push.txt b/Documentation/git-push.txt
index b17283a..e1a46a7 100644
--- a/Documentation/git-push.txt
+++ b/Documentation/git-push.txt
@@ -9,7 +9,7 @@ git-push - Update remote refs along with associated objects
SYNOPSIS
--------
[verse]
-'git push' [--all | --mirror | --tags] [--follow-tags] [-n | --dry-run] [--receive-pack=<git-receive-pack>]
+'git push' [--all | --mirror | --tags] [--follow-tags] [--atomic] [-n | --dry-run] [--receive-pack=<git-receive-pack>]
[--repo=<repository>] [-f | --force] [--prune] [-v | --verbose]
[-u | --set-upstream] [--signed]
[--force-with-lease[=<refname>[:<expect>]]]
@@ -136,6 +136,11 @@ already exists on the remote side.
logged. See linkgit:git-receive-pack[1] for the details
on the receiving end.
+--[no-]atomic::
+ Use an atomic transaction on the remote side if available.
+ Either all refs are updated, or on error, no refs are updated.
+ If the server does not support atomic pushes the push will fail.
+
--receive-pack=<git-receive-pack>::
--exec=<git-receive-pack>::
Path to the 'git-receive-pack' program on the remote
@@ -214,22 +219,8 @@ origin +master` to force a push to the `master` branch). See the
`<refspec>...` section above for details.
--repo=<repository>::
- This option is only relevant if no <repository> argument is
- passed in the invocation. In this case, 'git push' derives the
- remote name from the current branch: If it tracks a remote
- branch, then that remote repository is pushed to. Otherwise,
- the name "origin" is used. For this latter case, this option
- can be used to override the name "origin". In other words,
- the difference between these two commands
-+
---------------------------
-git push public #1
-git push --repo=public #2
---------------------------
-+
-is that #1 always pushes to "public" whereas #2 pushes to "public"
-only if the current branch does not track a remote branch. This is
-useful if you write an alias or script around 'git push'.
+ This option is equivalent to the <repository> argument. If both
+ are specified, the command-line argument takes precedence.
-u::
--set-upstream::
diff --git a/Documentation/git-remote.txt b/Documentation/git-remote.txt
index cb103c8..a77607b 100644
--- a/Documentation/git-remote.txt
+++ b/Documentation/git-remote.txt
@@ -130,17 +130,25 @@ branches, adds to that list.
'set-url'::
-Changes URL remote points to. Sets first URL remote points to matching
+Changes URLs for the remote. Sets first URL for remote <name> that matches
regex <oldurl> (first URL if no <oldurl> is given) to <newurl>. If
-<oldurl> doesn't match any URL, error occurs and nothing is changed.
+<oldurl> doesn't match any URL, an error occurs and nothing is changed.
+
With '--push', push URLs are manipulated instead of fetch URLs.
+
-With '--add', instead of changing some URL, new URL is added.
+With '--add', instead of changing existing URLs, new URL is added.
+
-With '--delete', instead of changing some URL, all URLs matching
-regex <url> are deleted. Trying to delete all non-push URLs is an
-error.
+With '--delete', instead of changing existing URLs, all URLs matching
+regex <url> are deleted for remote <name>. Trying to delete all
+non-push URLs is an error.
++
+Note that the push URL and the fetch URL, even though they can
+be set differently, must still refer to the same place. What you
+pushed to the push URL should be what you would see if you
+immediately fetched from the fetch URL. If you are trying to
+fetch from one place (e.g. your upstream) and push to another (e.g.
+your publishing repository), use two separate remotes.
+
'show'::
diff --git a/Documentation/git-rev-list.txt b/Documentation/git-rev-list.txt
index fd7f8b5..5b11922 100644
--- a/Documentation/git-rev-list.txt
+++ b/Documentation/git-rev-list.txt
@@ -46,7 +46,8 @@ SYNOPSIS
[ \--extended-regexp | -E ]
[ \--fixed-strings | -F ]
[ \--date=(local|relative|default|iso|iso-strict|rfc|short) ]
- [ [\--objects | \--objects-edge] [ \--unpacked ] ]
+ [ [ \--objects | \--objects-edge | \--objects-edge-aggressive ]
+ [ \--unpacked ] ]
[ \--pretty | \--header ]
[ \--bisect ]
[ \--bisect-vars ]
diff --git a/Documentation/git-send-email.txt b/Documentation/git-send-email.txt
index a60776e..f248a86 100644
--- a/Documentation/git-send-email.txt
+++ b/Documentation/git-send-email.txt
@@ -131,6 +131,21 @@ Note that no attempts whatsoever are made to validate the encoding.
Specify encoding of compose message. Default is the value of the
'sendemail.composeencoding'; if that is unspecified, UTF-8 is assumed.
+--transfer-encoding=(7bit|8bit|quoted-printable|base64)::
+ Specify the transfer encoding to be used to send the message over SMTP.
+ 7bit will fail upon encountering a non-ASCII message. quoted-printable
+ can be useful when the repository contains files that contain carriage
+ returns, but makes the raw patch email file (as saved from a MUA) much
+ harder to inspect manually. base64 is even more fool proof, but also
+ even more opaque. Default is the value of the 'sendemail.transferEncoding'
+ configuration value; if that is unspecified, git will use 8bit and not
+ add a Content-Transfer-Encoding header.
+
+--xmailer::
+--no-xmailer::
+ Add (or prevent adding) the "X-Mailer:" header. By default,
+ the header is added, but it can be turned off by setting the
+ `sendemail.xmailer` configuration variable to `false`.
Sending
~~~~~~~
@@ -199,10 +214,15 @@ must be used for each option.
Legacy alias for '--smtp-encryption ssl'.
--smtp-ssl-cert-path::
- Path to ca-certificates (either a directory or a single file).
- Set it to an empty string to disable certificate verification.
- Defaults to the value set to the 'sendemail.smtpsslcertpath'
- configuration variable, if set, or `/etc/ssl/certs` otherwise.
+ Path to a store of trusted CA certificates for SMTP SSL/TLS
+ certificate validation (either a directory that has been processed
+ by 'c_rehash', or a single file containing one or more PEM format
+ certificates concatenated together: see verify(1) -CAfile and
+ -CApath for more information on these). Set it to an empty string
+ to disable certificate verification. Defaults to the value of the
+ 'sendemail.smtpsslcertpath' configuration variable, if set, or the
+ backing SSL library's compiled-in default otherwise (which should
+ be the best choice on most platforms).
--smtp-user=<user>::
Username for SMTP-AUTH. Default is the value of 'sendemail.smtpuser';
diff --git a/Documentation/git-send-pack.txt b/Documentation/git-send-pack.txt
index 2a0de42..45c7725 100644
--- a/Documentation/git-send-pack.txt
+++ b/Documentation/git-send-pack.txt
@@ -9,7 +9,7 @@ git-send-pack - Push objects over Git protocol to another repository
SYNOPSIS
--------
[verse]
-'git send-pack' [--all] [--dry-run] [--force] [--receive-pack=<git-receive-pack>] [--verbose] [--thin] [<host>:]<directory> [<ref>...]
+'git send-pack' [--all] [--dry-run] [--force] [--receive-pack=<git-receive-pack>] [--verbose] [--thin] [--atomic] [<host>:]<directory> [<ref>...]
DESCRIPTION
-----------
@@ -62,6 +62,11 @@ be in a separate packet, and the list must end with a flush packet.
Send a "thin" pack, which records objects in deltified form based
on objects not included in the pack to reduce network traffic.
+--atomic::
+ Use an atomic transaction for updating the refs. If any of the refs
+ fails to update then the entire push will fail without changing any
+ refs.
+
<host>::
A remote host to house the repository. When this
part is specified, 'git-receive-pack' is invoked via
diff --git a/Documentation/git-stripspace.txt b/Documentation/git-stripspace.txt
index c87bfcb..6c6e989 100644
--- a/Documentation/git-stripspace.txt
+++ b/Documentation/git-stripspace.txt
@@ -10,6 +10,7 @@ SYNOPSIS
--------
[verse]
'git stripspace' [-s | --strip-comments] < input
+'git stripspace' [-c | --comment-lines] < input
DESCRIPTION
-----------
diff --git a/Documentation/git-update-index.txt b/Documentation/git-update-index.txt
index 929869b..aff0179 100644
--- a/Documentation/git-update-index.txt
+++ b/Documentation/git-update-index.txt
@@ -82,20 +82,18 @@ OPTIONS
Set the execute permissions on the updated files.
--[no-]assume-unchanged::
- When these flags are specified, the object names recorded
- for the paths are not updated. Instead, these options
- set and unset the "assume unchanged" bit for the
- paths. When the "assume unchanged" bit is on, Git stops
- checking the working tree files for possible
- modifications, so you need to manually unset the bit to
- tell Git when you change the working tree file. This is
+ When this flag is specified, the object names recorded
+ for the paths are not updated. Instead, this option
+ sets/unsets the "assume unchanged" bit for the
+ paths. When the "assume unchanged" bit is on, the user
+ promises not to change the file and allows Git to assume
+ that the working tree file matches what is recorded in
+ the index. If you want to change the working tree file,
+ you need to unset the bit to tell Git. This is
sometimes helpful when working with a big project on a
filesystem that has very slow lstat(2) system call
(e.g. cifs).
+
-This option can be also used as a coarse file-level mechanism
-to ignore uncommitted changes in tracked files (akin to what
-`.gitignore` does for untracked files).
Git will fail (gracefully) in case it needs to modify this file
in the index e.g. when merging in a commit;
thus, in case the assumed-untracked file is changed upstream,
diff --git a/Documentation/git.txt b/Documentation/git.txt
index dd17254..b37f1ab 100644
--- a/Documentation/git.txt
+++ b/Documentation/git.txt
@@ -43,40 +43,52 @@ unreleased) version of Git, that is available from the 'master'
branch of the `git.git` repository.
Documentation for older releases are available here:
-* link:v2.2.0/git.html[documentation for release 2.2]
+* link:v2.3.1/git.html[documentation for release 2.3.1]
* release notes for
+ link:RelNotes/2.3.1.txt[2.3.1],
+ link:RelNotes/2.3.0.txt[2.3].
+
+* link:v2.2.2/git.html[documentation for release 2.2.2]
+
+* release notes for
+ link:RelNotes/2.2.2.txt[2.2.2],
+ link:RelNotes/2.2.1.txt[2.2.1],
link:RelNotes/2.2.0.txt[2.2].
-* link:v2.1.3/git.html[documentation for release 2.1.3]
+* link:v2.1.4/git.html[documentation for release 2.1.4]
* release notes for
+ link:RelNotes/2.1.4.txt[2.1.4],
link:RelNotes/2.1.3.txt[2.1.3],
link:RelNotes/2.1.2.txt[2.1.2],
link:RelNotes/2.1.1.txt[2.1.1],
link:RelNotes/2.1.0.txt[2.1].
-* link:v2.0.4/git.html[documentation for release 2.0.4]
+* link:v2.0.5/git.html[documentation for release 2.0.5]
* release notes for
+ link:RelNotes/2.0.5.txt[2.0.5],
link:RelNotes/2.0.4.txt[2.0.4],
link:RelNotes/2.0.3.txt[2.0.3],
link:RelNotes/2.0.2.txt[2.0.2],
link:RelNotes/2.0.1.txt[2.0.1],
link:RelNotes/2.0.0.txt[2.0.0].
-* link:v1.9.4/git.html[documentation for release 1.9.4]
+* link:v1.9.5/git.html[documentation for release 1.9.5]
* release notes for
+ link:RelNotes/1.9.5.txt[1.9.5],
link:RelNotes/1.9.4.txt[1.9.4],
link:RelNotes/1.9.3.txt[1.9.3],
link:RelNotes/1.9.2.txt[1.9.2],
link:RelNotes/1.9.1.txt[1.9.1],
link:RelNotes/1.9.0.txt[1.9.0].
-* link:v1.8.5.5/git.html[documentation for release 1.8.5.5]
+* link:v1.8.5.6/git.html[documentation for release 1.8.5.6]
* release notes for
+ link:RelNotes/1.8.5.6.txt[1.8.5.6],
link:RelNotes/1.8.5.5.txt[1.8.5.5],
link:RelNotes/1.8.5.4.txt[1.8.5.4],
link:RelNotes/1.8.5.3.txt[1.8.5.3],
@@ -908,6 +920,10 @@ for further details.
and read the password from its STDOUT. See also the 'core.askpass'
option in linkgit:git-config[1].
+'GIT_TERMINAL_PROMPT'::
+ If this environment variable is set to `0`, git will not prompt
+ on the terminal (e.g., when asking for HTTP authentication).
+
'GIT_CONFIG_NOSYSTEM'::
Whether to skip reading settings from the system-wide
`$(prefix)/etc/gitconfig` file. This environment variable can
diff --git a/Documentation/githooks.txt b/Documentation/githooks.txt
index 9ef2469..7ba0ac9 100644
--- a/Documentation/githooks.txt
+++ b/Documentation/githooks.txt
@@ -341,6 +341,36 @@ Both standard output and standard error output are forwarded to
'git send-pack' on the other end, so you can simply `echo` messages
for the user.
+push-to-checkout
+~~~~~~~~~~~~~~~~
+
+This hook is invoked by 'git-receive-pack' on the remote repository,
+which happens when a 'git push' is done on a local repository, when
+the push tries to update the branch that is currently checked out
+and the `receive.denyCurrentBranch` configuration variable is set to
+`updateInstead`. Such a push by default is refused if the working
+tree and the index of the remote repository has any difference from
+the currently checked out commit; when both the working tree and the
+index match the current commit, they are updated to match the newly
+pushed tip of the branch. This hook is to be used to override the
+default behaviour.
+
+The hook receives the commit with which the tip of the current
+branch is going to be updated. It can exit with a non-zero status
+to refuse the push (when it does so, it must not modify the index or
+the working tree). Or it can make any necessary changes to the
+working tree and to the index to bring them to the desired state
+when the tip of the current branch is updated to the new commit, and
+exit with a zero status.
+
+For example, the hook can simply run `git read-tree -u -m HEAD "$1"`
+in order to emulate 'git fetch' that is run in the reverse direction
+with `git push`, as the two-tree form of `read-tree -u -m` is
+essentially the same as `git checkout` that switches branches while
+keeping the local changes in the working tree that do not interfere
+with the difference between the branches.
+
+
pre-auto-gc
~~~~~~~~~~~
diff --git a/Documentation/gitignore.txt b/Documentation/gitignore.txt
index 09e82c3..4fd0442 100644
--- a/Documentation/gitignore.txt
+++ b/Documentation/gitignore.txt
@@ -138,9 +138,6 @@ NOTES
The purpose of gitignore files is to ensure that certain files
not tracked by Git remain untracked.
-To ignore uncommitted changes in a file that is already tracked,
-use 'git update-index {litdd}assume-unchanged'.
-
To stop tracking a file that is currently tracked, use
'git rm --cached'.
@@ -203,7 +200,6 @@ everything within `foo/bar`):
SEE ALSO
--------
linkgit:git-rm[1],
-linkgit:git-update-index[1],
linkgit:gitrepository-layout[5],
linkgit:git-check-ignore[1]
diff --git a/Documentation/pretty-options.txt b/Documentation/pretty-options.txt
index 8569e29..74aa01a 100644
--- a/Documentation/pretty-options.txt
+++ b/Documentation/pretty-options.txt
@@ -3,9 +3,13 @@
Pretty-print the contents of the commit logs in a given format,
where '<format>' can be one of 'oneline', 'short', 'medium',
- 'full', 'fuller', 'email', 'raw' and 'format:<string>'. See
- the "PRETTY FORMATS" section for some additional details for each
- format. When omitted, the format defaults to 'medium'.
+ 'full', 'fuller', 'email', 'raw', 'format:<string>'
+ and 'tformat:<string>'. When '<format>' is none of the above,
+ and has '%placeholder' in it, it acts as if
+ '--pretty=tformat:<format>' were given.
++
+See the "PRETTY FORMATS" section for some additional details for each
+format. When '=<format>' part is omitted, it defaults to 'medium'.
+
Note: you can specify the default pretty format in the repository
configuration (see linkgit:git-config[1]).
diff --git a/Documentation/rev-list-options.txt b/Documentation/rev-list-options.txt
index afccfdc..4ed8587 100644
--- a/Documentation/rev-list-options.txt
+++ b/Documentation/rev-list-options.txt
@@ -66,6 +66,10 @@ if it is part of the log message.
Limit the commits output to ones that match all given `--grep`,
instead of ones that match at least one.
+--invert-grep::
+ Limit the commits output to ones with log message that do not
+ match the pattern specified with `--grep=<pattern>`.
+
-i::
--regexp-ignore-case::
Match the regular expression limiting patterns without regard to letter
@@ -172,11 +176,6 @@ explicitly.
Pretend as if all objects mentioned by reflogs are listed on the
command line as `<commit>`.
---indexed-objects::
- Pretend as if all trees and blobs used by the index are listed
- on the command line. Note that you probably want to use
- `--objects`, too.
-
--ignore-missing::
Upon seeing an invalid object name in the input, pretend as if
the bad input was not given.
@@ -644,6 +643,7 @@ Object Traversal
These options are mostly targeted for packing of Git repositories.
+ifdef::git-rev-list[]
--objects::
Print the object IDs of any object referenced by the listed
commits. `--objects foo ^bar` thus means ``send me
@@ -653,13 +653,24 @@ These options are mostly targeted for packing of Git repositories.
--objects-edge::
Similar to `--objects`, but also print the IDs of excluded
commits prefixed with a ``-'' character. This is used by
- linkgit:git-pack-objects[1] to build ``thin'' pack, which records
+ linkgit:git-pack-objects[1] to build a ``thin'' pack, which records
objects in deltified form based on objects contained in these
excluded commits to reduce network traffic.
+--objects-edge-aggressive::
+ Similar to `--objects-edge`, but it tries harder to find excluded
+ commits at the cost of increased time. This is used instead of
+ `--objects-edge` to build ``thin'' packs for shallow repositories.
+
+--indexed-objects::
+ Pretend as if all trees and blobs used by the index are listed
+ on the command line. Note that you probably want to use
+ `--objects`, too.
+
--unpacked::
Only useful with `--objects`; print the object IDs that are not
in packs.
+endif::git-rev-list[]
--no-walk[=(sorted|unsorted)]::
Only show the given commits, but do not traverse their ancestors.
diff --git a/Documentation/technical/api-credentials.txt b/Documentation/technical/api-credentials.txt
index c1b42a4..e44426d 100644
--- a/Documentation/technical/api-credentials.txt
+++ b/Documentation/technical/api-credentials.txt
@@ -248,7 +248,10 @@ FORMAT` in linkgit:git-credential[7] for a detailed specification).
For a `get` operation, the helper should produce a list of attributes
on stdout in the same format. A helper is free to produce a subset, or
even no values at all if it has nothing useful to provide. Any provided
-attributes will overwrite those already known about by Git.
+attributes will overwrite those already known about by Git. If a helper
+outputs a `quit` attribute with a value of `true` or `1`, no further
+helpers will be consulted, nor will the user be prompted (if no
+credential has been provided, the operation will then fail).
For a `store` or `erase` operation, the helper's output is ignored.
If it fails to perform the requested operation, it may complain to
diff --git a/Documentation/technical/api-error-handling.txt b/Documentation/technical/api-error-handling.txt
new file mode 100644
index 0000000..fc68db1
--- /dev/null
+++ b/Documentation/technical/api-error-handling.txt
@@ -0,0 +1,75 @@
+Error reporting in git
+======================
+
+`die`, `usage`, `error`, and `warning` report errors of various
+kinds.
+
+- `die` is for fatal application errors. It prints a message to
+ the user and exits with status 128.
+
+- `usage` is for errors in command line usage. After printing its
+ message, it exits with status 129. (See also `usage_with_options`
+ in the link:api-parse-options.html[parse-options API].)
+
+- `error` is for non-fatal library errors. It prints a message
+ to the user and returns -1 for convenience in signaling the error
+ to the caller.
+
+- `warning` is for reporting situations that probably should not
+ occur but which the user (and Git) can continue to work around
+ without running into too many problems. Like `error`, it
+ returns -1 after reporting the situation to the caller.
+
+Customizable error handlers
+---------------------------
+
+The default behavior of `die` and `error` is to write a message to
+stderr and then exit or return as appropriate. This behavior can be
+overridden using `set_die_routine` and `set_error_routine`. For
+example, "git daemon" uses set_die_routine to write the reason `die`
+was called to syslog before exiting.
+
+Library errors
+--------------
+
+Functions return a negative integer on error. Details beyond that
+vary from function to function:
+
+- Some functions return -1 for all errors. Others return a more
+ specific value depending on how the caller might want to react
+ to the error.
+
+- Some functions report the error to stderr with `error`,
+ while others leave that for the caller to do.
+
+- errno is not meaningful on return from most functions (except
+ for thin wrappers for system calls).
+
+Check the function's API documentation to be sure.
+
+Caller-handled errors
+---------------------
+
+An increasing number of functions take a parameter 'struct strbuf *err'.
+On error, such functions append a message about what went wrong to the
+'err' strbuf. The message is meant to be complete enough to be passed
+to `die` or `error` as-is. For example:
+
+ if (ref_transaction_commit(transaction, &err))
+ die("%s", err.buf);
+
+The 'err' parameter will be untouched if no error occured, so multiple
+function calls can be chained:
+
+ t = ref_transaction_begin(&err);
+ if (!t ||
+ ref_transaction_update(t, "HEAD", ..., &err) ||
+ ret_transaction_commit(t, &err))
+ die("%s", err.buf);
+
+The 'err' parameter must be a pointer to a valid strbuf. To silence
+a message, pass a strbuf that is explicitly ignored:
+
+ if (thing_that_can_fail_in_an_ignorable_way(..., &err))
+ /* This failure is okay. */
+ strbuf_reset(&err);
diff --git a/Documentation/technical/api-string-list.txt b/Documentation/technical/api-string-list.txt
index d51a657..c08402b 100644
--- a/Documentation/technical/api-string-list.txt
+++ b/Documentation/technical/api-string-list.txt
@@ -29,7 +29,7 @@ member (you need this if you add things later) and you should set the
`unsorted_string_list_has_string` and get it from the list using
`string_list_lookup` for sorted lists.
-. Can sort an unsorted list using `sort_string_list`.
+. Can sort an unsorted list using `string_list_sort`.
. Can remove duplicate items from a sorted list using
`string_list_remove_duplicates`.
@@ -146,7 +146,7 @@ write `string_list_insert(...)->util = ...;`.
ownership of a malloc()ed string to a `string_list` that has
`strdup_string` set.
-`sort_string_list`::
+`string_list_sort`::
Sort the list's entries by string value in `strcmp()` order.
diff --git a/Documentation/technical/index-format.txt b/Documentation/technical/index-format.txt
index 1250b5c..35112e4 100644
--- a/Documentation/technical/index-format.txt
+++ b/Documentation/technical/index-format.txt
@@ -207,7 +207,7 @@ Git index format
in a separate file. This extension records the changes to be made on
top of that to produce the final index.
- The signature for this extension is { 'l', 'i, 'n', 'k' }.
+ The signature for this extension is { 'l', 'i', 'n', 'k' }.
The extension consists of:
diff --git a/Documentation/technical/protocol-capabilities.txt b/Documentation/technical/protocol-capabilities.txt
index 6d5424c..4f8a7bf 100644
--- a/Documentation/technical/protocol-capabilities.txt
+++ b/Documentation/technical/protocol-capabilities.txt
@@ -18,8 +18,9 @@ was sent. Server MUST NOT ignore capabilities that client requested
and server advertised. As a consequence of these rules, server MUST
NOT advertise capabilities it does not understand.
-The 'report-status', 'delete-refs', 'quiet', and 'push-cert' capabilities
-are sent and recognized by the receive-pack (push to server) process.
+The 'atomic', 'report-status', 'delete-refs', 'quiet', and 'push-cert'
+capabilities are sent and recognized by the receive-pack (push to server)
+process.
The 'ofs-delta' and 'side-band-64k' capabilities are sent and recognized
by both upload-pack and receive-pack protocols. The 'agent' capability
@@ -244,6 +245,14 @@ respond with the 'quiet' capability to suppress server-side progress
reporting if the local progress reporting is also being suppressed
(e.g., via `push -q`, or if stderr does not go to a tty).
+atomic
+------
+
+If the server sends the 'atomic' capability it is capable of accepting
+atomic pushes. If the pushing client requests this capability, the server
+will update the refs in one atomic transaction. Either all refs are
+updated or none.
+
allow-tip-sha1-in-want
----------------------
diff --git a/GIT-VERSION-GEN b/GIT-VERSION-GEN
index 53dd6b3..0407788 100755
--- a/GIT-VERSION-GEN
+++ b/GIT-VERSION-GEN
@@ -1,7 +1,7 @@
#!/bin/sh
GVF=GIT-VERSION-FILE
-DEF_VER=v2.2.0.GIT
+DEF_VER=v2.3.1
LF='
'
diff --git a/INSTALL b/INSTALL
index 6ec7a24..ffb071e 100644
--- a/INSTALL
+++ b/INSTALL
@@ -108,18 +108,21 @@ Issues of note:
so you might need to install additional packages other than Perl
itself, e.g. Time::HiRes.
- - "openssl" library is used by git-imap-send to use IMAP over SSL.
- If you don't need it, use NO_OPENSSL.
+ - git-imap-send needs the OpenSSL library to talk IMAP over SSL if
+ you are using libcurl older than 7.34.0. Otherwise you can use
+ NO_OPENSSL without losing git-imap-send.
By default, git uses OpenSSL for SHA1 but it will use its own
library (inspired by Mozilla's) with either NO_OPENSSL or
BLK_SHA1. Also included is a version optimized for PowerPC
(PPC_SHA1).
- - "libcurl" library is used by git-http-fetch and git-fetch. You
- might also want the "curl" executable for debugging purposes.
- If you do not use http:// or https:// repositories, you do not
- have to have them (use NO_CURL).
+ - "libcurl" library is used by git-http-fetch, git-fetch, and, if
+ the curl version >= 7.34.0, for git-imap-send. You might also
+ want the "curl" executable for debugging purposes. If you do not
+ use http:// or https:// repositories, and do not want to put
+ patches into an IMAP mailbox, you do not have to have them
+ (use NO_CURL).
- "expat" library; git-http-push uses it for remote lock
management over DAV. Similar to "curl" above, this is optional
diff --git a/Makefile b/Makefile
index 7482a4d..44f1dd1 100644
--- a/Makefile
+++ b/Makefile
@@ -191,6 +191,10 @@ all::
# Define NO_TRUSTABLE_FILEMODE if your filesystem may claim to support
# the executable mode bit, but doesn't really do so.
#
+# Define NEEDS_MODE_TRANSLATION if your OS strays from the typical file type
+# bits in mode values (e.g. z/OS defines I_SFMT to 0xFF000000 as opposed to the
+# usual 0xF000).
+#
# Define NO_IPV6 if you lack IPv6 support and getaddrinfo().
#
# Define NO_UNIX_SOCKETS if your system does not offer unix sockets.
@@ -339,6 +343,20 @@ all::
# return NULL when it receives a bogus time_t.
#
# Define HAVE_CLOCK_GETTIME if your platform has clock_gettime in librt.
+#
+# Define HAVE_CLOCK_MONOTONIC if your platform has CLOCK_MONOTONIC in librt.
+#
+# Define NO_HMAC_CTX_CLEANUP if your OpenSSL is version 0.9.6b or earlier to
+# cleanup the HMAC context with the older HMAC_cleanup function.
+#
+# Define USE_PARENS_AROUND_GETTEXT_N to "yes" if your compiler happily
+# compiles the following initialization:
+#
+# static const char s[] = ("FOO");
+#
+# and define it to "no" if you need to remove the parentheses () around the
+# constant. The default is "auto", which means to use parentheses if your
+# compiler is detected to support it.
GIT-VERSION-FILE: FORCE
@$(SHELL_PATH) ./GIT-VERSION-GEN
@@ -946,6 +964,14 @@ ifneq (,$(SOCKLEN_T))
BASIC_CFLAGS += -Dsocklen_t=$(SOCKLEN_T)
endif
+ifeq (yes,$(USE_PARENS_AROUND_GETTEXT_N))
+ BASIC_CFLAGS += -DUSE_PARENS_AROUND_GETTEXT_N=1
+else
+ifeq (no,$(USE_PARENS_AROUND_GETTEXT_N))
+ BASIC_CFLAGS += -DUSE_PARENS_AROUND_GETTEXT_N=0
+endif
+endif
+
ifeq ($(uname_S),Darwin)
ifndef NO_FINK
ifeq ($(shell test -d /sw/lib && echo y),y)
@@ -995,6 +1021,9 @@ ifdef HAVE_ALLOCA_H
BASIC_CFLAGS += -DHAVE_ALLOCA_H
endif
+IMAP_SEND_BUILDDEPS =
+IMAP_SEND_LDFLAGS = $(OPENSSL_LINK) $(OPENSSL_LIBSSL) $(LIB_4_CRYPTO)
+
ifdef NO_CURL
BASIC_CFLAGS += -DNO_CURL
REMOTE_CURL_PRIMARY =
@@ -1023,12 +1052,21 @@ else
REMOTE_CURL_NAMES = $(REMOTE_CURL_PRIMARY) $(REMOTE_CURL_ALIASES)
PROGRAM_OBJS += http-fetch.o
PROGRAMS += $(REMOTE_CURL_NAMES)
- curl_check := $(shell (echo 070908; curl-config --vernum) 2>/dev/null | sort -r | sed -ne 2p)
+ curl_check := $(shell (echo 070908; curl-config --vernum | sed -e '/^70[BC]/s/^/0/') 2>/dev/null | sort -r | sed -ne 2p)
ifeq "$(curl_check)" "070908"
ifndef NO_EXPAT
PROGRAM_OBJS += http-push.o
endif
endif
+ curl_check := $(shell (echo 072200; curl-config --vernum | sed -e '/^70[BC]/s/^/0/') 2>/dev/null | sort -r | sed -ne 2p)
+ ifeq "$(curl_check)" "072200"
+ USE_CURL_FOR_IMAP_SEND = YesPlease
+ endif
+ ifdef USE_CURL_FOR_IMAP_SEND
+ BASIC_CFLAGS += -DUSE_CURL_FOR_IMAP_SEND
+ IMAP_SEND_BUILDDEPS = http.o
+ IMAP_SEND_LDFLAGS += $(CURL_LIBCURL)
+ endif
ifndef NO_EXPAT
ifdef EXPATDIR
BASIC_CFLAGS += -I$(EXPATDIR)/include
@@ -1059,6 +1097,9 @@ ifndef NO_OPENSSL
ifdef NEEDS_CRYPTO_WITH_SSL
OPENSSL_LIBSSL += -lcrypto
endif
+ ifdef NO_HMAC_CTX_CLEANUP
+ BASIC_CFLAGS += -DNO_HMAC_CTX_CLEANUP
+ endif
else
BASIC_CFLAGS += -DNO_OPENSSL
BLK_SHA1 = 1
@@ -1230,6 +1271,10 @@ endif
ifdef NO_TRUSTABLE_FILEMODE
BASIC_CFLAGS += -DNO_TRUSTABLE_FILEMODE
endif
+ifdef NEEDS_MODE_TRANSLATION
+ COMPAT_CFLAGS += -DNEEDS_MODE_TRANSLATION
+ COMPAT_OBJS += compat/stat.o
+endif
ifdef NO_IPV6
BASIC_CFLAGS += -DNO_IPV6
endif
@@ -1382,6 +1427,10 @@ ifdef HAVE_CLOCK_GETTIME
EXTLIBS += -lrt
endif
+ifdef HAVE_CLOCK_MONOTONIC
+ BASIC_CFLAGS += -DHAVE_CLOCK_MONOTONIC
+endif
+
ifeq ($(TCLTK_PATH),)
NO_TCLTK = NoThanks
endif
@@ -1880,7 +1929,7 @@ gettext.sp gettext.s gettext.o: GIT-PREFIX
gettext.sp gettext.s gettext.o: EXTRA_CPPFLAGS = \
-DGIT_LOCALE_PATH='"$(localedir_SQ)"'
-http-push.sp http.sp http-walker.sp remote-curl.sp: SPARSE_FLAGS += \
+http-push.sp http.sp http-walker.sp remote-curl.sp imap-send.sp: SPARSE_FLAGS += \
-DCURL_DISABLE_TYPECHECK
ifdef NO_EXPAT
@@ -1901,9 +1950,9 @@ endif
git-%$X: %.o GIT-LDFLAGS $(GITLIBS)
$(QUIET_LINK)$(CC) $(ALL_CFLAGS) -o $@ $(ALL_LDFLAGS) $(filter %.o,$^) $(LIBS)
-git-imap-send$X: imap-send.o GIT-LDFLAGS $(GITLIBS)
+git-imap-send$X: imap-send.o $(IMAP_SEND_BUILDDEPS) GIT-LDFLAGS $(GITLIBS)
$(QUIET_LINK)$(CC) $(ALL_CFLAGS) -o $@ $(ALL_LDFLAGS) $(filter %.o,$^) \
- $(LIBS) $(OPENSSL_LINK) $(OPENSSL_LIBSSL) $(LIB_4_CRYPTO)
+ $(LIBS) $(IMAP_SEND_LDFLAGS)
git-http-fetch$X: http.o http-walker.o http-fetch.o GIT-LDFLAGS $(GITLIBS)
$(QUIET_LINK)$(CC) $(ALL_CFLAGS) -o $@ $(ALL_LDFLAGS) $(filter %.o,$^) \
diff --git a/RelNotes b/RelNotes
index 9257c74..8dae3d4 120000..100644
--- a/RelNotes
+++ b/RelNotes
@@ -1 +1,171 @@
-Documentation/RelNotes/2.3.0.txt \ No newline at end of file
+Git ???? Release Notes
+======================
+
+Updates since v2.3
+------------------
+
+Ports
+
+
+UI, Workflows & Features
+
+ * The command usage info strings given by "git cmd -h" and in
+ documentation have been tweaked for consistency.
+
+ * The "sync" subcommand of "git p4" now allows users to exclude
+ subdirectories like its "clone" subcommand does.
+
+ * "git log --invert-grep --grep=WIP" will show only commits that do
+ not have the string "WIP" in their messages.
+
+ * "git push" has been taught a "--atomic" option that makes push to
+ update more than one ref an "all-or-none" affair.
+
+ * Extending the "push to deploy" added in 2.3, the behaviour of "git
+ push" when updating the branch that is checked out can now be
+ tweaked by push-to-checkout hook.
+
+ * Using environment variable LANGUAGE and friends on the client side,
+ HTTP-based transports now send Accept-Language when making requests.
+
+
+Performance, Internal Implementation, Development Support etc.
+
+ * Implementation of N_() macro has been updated slightly to help us
+ detect mistakes.
+
+ * Implementation of "reflog expire" has been restructured to fit the
+ reflogs better with the recently updated ref API.
+
+
+Also contains various documentation updates and code clean-ups.
+
+
+Fixes since v2.3
+----------------
+
+Unless otherwise noted, all the fixes since v2.3 in the maintenance
+track are contained in this release (see the maintenance releases'
+notes for details).
+
+ * "git blame HEAD -- missing" failed to correctly say "HEAD" when it
+ tried to say "No such path 'missing' in HEAD".
+ (merge a46442f jk/blame-commit-label later to maint).
+
+ * "git rerere" (invoked internally from many mergy operations) did
+ not correctly signal errors when told to update the working tree
+ files and failed to do so for whatever reason.
+ (merge 89ea903 jn/rerere-fail-on-auto-update-failure later to maint).
+
+ * Setting diff.submodule to 'log' made "git format-patch" produce
+ broken patches.
+ (merge 339de50 dk/format-patch-ignore-diff-submodule later to maint).
+
+ * After attempting and failing a password-less authentication
+ (e.g. kerberos), libcURL refuses to fall back to password based
+ Basic authentication without a bit of help/encouragement.
+ (merge 4dbe664 bc/http-fallback-to-password-after-krb-fails later to maint).
+
+ * The "git push" documentation made the "--repo=<there>" option
+ easily misunderstood.
+ (merge 57b92a7 mg/push-repo-option-doc later to maint).
+
+ * Code to read branch name from various files in .git/ directory
+ would have misbehaved if the code to write them left an empty file.
+ (merge 66ec904 jk/status-read-branch-name-fix later to maint).
+
+ * A misspelled conditional that is always true has been fixed.
+ (merge 94ee8e2 jk/remote-curl-an-array-in-struct-cannot-be-null later to maint).
+
+ * The documentation incorrectly said that C(opy) and R(ename) are the
+ only ones that can be followed by the score number in the output in
+ the --raw format.
+ (merge ac1c2d9 jc/diff-format-doc later to maint).
+
+ * A broken pack .idx file in the receiving repository prevented the
+ dumb http transport from fetching a good copy of it from the other
+ side.
+ (merge 8b9c2dd jk/dumb-http-idx-fetch-fix later to maint).
+
+ * The error message from "git commit", when a non-existing author
+ name was given as value to the "--author=" parameter, has been
+ reworded to avoid misunderstanding.
+ (merge 1044b1f mg/commit-author-no-match-malformed-message later to maint).
+
+ * "git log --help" used to show rev-list options that are irrelevant
+ to the "log" command.
+ (merge 3cab02d jc/doc-log-rev-list-options later to maint).
+
+ * "git apply --whitespace=fix" used to under-allocate the memory when
+ the fix resulted in a longer text than the original patch.
+ (merge 407a792 jc/apply-ws-fix-expands later to maint).
+
+ * The interactive "show a list and let the user choose from it"
+ interface "add -i" used showed and prompted to the user even when
+ the candidate list was empty, against which the only "choice" the
+ user could have made was to choose nothing.
+ (merge a9c4641 ak/add-i-empty-candidates later to maint).
+
+ * The insn sheet "git rebase -i" creates did not fully honor
+ core.abbrev settings.
+ (merge edb72d5 ks/rebase-i-abbrev later to maint).
+
+ * "git fetch" over a remote-helper that cannot respond to "list"
+ command could not fetch from a symbolic reference e.g. HEAD.
+ (merge 33cae54 mh/deref-symref-over-helper-transport later to maint).
+
+ * "git push --signed" gave an incorrectly worded error message when
+ the other side did not support the capability.
+ (merge 45917f0 jc/push-cert later to maint).
+
+ * We didn't format an integer that wouldn't fit in "int" but in
+ "uintmax_t" correctly.
+ (merge d306f3d jk/decimal-width-for-uintmax later to maint).
+
+ * Reading configuration from a blob object, when it ends with a lone
+ CR, use to confuse the configuration parser.
+ (merge 1d0655c jk/config-no-ungetc-eof later to maint).
+
+ * The pack bitmap support did not build with older versions of GCC.
+ (merge bd4e882 jk/pack-bitmap later to maint).
+
+ * The documentation wasn't clear that "remote.<nick>.pushURL" and
+ "remote.<nick>.URL" are there to name the same repository accessed
+ via different transports, not two separate repositories.
+ (merge 697f652 jc/remote-set-url-doc later to maint).
+
+ * Older GnuPG implementations may not correctly import the keyring
+ material we prepare for the tests to use.
+ (merge 1f985d6 ch/new-gpg-drops-rfc-1991 later to maint).
+
+ * The credential helper for Windows (in contrib/) used to mishandle
+ a user name with an at-sign in it.
+ (merge 13d261e av/wincred-with-at-in-username-fix later to maint).
+
+ * Longstanding configuration variable naming rules has been added to
+ the documentation.
+ (merge 35840a3 jc/conf-var-doc later to maint).
+
+ * An earlier workaround to squelch unhelpful deprecation warnings
+ from the complier on Mac OSX unnecessarily set minimum required
+ version of the OS, which the user might want to raise (or lower)
+ for other reasons.
+ (merge 88c03eb es/squelch-openssl-warnings-on-macosx later to maint).
+
+ * Certain older vintages of cURL give irregular output from
+ "curl-config --vernum", which confused our build system.
+ (merge 3af6792 tc/curl-vernum-output-broken-in-7.11 later to maint).
+
+ * In v2.2.0, we broke "git prune" that runs in a repository that
+ borrows from an alternate object store.
+ (merge b0a4264 jk/prune-mtime later to maint).
+
+ * "git submodule add" failed to squash "path/to/././submodule" to
+ "path/to/submodule".
+ (merge 8196e72 ps/submodule-sanitize-path-upon-add later to maint).
+
+ * "git merge-file" did not work correctly in a subdirectory.
+ (merge 204a8ff ab/merge-file-prefix later to maint).
+
+ * "git blame" died, trying to free an uninitialized piece of memory.
+ (merge e600592 es/blame-commit-info-fix later to maint).
diff --git a/advice.c b/advice.c
index 3b8bf3c..575bec2 100644
--- a/advice.c
+++ b/advice.c
@@ -105,7 +105,7 @@ void detach_advice(const char *new_name)
"state without impacting any branches by performing another checkout.\n\n"
"If you want to create a new branch to retain commits you create, you may\n"
"do so (now or later) by using -b with the checkout command again. Example:\n\n"
- " git checkout -b new_branch_name\n\n";
+ " git checkout -b <new-branch-name>\n\n";
fprintf(stderr, fmt, new_name);
}
diff --git a/archive.c b/archive.c
index 94a9981..96057ed 100644
--- a/archive.c
+++ b/archive.c
@@ -8,9 +8,9 @@
#include "dir.h"
static char const * const archive_usage[] = {
- N_("git archive [options] <tree-ish> [<path>...]"),
+ N_("git archive [<options>] <tree-ish> [<path>...]"),
N_("git archive --list"),
- N_("git archive --remote <repo> [--exec <cmd>] [options] <tree-ish> [<path>...]"),
+ N_("git archive --remote <repo> [--exec <cmd>] [<options>] <tree-ish> [<path>...]"),
N_("git archive --remote <repo> [--exec <cmd>] --list"),
NULL
};
@@ -157,18 +157,26 @@ static int write_archive_entry(const unsigned char *sha1, const char *base,
return write_entry(args, sha1, path.buf, path.len, mode);
}
+static int write_archive_entry_buf(const unsigned char *sha1, struct strbuf *base,
+ const char *filename, unsigned mode, int stage,
+ void *context)
+{
+ return write_archive_entry(sha1, base->buf, base->len,
+ filename, mode, stage, context);
+}
+
static void queue_directory(const unsigned char *sha1,
- const char *base, int baselen, const char *filename,
+ struct strbuf *base, const char *filename,
unsigned mode, int stage, struct archiver_context *c)
{
struct directory *d;
- d = xmallocz(sizeof(*d) + baselen + 1 + strlen(filename));
+ d = xmallocz(sizeof(*d) + base->len + 1 + strlen(filename));
d->up = c->bottom;
- d->baselen = baselen;
+ d->baselen = base->len;
d->mode = mode;
d->stage = stage;
c->bottom = d;
- d->len = sprintf(d->path, "%.*s%s/", baselen, base, filename);
+ d->len = sprintf(d->path, "%.*s%s/", (int)base->len, base->buf, filename);
hashcpy(d->sha1, sha1);
}
@@ -191,28 +199,28 @@ static int write_directory(struct archiver_context *c)
}
static int queue_or_write_archive_entry(const unsigned char *sha1,
- const char *base, int baselen, const char *filename,
+ struct strbuf *base, const char *filename,
unsigned mode, int stage, void *context)
{
struct archiver_context *c = context;
while (c->bottom &&
- !(baselen >= c->bottom->len &&
- !strncmp(base, c->bottom->path, c->bottom->len))) {
+ !(base->len >= c->bottom->len &&
+ !strncmp(base->buf, c->bottom->path, c->bottom->len))) {
struct directory *next = c->bottom->up;
free(c->bottom);
c->bottom = next;
}
if (S_ISDIR(mode)) {
- queue_directory(sha1, base, baselen, filename,
+ queue_directory(sha1, base, filename,
mode, stage, c);
return READ_TREE_RECURSIVE;
}
if (write_directory(c))
return -1;
- return write_archive_entry(sha1, base, baselen, filename, mode,
+ return write_archive_entry(sha1, base->buf, base->len, filename, mode,
stage, context);
}
@@ -260,7 +268,7 @@ int write_archive_entries(struct archiver_args *args,
err = read_tree_recursive(args->tree, "", 0, 0, &args->pathspec,
args->pathspec.has_wildcard ?
queue_or_write_archive_entry :
- write_archive_entry,
+ write_archive_entry_buf,
&context);
if (err == READ_TREE_RECURSIVE)
err = 0;
@@ -286,14 +294,14 @@ static const struct archiver *lookup_archiver(const char *name)
return NULL;
}
-static int reject_entry(const unsigned char *sha1, const char *base,
- int baselen, const char *filename, unsigned mode,
+static int reject_entry(const unsigned char *sha1, struct strbuf *base,
+ const char *filename, unsigned mode,
int stage, void *context)
{
int ret = -1;
if (S_ISDIR(mode)) {
struct strbuf sb = STRBUF_INIT;
- strbuf_addstr(&sb, base);
+ strbuf_addbuf(&sb, base);
strbuf_addstr(&sb, filename);
if (!match_pathspec(context, sb.buf, sb.len, 0, NULL, 1))
ret = READ_TREE_RECURSIVE;
diff --git a/attr.c b/attr.c
index cd54697..1f9eebd 100644
--- a/attr.c
+++ b/attr.c
@@ -32,9 +32,12 @@ struct git_attr {
struct git_attr *next;
unsigned h;
int attr_nr;
+ int maybe_macro;
+ int maybe_real;
char name[FLEX_ARRAY];
};
static int attr_nr;
+static int cannot_trust_maybe_real;
static struct git_attr_check *check_all_attr;
static struct git_attr *(git_attr_hash[HASHSIZE]);
@@ -95,6 +98,8 @@ static struct git_attr *git_attr_internal(const char *name, int len)
a->h = hval;
a->next = git_attr_hash[pos];
a->attr_nr = attr_nr++;
+ a->maybe_macro = 0;
+ a->maybe_real = 0;
git_attr_hash[pos] = a;
REALLOC_ARRAY(check_all_attr, attr_nr);
@@ -244,9 +249,10 @@ static struct match_attr *parse_attr_line(const char *line, const char *src,
sizeof(*res) +
sizeof(struct attr_state) * num_attr +
(is_macro ? 0 : namelen + 1));
- if (is_macro)
+ if (is_macro) {
res->u.attr = git_attr_internal(name, namelen);
- else {
+ res->u.attr->maybe_macro = 1;
+ } else {
char *p = (char *)&(res->state[num_attr]);
memcpy(p, name, namelen);
res->u.pat.pattern = p;
@@ -266,6 +272,10 @@ static struct match_attr *parse_attr_line(const char *line, const char *src,
/* Second pass to fill the attr_states */
for (cp = states, i = 0; *cp; i++) {
cp = parse_attr(src, lineno, cp, &(res->state[i]));
+ if (!is_macro)
+ res->state[i].attr->maybe_real = 1;
+ if (res->state[i].attr->maybe_macro)
+ cannot_trust_maybe_real = 1;
}
return res;
@@ -681,13 +691,14 @@ static int fill(const char *path, int pathlen, int basename_offset,
return rem;
}
-static int macroexpand_one(int attr_nr, int rem)
+static int macroexpand_one(int nr, int rem)
{
struct attr_stack *stk;
struct match_attr *a = NULL;
int i;
- if (check_all_attr[attr_nr].value != ATTR__TRUE)
+ if (check_all_attr[nr].value != ATTR__TRUE ||
+ !check_all_attr[nr].attr->maybe_macro)
return rem;
for (stk = attr_stack; !a && stk; stk = stk->prev)
@@ -695,7 +706,7 @@ static int macroexpand_one(int attr_nr, int rem)
struct match_attr *ma = stk->attrs[i];
if (!ma->is_macro)
continue;
- if (ma->u.attr->attr_nr == attr_nr)
+ if (ma->u.attr->attr_nr == nr)
a = ma;
}
@@ -706,10 +717,13 @@ static int macroexpand_one(int attr_nr, int rem)
}
/*
- * Collect all attributes for path into the array pointed to by
- * check_all_attr.
+ * Collect attributes for path into the array pointed to by
+ * check_all_attr. If num is non-zero, only attributes in check[] are
+ * collected. Otherwise all attributes are collected.
*/
-static void collect_all_attrs(const char *path)
+static void collect_some_attrs(const char *path, int num,
+ struct git_attr_check *check)
+
{
struct attr_stack *stk;
int i, pathlen, rem, dirlen;
@@ -732,6 +746,19 @@ static void collect_all_attrs(const char *path)
prepare_attr_stack(path, dirlen);
for (i = 0; i < attr_nr; i++)
check_all_attr[i].value = ATTR__UNKNOWN;
+ if (num && !cannot_trust_maybe_real) {
+ rem = 0;
+ for (i = 0; i < num; i++) {
+ if (!check[i].attr->maybe_real) {
+ struct git_attr_check *c;
+ c = check_all_attr + check[i].attr->attr_nr;
+ c->value = ATTR__UNSET;
+ rem++;
+ }
+ }
+ if (rem == num)
+ return;
+ }
rem = attr_nr;
for (stk = attr_stack; 0 < rem && stk; stk = stk->prev)
@@ -742,7 +769,7 @@ int git_check_attr(const char *path, int num, struct git_attr_check *check)
{
int i;
- collect_all_attrs(path);
+ collect_some_attrs(path, num, check);
for (i = 0; i < num; i++) {
const char *value = check_all_attr[check[i].attr->attr_nr].value;
@@ -758,7 +785,7 @@ int git_all_attrs(const char *path, int *num, struct git_attr_check **check)
{
int i, count, j;
- collect_all_attrs(path);
+ collect_some_attrs(path, 0, NULL);
/* Count the number of attributes that are set. */
count = 0;
diff --git a/bisect.c b/bisect.c
index df09cbc..8c6d843 100644
--- a/bisect.c
+++ b/bisect.c
@@ -777,7 +777,7 @@ static void check_merge_bases(int no_checkout)
int rev_nr;
struct commit **rev = get_bad_and_good_commits(&rev_nr);
- result = get_merge_bases_many(rev[0], rev_nr - 1, rev + 1, 0);
+ result = get_merge_bases_many(rev[0], rev_nr - 1, rev + 1);
for (; result; result = result->next) {
const unsigned char *mb = result->item->object.sha1;
diff --git a/builtin/add.c b/builtin/add.c
index ae6d3e2..3390933 100644
--- a/builtin/add.c
+++ b/builtin/add.c
@@ -19,7 +19,7 @@
#include "argv-array.h"
static const char * const builtin_add_usage[] = {
- N_("git add [options] [--] <pathspec>..."),
+ N_("git add [<options>] [--] <pathspec>..."),
NULL
};
static int patch_interactive, add_interactive, edit_interactive;
@@ -284,7 +284,7 @@ static int add_files(struct dir_struct *dir, int flags)
for (i = 0; i < dir->ignored_nr; i++)
fprintf(stderr, "%s\n", dir->ignored[i]->name);
fprintf(stderr, _("Use -f if you really want to add them.\n"));
- die(_("no files added"));
+ exit_status = 1;
}
for (i = 0; i < dir->nr; i++)
diff --git a/builtin/apply.c b/builtin/apply.c
index 28d24f8..955cc79 100644
--- a/builtin/apply.c
+++ b/builtin/apply.c
@@ -55,7 +55,7 @@ static const char *fake_ancestor;
static int line_termination = '\n';
static unsigned int p_context = UINT_MAX;
static const char * const apply_usage[] = {
- N_("git apply [options] [<patch>...]"),
+ N_("git apply [<options>] [<patch>...]"),
NULL
};
@@ -657,11 +657,6 @@ static size_t diff_timestamp_len(const char *line, size_t len)
return line + len - end;
}
-static char *null_strdup(const char *s)
-{
- return s ? xstrdup(s) : NULL;
-}
-
static char *find_name_common(const char *line, const char *def,
int p_value, const char *end, int terminate)
{
@@ -684,10 +679,10 @@ static char *find_name_common(const char *line, const char *def,
start = line;
}
if (!start)
- return squash_slash(null_strdup(def));
+ return squash_slash(xstrdup_or_null(def));
len = line - start;
if (!len)
- return squash_slash(null_strdup(def));
+ return squash_slash(xstrdup_or_null(def));
/*
* Generally we prefer the shorter name, especially
@@ -909,7 +904,7 @@ static void parse_traditional_patch(const char *first, const char *second, struc
patch->old_name = name;
} else {
patch->old_name = name;
- patch->new_name = null_strdup(name);
+ patch->new_name = xstrdup_or_null(name);
}
}
if (!name)
@@ -998,7 +993,7 @@ static int gitdiff_delete(const char *line, struct patch *patch)
{
patch->is_delete = 1;
free(patch->old_name);
- patch->old_name = null_strdup(patch->def_name);
+ patch->old_name = xstrdup_or_null(patch->def_name);
return gitdiff_oldmode(line, patch);
}
@@ -1006,7 +1001,7 @@ static int gitdiff_newfile(const char *line, struct patch *patch)
{
patch->is_new = 1;
free(patch->new_name);
- patch->new_name = null_strdup(patch->def_name);
+ patch->new_name = xstrdup_or_null(patch->def_name);
return gitdiff_newmode(line, patch);
}
@@ -2235,6 +2230,12 @@ static void update_pre_post_images(struct image *preimage,
ctx++;
}
+ if (postlen
+ ? postlen < new - postimage->buf
+ : postimage->len < new - postimage->buf)
+ die("BUG: caller miscounted postlen: asked %d, orig = %d, used = %d",
+ (int)postlen, (int) postimage->len, (int)(new - postimage->buf));
+
/* Fix the length of the whole thing */
postimage->len = new - postimage->buf;
postimage->nr -= reduced;
@@ -2390,10 +2391,27 @@ static int match_fragment(struct image *img,
/*
* The hunk does not apply byte-by-byte, but the hash says
- * it might with whitespace fuzz. We haven't been asked to
+ * it might with whitespace fuzz. We weren't asked to
* ignore whitespace, we were asked to correct whitespace
* errors, so let's try matching after whitespace correction.
*
+ * While checking the preimage against the target, whitespace
+ * errors in both fixed, we count how large the corresponding
+ * postimage needs to be. The postimage prepared by
+ * apply_one_fragment() has whitespace errors fixed on added
+ * lines already, but the common lines were propagated as-is,
+ * which may become longer when their whitespace errors are
+ * fixed.
+ */
+
+ /* First count added lines in postimage */
+ postlen = 0;
+ for (i = 0; i < postimage->nr; i++) {
+ if (!(postimage->line[i].flag & LINE_COMMON))
+ postlen += postimage->line[i].len;
+ }
+
+ /*
* The preimage may extend beyond the end of the file,
* but in this loop we will only handle the part of the
* preimage that falls within the file.
@@ -2401,7 +2419,6 @@ static int match_fragment(struct image *img,
strbuf_init(&fixed, preimage->len + 1);
orig = preimage->buf;
target = img->buf + try;
- postlen = 0;
for (i = 0; i < preimage_limit; i++) {
size_t oldlen = preimage->line[i].len;
size_t tgtlen = img->line[try_lno + i].len;
@@ -2429,7 +2446,10 @@ static int match_fragment(struct image *img,
match = (tgtfix.len == fixed.len - fixstart &&
!memcmp(tgtfix.buf, fixed.buf + fixstart,
fixed.len - fixstart));
- postlen += tgtfix.len;
+
+ /* Add the length if this is common with the postimage */
+ if (preimage->line[i].flag & LINE_COMMON)
+ postlen += tgtfix.len;
strbuf_release(&tgtfix);
if (!match)
@@ -4180,7 +4200,7 @@ static int write_out_results(struct patch *list)
if (cpath.nr) {
struct string_list_item *item;
- sort_string_list(&cpath);
+ string_list_sort(&cpath);
for_each_string_list_item(item, &cpath)
fprintf(stderr, "U %s\n", item->string);
string_list_clear(&cpath, 0);
diff --git a/builtin/blame.c b/builtin/blame.c
index 303e217..06484c2 100644
--- a/builtin/blame.c
+++ b/builtin/blame.c
@@ -27,12 +27,12 @@
#include "line-range.h"
#include "line-log.h"
-static char blame_usage[] = N_("git blame [options] [rev-opts] [rev] [--] file");
+static char blame_usage[] = N_("git blame [<options>] [<rev-opts>] [<rev>] [--] file");
static const char *blame_opt_usage[] = {
blame_usage,
"",
- N_("[rev-opts] are documented in git-rev-list(1)"),
+ N_("<rev-opts> are documented in git-rev-list(1)"),
NULL
};
@@ -2085,7 +2085,6 @@ static void find_alignment(struct scoreboard *sb, int *option)
for (e = sb->ent; e; e = e->next) {
struct origin *suspect = e->suspect;
- struct commit_info ci;
int num;
if (compute_auto_abbrev)
@@ -2096,6 +2095,7 @@ static void find_alignment(struct scoreboard *sb, int *option)
if (longest_file < num)
longest_file = num;
if (!(suspect->commit->object.flags & METAINFO_SHOWN)) {
+ struct commit_info ci;
suspect->commit->object.flags |= METAINFO_SHOWN;
get_commit_info(suspect->commit, &ci, 1);
if (*option & OUTPUT_SHOW_EMAIL)
@@ -2104,6 +2104,7 @@ static void find_alignment(struct scoreboard *sb, int *option)
num = utf8_strwidth(ci.author.buf);
if (longest_author < num)
longest_author = num;
+ commit_info_destroy(&ci);
}
num = e->s_lno + e->num_lines;
if (longest_src_lines < num)
@@ -2113,8 +2114,6 @@ static void find_alignment(struct scoreboard *sb, int *option)
longest_dst_lines = num;
if (largest_score < ent_score(sb, e))
largest_score = ent_score(sb, e);
-
- commit_info_destroy(&ci);
}
max_orig_digits = decimal_width(longest_src_lines);
max_digits = decimal_width(longest_dst_lines);
@@ -2390,7 +2389,7 @@ static struct commit *fake_working_tree_commit(struct diff_options *opt,
return commit;
}
-static const char *prepare_final(struct scoreboard *sb)
+static char *prepare_final(struct scoreboard *sb)
{
int i;
const char *final_commit_name = NULL;
@@ -2415,10 +2414,10 @@ static const char *prepare_final(struct scoreboard *sb)
sb->final = (struct commit *) obj;
final_commit_name = revs->pending.objects[i].name;
}
- return final_commit_name;
+ return xstrdup_or_null(final_commit_name);
}
-static const char *prepare_initial(struct scoreboard *sb)
+static char *prepare_initial(struct scoreboard *sb)
{
int i;
const char *final_commit_name = NULL;
@@ -2445,7 +2444,7 @@ static const char *prepare_initial(struct scoreboard *sb)
}
if (!final_commit_name)
die("No commit to dig down to?");
- return final_commit_name;
+ return xstrdup(final_commit_name);
}
static int blame_copy_callback(const struct option *option, const char *arg, int unset)
@@ -2489,7 +2488,7 @@ int cmd_blame(int argc, const char **argv, const char *prefix)
struct origin *o;
struct blame_entry *ent = NULL;
long dashdash_pos, lno;
- const char *final_commit_name = NULL;
+ char *final_commit_name = NULL;
enum object_type type;
static struct string_list range_list;
@@ -2786,6 +2785,8 @@ parse_done:
assign_blame(&sb, opt);
+ free(final_commit_name);
+
if (incremental)
return 0;
diff --git a/builtin/branch.c b/builtin/branch.c
index 3b79c50..6a25957 100644
--- a/builtin/branch.c
+++ b/builtin/branch.c
@@ -21,10 +21,10 @@
#include "wt-status.h"
static const char * const builtin_branch_usage[] = {
- N_("git branch [options] [-r | -a] [--merged | --no-merged]"),
- N_("git branch [options] [-l] [-f] <branchname> [<start-point>]"),
- N_("git branch [options] [-r] (-d | -D) <branchname>..."),
- N_("git branch [options] (-m | -M) [<oldbranch>] <newbranch>"),
+ N_("git branch [<options>] [-r | -a] [--merged | --no-merged]"),
+ N_("git branch [<options>] [-l] [-f] <branch-name> [<start-point>]"),
+ N_("git branch [<options>] [-r] (-d | -D) <branch-name>..."),
+ N_("git branch [<options>] (-m | -M) [<old-branch>] <new-branch>"),
NULL
};
@@ -800,7 +800,7 @@ static int edit_branch_description(const char *branch_name)
int cmd_branch(int argc, const char **argv, const char *prefix)
{
- int delete = 0, rename = 0, force_create = 0, list = 0;
+ int delete = 0, rename = 0, force = 0, list = 0;
int verbose = 0, abbrev = -1, detached = 0;
int reflog = 0, edit_description = 0;
int quiet = 0, unset_upstream = 0;
@@ -848,7 +848,7 @@ int cmd_branch(int argc, const char **argv, const char *prefix)
OPT_BOOL('l', "create-reflog", &reflog, N_("create the branch's reflog")),
OPT_BOOL(0, "edit-description", &edit_description,
N_("edit the description for the branch")),
- OPT__FORCE(&force_create, N_("force creation (when already exists)")),
+ OPT__FORCE(&force, N_("force creation, move/rename, deletion")),
{
OPTION_CALLBACK, 0, "no-merged", &merge_filter_ref,
N_("commit"), N_("print only not merged branches"),
@@ -891,7 +891,7 @@ int cmd_branch(int argc, const char **argv, const char *prefix)
if (with_commit || merge_filter != NO_FILTER)
list = 1;
- if (!!delete + !!rename + !!force_create + !!new_upstream +
+ if (!!delete + !!rename + !!new_upstream +
list + unset_upstream > 1)
usage_with_options(builtin_branch_usage, options);
@@ -904,6 +904,11 @@ int cmd_branch(int argc, const char **argv, const char *prefix)
colopts = 0;
}
+ if (force) {
+ delete *= 2;
+ rename *= 2;
+ }
+
if (delete) {
if (!argc)
die(_("branch name required"));
@@ -1020,7 +1025,7 @@ int cmd_branch(int argc, const char **argv, const char *prefix)
branch_existed = ref_exists(branch->refname);
create_branch(head, argv[0], (argc == 2) ? argv[1] : head,
- force_create, reflog, 0, quiet, track);
+ force, reflog, 0, quiet, track);
/*
* We only show the instructions if the user gave us
diff --git a/builtin/cat-file.c b/builtin/cat-file.c
index f8d8129..df99df4 100644
--- a/builtin/cat-file.c
+++ b/builtin/cat-file.c
@@ -4,12 +4,8 @@
* Copyright (C) Linus Torvalds, 2005
*/
#include "cache.h"
-#include "exec_cmd.h"
-#include "tag.h"
-#include "tree.h"
#include "builtin.h"
#include "parse-options.h"
-#include "diff.h"
#include "userdiff.h"
#include "streaming.h"
@@ -79,8 +75,6 @@ static int cat_one_file(int opt, const char *exp_type, const char *obj_name)
if (type_from_string(exp_type) == OBJ_BLOB) {
unsigned char blob_sha1[20];
if (sha1_object_info(sha1, NULL) == OBJ_TAG) {
- enum object_type type;
- unsigned long size;
char *buffer = read_sha1_file(sha1, &type, &size);
const char *target;
if (!skip_prefix(buffer, "object ", &target) ||
@@ -329,8 +323,8 @@ static int batch_objects(struct batch_options *opt)
}
static const char * const cat_file_usage[] = {
- N_("git cat-file (-t|-s|-e|-p|<type>|--textconv) <object>"),
- N_("git cat-file (--batch|--batch-check) < <list_of_objects>"),
+ N_("git cat-file (-t | -s | -e | -p | <type> | --textconv) <object>"),
+ N_("git cat-file (--batch | --batch-check) < <list-of-objects>"),
NULL
};
diff --git a/builtin/check-attr.c b/builtin/check-attr.c
index 5600ec3..21d2bed 100644
--- a/builtin/check-attr.c
+++ b/builtin/check-attr.c
@@ -8,8 +8,8 @@ static int all_attrs;
static int cached_attrs;
static int stdin_paths;
static const char * const check_attr_usage[] = {
-N_("git check-attr [-a | --all | attr...] [--] pathname..."),
-N_("git check-attr --stdin [-z] [-a | --all | attr...] < <list-of-paths>"),
+N_("git check-attr [-a | --all | <attr>...] [--] <pathname>..."),
+N_("git check-attr --stdin [-z] [-a | --all | <attr>...] < <list-of-paths>"),
NULL
};
diff --git a/builtin/check-ignore.c b/builtin/check-ignore.c
index 594463a..dc8d97c 100644
--- a/builtin/check-ignore.c
+++ b/builtin/check-ignore.c
@@ -7,8 +7,8 @@
static int quiet, verbose, stdin_paths, show_non_matching, no_index;
static const char * const check_ignore_usage[] = {
-"git check-ignore [options] pathname...",
-"git check-ignore [options] --stdin < <list-of-paths>",
+"git check-ignore [<options>] <pathname>...",
+"git check-ignore [<options>] --stdin < <list-of-paths>",
NULL
};
diff --git a/builtin/check-mailmap.c b/builtin/check-mailmap.c
index 8f4d809..eaaea54 100644
--- a/builtin/check-mailmap.c
+++ b/builtin/check-mailmap.c
@@ -5,7 +5,7 @@
static int use_stdin;
static const char * const check_mailmap_usage[] = {
-N_("git check-mailmap [options] <contact>..."),
+N_("git check-mailmap [<options>] <contact>..."),
NULL
};
diff --git a/builtin/check-ref-format.c b/builtin/check-ref-format.c
index 28a7320..fd915d5 100644
--- a/builtin/check-ref-format.c
+++ b/builtin/check-ref-format.c
@@ -8,7 +8,7 @@
#include "strbuf.h"
static const char builtin_check_ref_format_usage[] =
-"git check-ref-format [--normalize] [options] <refname>\n"
+"git check-ref-format [--normalize] [<options>] <refname>\n"
" or: git check-ref-format --branch <branchname-shorthand>";
/*
diff --git a/builtin/checkout-index.c b/builtin/checkout-index.c
index 383dccf..9ca2da1 100644
--- a/builtin/checkout-index.c
+++ b/builtin/checkout-index.c
@@ -18,7 +18,7 @@ static char topath[4][TEMPORARY_FILENAME_LENGTH + 1];
static struct checkout state;
-static void write_tempfile_record(const char *name, int prefix_length)
+static void write_tempfile_record(const char *name, const char *prefix)
{
int i;
@@ -35,14 +35,14 @@ static void write_tempfile_record(const char *name, int prefix_length)
fputs(topath[checkout_stage], stdout);
putchar('\t');
- write_name_quoted(name + prefix_length, stdout, line_termination);
+ write_name_quoted_relative(name, prefix, stdout, line_termination);
for (i = 0; i < 4; i++) {
topath[i][0] = 0;
}
}
-static int checkout_file(const char *name, int prefix_length)
+static int checkout_file(const char *name, const char *prefix)
{
int namelen = strlen(name);
int pos = cache_name_pos(name, namelen);
@@ -71,7 +71,7 @@ static int checkout_file(const char *name, int prefix_length)
if (did_checkout) {
if (to_tempfile)
- write_tempfile_record(name, prefix_length);
+ write_tempfile_record(name, prefix);
return errs > 0 ? -1 : 0;
}
@@ -106,7 +106,7 @@ static void checkout_all(const char *prefix, int prefix_length)
if (last_ce && to_tempfile) {
if (ce_namelen(last_ce) != ce_namelen(ce)
|| memcmp(last_ce->name, ce->name, ce_namelen(ce)))
- write_tempfile_record(last_ce->name, prefix_length);
+ write_tempfile_record(last_ce->name, prefix);
}
if (checkout_entry(ce, &state,
to_tempfile ? topath[ce_stage(ce)] : NULL) < 0)
@@ -114,7 +114,7 @@ static void checkout_all(const char *prefix, int prefix_length)
last_ce = ce;
}
if (last_ce && to_tempfile)
- write_tempfile_record(last_ce->name, prefix_length);
+ write_tempfile_record(last_ce->name, prefix);
if (errs)
/* we have already done our error reporting.
* exit with the same code as die().
@@ -123,7 +123,7 @@ static void checkout_all(const char *prefix, int prefix_length)
}
static const char * const builtin_checkout_index_usage[] = {
- N_("git checkout-index [options] [--] [<file>...]"),
+ N_("git checkout-index [<options>] [--] [<file>...]"),
NULL
};
@@ -248,7 +248,7 @@ int cmd_checkout_index(int argc, const char **argv, const char *prefix)
if (read_from_stdin)
die("git checkout-index: don't mix '--stdin' and explicit filenames");
p = prefix_path(prefix, prefix_length, arg);
- checkout_file(p, prefix_length);
+ checkout_file(p, prefix);
if (p < arg || p > arg + strlen(arg))
free((char *)p);
}
@@ -268,7 +268,7 @@ int cmd_checkout_index(int argc, const char **argv, const char *prefix)
strbuf_swap(&buf, &nbuf);
}
p = prefix_path(prefix, prefix_length, buf.buf);
- checkout_file(p, prefix_length);
+ checkout_file(p, prefix);
if (p < buf.buf || p > buf.buf + buf.len)
free((char *)p);
}
diff --git a/builtin/checkout.c b/builtin/checkout.c
index 5a78758..3e141fc 100644
--- a/builtin/checkout.c
+++ b/builtin/checkout.c
@@ -22,8 +22,8 @@
#include "argv-array.h"
static const char * const checkout_usage[] = {
- N_("git checkout [options] <branch>"),
- N_("git checkout [options] [<branch>] -- <file>..."),
+ N_("git checkout [<options>] <branch>"),
+ N_("git checkout [<options>] [<branch>] -- <file>..."),
NULL,
};
@@ -62,7 +62,7 @@ static int post_checkout_hook(struct commit *old, struct commit *new,
}
-static int update_some(const unsigned char *sha1, const char *base, int baselen,
+static int update_some(const unsigned char *sha1, struct strbuf *base,
const char *pathname, unsigned mode, int stage, void *context)
{
int len;
@@ -72,11 +72,11 @@ static int update_some(const unsigned char *sha1, const char *base, int baselen,
if (S_ISDIR(mode))
return READ_TREE_RECURSIVE;
- len = baselen + strlen(pathname);
+ len = base->len + strlen(pathname);
ce = xcalloc(1, cache_entry_size(len));
hashcpy(ce->sha1, sha1);
- memcpy(ce->name, base, baselen);
- memcpy(ce->name + baselen, pathname, len - baselen);
+ memcpy(ce->name, base->buf, base->len);
+ memcpy(ce->name + base->len, pathname, len - base->len);
ce->ce_flags = create_ce_flags(0) | CE_UPDATE;
ce->ce_namelen = len;
ce->ce_mode = create_ce_mode(mode);
@@ -746,7 +746,7 @@ static void suggest_reattach(struct commit *commit, struct rev_info *revs)
_(
"If you want to keep them by creating a new branch, "
"this may be a good time\nto do so with:\n\n"
- " git branch new_branch_name %s\n\n"),
+ " git branch <new-branch-name> %s\n\n"),
find_unique_abbrev(commit->object.sha1, DEFAULT_ABBREV));
}
@@ -1127,7 +1127,7 @@ int cmd_checkout(int argc, const char **argv, const char *prefix)
OPT_BOOL(0, "ignore-skip-worktree-bits", &opts.ignore_skipworktree,
N_("do not limit pathspecs to sparse entries only")),
OPT_HIDDEN_BOOL(0, "guess", &dwim_new_local_branch,
- N_("second guess 'git checkout no-such-branch'")),
+ N_("second guess 'git checkout <no-such-branch>'")),
OPT_END(),
};
diff --git a/builtin/clean.c b/builtin/clean.c
index 7784676..7e7fdcf 100644
--- a/builtin/clean.c
+++ b/builtin/clean.c
@@ -321,7 +321,7 @@ static void print_highlight_menu_stuff(struct menu_stuff *stuff, int **chosen)
switch (stuff->type) {
default:
- die("Bad type of menu_staff when print menu");
+ die("Bad type of menu_stuff when print menu");
case MENU_STUFF_TYPE_MENU_ITEM:
menu_item = (struct menu_item *)stuff->stuff;
for (i = 0; i < stuff->nr; i++, menu_item++) {
diff --git a/builtin/clone.c b/builtin/clone.c
index d5e7532..9572467 100644
--- a/builtin/clone.c
+++ b/builtin/clone.c
@@ -34,7 +34,7 @@
*
*/
static const char * const builtin_clone_usage[] = {
- N_("git clone [options] [--] <repo> [<dir>]"),
+ N_("git clone [<options>] [--] <repo> [<dir>]"),
NULL
};
@@ -49,6 +49,7 @@ static int option_verbosity;
static int option_progress = -1;
static struct string_list option_config;
static struct string_list option_reference;
+static int option_dissociate;
static int opt_parse_reference(const struct option *opt, const char *arg, int unset)
{
@@ -94,6 +95,8 @@ static struct option builtin_clone_options[] = {
N_("create a shallow clone of that depth")),
OPT_BOOL(0, "single-branch", &option_single_branch,
N_("clone only one branch, HEAD or --branch")),
+ OPT_BOOL(0, "dissociate", &option_dissociate,
+ N_("use --reference only while cloning")),
OPT_STRING(0, "separate-git-dir", &real_git_dir, N_("gitdir"),
N_("separate git dir from working tree")),
OPT_STRING_LIST('c', "config", &option_config, N_("key=value"),
@@ -735,6 +738,16 @@ static void write_refspec_config(const char *src_ref_prefix,
strbuf_release(&value);
}
+static void dissociate_from_references(void)
+{
+ static const char* argv[] = { "repack", "-a", "-d", NULL };
+
+ if (run_command_v_opt(argv, RUN_GIT_CMD|RUN_COMMAND_NO_STDIN))
+ die(_("cannot repack to clean up"));
+ if (unlink(git_path("objects/info/alternates")) && errno != ENOENT)
+ die_errno(_("cannot unlink temporary alternates file"));
+}
+
int cmd_clone(int argc, const char **argv, const char *prefix)
{
int is_bundle = 0, is_local;
@@ -880,6 +893,10 @@ int cmd_clone(int argc, const char **argv, const char *prefix)
if (option_reference.nr)
setup_reference();
+ else if (option_dissociate) {
+ warning(_("--dissociate given, but there is no --reference"));
+ option_dissociate = 0;
+ }
fetch_pattern = value.buf;
refspec = parse_fetch_refspec(1, &fetch_pattern);
@@ -993,6 +1010,9 @@ int cmd_clone(int argc, const char **argv, const char *prefix)
transport_unlock_pack(transport);
transport_disconnect(transport);
+ if (option_dissociate)
+ dissociate_from_references();
+
junk_mode = JUNK_LEAVE_REPO;
err = checkout();
diff --git a/builtin/column.c b/builtin/column.c
index 7581852..449413c 100644
--- a/builtin/column.c
+++ b/builtin/column.c
@@ -6,7 +6,7 @@
#include "column.h"
static const char * const builtin_column_usage[] = {
- N_("git column [options]"),
+ N_("git column [<options>]"),
NULL
};
static unsigned int colopts;
diff --git a/builtin/commit-tree.c b/builtin/commit-tree.c
index 8a66c74..25aa2cd 100644
--- a/builtin/commit-tree.c
+++ b/builtin/commit-tree.c
@@ -66,10 +66,8 @@ int cmd_commit_tree(int argc, const char **argv, const char *prefix)
continue;
}
- if (!memcmp(arg, "-S", 2)) {
- sign_commit = arg + 2;
+ if (skip_prefix(arg, "-S", &sign_commit))
continue;
- }
if (!strcmp(arg, "--no-gpg-sign")) {
sign_commit = NULL;
diff --git a/builtin/commit.c b/builtin/commit.c
index e108c53..6055c76 100644
--- a/builtin/commit.c
+++ b/builtin/commit.c
@@ -34,12 +34,12 @@
#include "mailmap.h"
static const char * const builtin_commit_usage[] = {
- N_("git commit [options] [--] <pathspec>..."),
+ N_("git commit [<options>] [--] <pathspec>..."),
NULL
};
static const char * const builtin_status_usage[] = {
- N_("git status [options] [--] <pathspec>..."),
+ N_("git status [<options>] [--] <pathspec>..."),
NULL
};
@@ -522,6 +522,12 @@ static int is_a_merge(const struct commit *current_head)
return !!(current_head->parents && current_head->parents->next);
}
+static void assert_split_ident(struct ident_split *id, const struct strbuf *buf)
+{
+ if (split_ident_line(id, buf->buf, buf->len) || !id->date_begin)
+ die("BUG: unable to parse our own ident: %s", buf->buf);
+}
+
static void export_one(const char *var, const char *s, const char *e, int hack)
{
struct strbuf buf = STRBUF_INIT;
@@ -532,20 +538,6 @@ static void export_one(const char *var, const char *s, const char *e, int hack)
strbuf_release(&buf);
}
-static int sane_ident_split(struct ident_split *person)
-{
- if (!person->name_begin || !person->name_end ||
- person->name_begin == person->name_end)
- return 0; /* no human readable name */
- if (!person->mail_begin || !person->mail_end ||
- person->mail_begin == person->mail_end)
- return 0; /* no usable mail */
- if (!person->date_begin || !person->date_end ||
- !person->tz_begin || !person->tz_end)
- return 0;
- return 1;
-}
-
static int parse_force_date(const char *in, struct strbuf *out)
{
strbuf_addch(out, '@');
@@ -567,20 +559,14 @@ static void set_ident_var(char **buf, char *val)
*buf = val;
}
-static char *envdup(const char *var)
-{
- const char *val = getenv(var);
- return val ? xstrdup(val) : NULL;
-}
-
static void determine_author_info(struct strbuf *author_ident)
{
char *name, *email, *date;
struct ident_split author;
- name = envdup("GIT_AUTHOR_NAME");
- email = envdup("GIT_AUTHOR_EMAIL");
- date = envdup("GIT_AUTHOR_DATE");
+ name = xstrdup_or_null(getenv("GIT_AUTHOR_NAME"));
+ email = xstrdup_or_null(getenv("GIT_AUTHOR_EMAIL"));
+ date = xstrdup_or_null(getenv("GIT_AUTHOR_DATE"));
if (author_message) {
struct ident_split ident;
@@ -623,25 +609,15 @@ static void determine_author_info(struct strbuf *author_ident)
}
strbuf_addstr(author_ident, fmt_ident(name, email, date, IDENT_STRICT));
- if (!split_ident_line(&author, author_ident->buf, author_ident->len) &&
- sane_ident_split(&author)) {
- export_one("GIT_AUTHOR_NAME", author.name_begin, author.name_end, 0);
- export_one("GIT_AUTHOR_EMAIL", author.mail_begin, author.mail_end, 0);
- export_one("GIT_AUTHOR_DATE", author.date_begin, author.tz_end, '@');
- }
-
+ assert_split_ident(&author, author_ident);
+ export_one("GIT_AUTHOR_NAME", author.name_begin, author.name_end, 0);
+ export_one("GIT_AUTHOR_EMAIL", author.mail_begin, author.mail_end, 0);
+ export_one("GIT_AUTHOR_DATE", author.date_begin, author.tz_end, '@');
free(name);
free(email);
free(date);
}
-static void split_ident_or_die(struct ident_split *id, const struct strbuf *buf)
-{
- if (split_ident_line(id, buf->buf, buf->len) ||
- !sane_ident_split(id))
- die(_("Malformed ident string: '%s'"), buf->buf);
-}
-
static int author_date_is_interesting(void)
{
return author_message || force_date;
@@ -800,32 +776,8 @@ static int prepare_to_commit(const char *index_file, const char *prefix,
if (clean_message_contents)
stripspace(&sb, 0);
- if (signoff) {
- /*
- * See if we have a Conflicts: block at the end. If yes, count
- * its size, so we can ignore it.
- */
- int ignore_footer = 0;
- int i, eol, previous = 0;
- const char *nl;
-
- for (i = 0; i < sb.len; i++) {
- nl = memchr(sb.buf + i, '\n', sb.len - i);
- if (nl)
- eol = nl - sb.buf;
- else
- eol = sb.len;
- if (starts_with(sb.buf + previous, "\nConflicts:\n")) {
- ignore_footer = sb.len - previous;
- break;
- }
- while (i < eol)
- i++;
- previous = eol;
- }
-
- append_signoff(&sb, ignore_footer, 0);
- }
+ if (signoff)
+ append_signoff(&sb, ignore_non_trailer(&sb), 0);
if (fwrite(sb.buf, 1, sb.len, s->fp) < sb.len)
die_errno(_("could not write commit template"));
@@ -880,8 +832,14 @@ static int prepare_to_commit(const char *index_file, const char *prefix,
status_printf_ln(s, GIT_COLOR_NORMAL,
"%s", only_include_assumed);
- split_ident_or_die(&ai, author_ident);
- split_ident_or_die(&ci, &committer_ident);
+ /*
+ * These should never fail because they come from our own
+ * fmt_ident. They may fail the sane_ident test, but we know
+ * that the name and mail pointers will at least be valid,
+ * which is enough for our tests and printing here.
+ */
+ assert_split_ident(&ai, author_ident);
+ assert_split_ident(&ci, &committer_ident);
if (ident_cmp(&ai, &ci))
status_printf_ln(s, GIT_COLOR_NORMAL,
@@ -1092,7 +1050,7 @@ static const char *find_author_by_nickname(const char *name)
clear_mailmap(&mailmap);
return strbuf_detach(&buf, NULL);
}
- die(_("No existing author found with '%s'"), name);
+ die(_("--author '%s' is not 'Name <email>' and matches no existing author"), name);
}
diff --git a/builtin/config.c b/builtin/config.c
index 15a7bea..d32c532 100644
--- a/builtin/config.c
+++ b/builtin/config.c
@@ -5,7 +5,7 @@
#include "urlmatch.h"
static const char *const builtin_config_usage[] = {
- N_("git config [options]"),
+ N_("git config [<options>]"),
NULL
};
diff --git a/builtin/describe.c b/builtin/describe.c
index 9103193..e00a75b 100644
--- a/builtin/describe.c
+++ b/builtin/describe.c
@@ -14,8 +14,8 @@
#define MAX_TAGS (FLAG_BITS - 1)
static const char * const describe_usage[] = {
- N_("git describe [options] <commit-ish>*"),
- N_("git describe [options] --dirty"),
+ N_("git describe [<options>] [<commit-ish>...]"),
+ N_("git describe [<options>] --dirty"),
NULL
};
diff --git a/builtin/diff-files.c b/builtin/diff-files.c
index 9200069..8ed2eb8 100644
--- a/builtin/diff-files.c
+++ b/builtin/diff-files.c
@@ -11,7 +11,7 @@
#include "submodule.h"
static const char diff_files_usage[] =
-"git diff-files [-q] [-0/-1/2/3 |-c|--cc] [<common diff options>] [<path>...]"
+"git diff-files [-q] [-0 | -1 | -2 | -3 | -c | --cc] [<common-diff-options>] [<path>...]"
COMMON_DIFF_OPTIONS_HELP;
int cmd_diff_files(int argc, const char **argv, const char *prefix)
diff --git a/builtin/diff-index.c b/builtin/diff-index.c
index ce15b23..d979824 100644
--- a/builtin/diff-index.c
+++ b/builtin/diff-index.c
@@ -7,7 +7,7 @@
static const char diff_cache_usage[] =
"git diff-index [-m] [--cached] "
-"[<common diff options>] <tree-ish> [<path>...]"
+"[<common-diff-options>] <tree-ish> [<path>...]"
COMMON_DIFF_OPTIONS_HELP;
int cmd_diff_index(int argc, const char **argv, const char *prefix)
diff --git a/builtin/diff-tree.c b/builtin/diff-tree.c
index 1c4ad62..12b683d 100644
--- a/builtin/diff-tree.c
+++ b/builtin/diff-tree.c
@@ -82,7 +82,7 @@ static int diff_tree_stdin(char *line)
static const char diff_tree_usage[] =
"git diff-tree [--stdin] [-m] [-c] [--cc] [-s] [-v] [--pretty] [-t] [-r] [--root] "
-"[<common diff options>] <tree-ish> [<tree-ish>] [<path>...]\n"
+"[<common-diff-options>] <tree-ish> [<tree-ish>] [<path>...]\n"
" -r diff recursively\n"
" --root include the initial commit as diff against /dev/null\n"
COMMON_DIFF_OPTIONS_HELP;
diff --git a/builtin/fetch-pack.c b/builtin/fetch-pack.c
index 1262b40..4a6b340 100644
--- a/builtin/fetch-pack.c
+++ b/builtin/fetch-pack.c
@@ -6,7 +6,7 @@
#include "sha1-array.h"
static const char fetch_pack_usage[] =
-"git fetch-pack [--all] [--stdin] [--quiet|-q] [--keep|-k] [--thin] "
+"git fetch-pack [--all] [--stdin] [--quiet | -q] [--keep | -k] [--thin] "
"[--include-tag] [--upload-pack=<git-upload-pack>] [--depth=<n>] "
"[--no-progress] [--diag-url] [-v] [<host>:]<directory> [<refs>...]";
diff --git a/builtin/fmt-merge-msg.c b/builtin/fmt-merge-msg.c
index 37177c6..1d962dc 100644
--- a/builtin/fmt-merge-msg.c
+++ b/builtin/fmt-merge-msg.c
@@ -10,7 +10,7 @@
#include "gpg-interface.h"
static const char * const fmt_merge_msg_usage[] = {
- N_("git fmt-merge-msg [-m <message>] [--log[=<n>]|--no-log] [--file <file>]"),
+ N_("git fmt-merge-msg [-m <message>] [--log[=<n>] | --no-log] [--file <file>]"),
NULL
};
@@ -216,8 +216,7 @@ static void add_branch_desc(struct strbuf *out, const char *name)
strbuf_addf(out, " : %.*s", (int)(ep - bp), bp);
bp = ep;
}
- if (out->buf[out->len - 1] != '\n')
- strbuf_addch(out, '\n');
+ strbuf_complete_line(out);
}
strbuf_release(&desc);
}
diff --git a/builtin/for-each-ref.c b/builtin/for-each-ref.c
index 603a90e..19be78a 100644
--- a/builtin/for-each-ref.c
+++ b/builtin/for-each-ref.c
@@ -717,7 +717,10 @@ static void populate_value(struct refinfo *ref)
starts_with(name, "upstream")) {
char buf[40];
- stat_tracking_info(branch, &num_ours, &num_theirs);
+ if (stat_tracking_info(branch, &num_ours,
+ &num_theirs) != 1)
+ continue;
+
if (!num_ours && !num_theirs)
v->s = "";
else if (!num_ours) {
@@ -735,7 +738,11 @@ static void populate_value(struct refinfo *ref)
} else if (!strcmp(formatp, "trackshort") &&
starts_with(name, "upstream")) {
assert(branch);
- stat_tracking_info(branch, &num_ours, &num_theirs);
+
+ if (stat_tracking_info(branch, &num_ours,
+ &num_theirs) != 1)
+ continue;
+
if (!num_ours && !num_theirs)
v->s = "=";
else if (!num_ours)
@@ -1054,7 +1061,7 @@ static int opt_parse_sort(const struct option *opt, const char *arg, int unset)
}
static char const * const for_each_ref_usage[] = {
- N_("git for-each-ref [options] [<pattern>]"),
+ N_("git for-each-ref [<options>] [<pattern>]"),
NULL
};
@@ -1075,7 +1082,7 @@ int cmd_for_each_ref(int argc, const char **argv, const char *prefix)
OPT_BIT(0 , "python", &quote_style,
N_("quote placeholders suitably for python"), QUOTE_PYTHON),
OPT_BIT(0 , "tcl", &quote_style,
- N_("quote placeholders suitably for tcl"), QUOTE_TCL),
+ N_("quote placeholders suitably for Tcl"), QUOTE_TCL),
OPT_GROUP(""),
OPT_INTEGER( 0 , "count", &maxcount, N_("show only <n> matched refs")),
diff --git a/builtin/fsck.c b/builtin/fsck.c
index a27515a..0c75786 100644
--- a/builtin/fsck.c
+++ b/builtin/fsck.c
@@ -600,7 +600,7 @@ static int fsck_cache_tree(struct cache_tree *it)
}
static char const * const fsck_usage[] = {
- N_("git fsck [options] [<object>...]"),
+ N_("git fsck [<options>] [<object>...]"),
NULL
};
diff --git a/builtin/gc.c b/builtin/gc.c
index 005adbe..5c634af 100644
--- a/builtin/gc.c
+++ b/builtin/gc.c
@@ -21,7 +21,7 @@
#define FAILED_RUN "failed to run %s"
static const char * const builtin_gc_usage[] = {
- N_("git gc [options]"),
+ N_("git gc [<options>]"),
NULL
};
diff --git a/builtin/grep.c b/builtin/grep.c
index 4063882..9262b73 100644
--- a/builtin/grep.c
+++ b/builtin/grep.c
@@ -20,7 +20,7 @@
#include "pathspec.h"
static char const * const grep_usage[] = {
- N_("git grep [options] [-e] <pattern> [<rev>...] [[--] <path>...]"),
+ N_("git grep [<options>] [-e] <pattern> [<rev>...] [[--] <path>...]"),
NULL
};
diff --git a/builtin/hash-object.c b/builtin/hash-object.c
index 6158363..207b90c 100644
--- a/builtin/hash-object.c
+++ b/builtin/hash-object.c
@@ -79,7 +79,7 @@ static void hash_stdin_paths(const char *type, int no_filters, unsigned flags,
int cmd_hash_object(int argc, const char **argv, const char *prefix)
{
static const char * const hash_object_usage[] = {
- N_("git hash-object [-t <type>] [-w] [--path=<file>|--no-filters] [--stdin] [--] <file>..."),
+ N_("git hash-object [-t <type>] [-w] [--path=<file> | --no-filters] [--stdin] [--] <file>..."),
N_("git hash-object --stdin-paths < <list-of-paths>"),
NULL
};
diff --git a/builtin/help.c b/builtin/help.c
index b3c818e..6133fe4 100644
--- a/builtin/help.c
+++ b/builtin/help.c
@@ -49,7 +49,7 @@ static struct option builtin_help_options[] = {
};
static const char * const builtin_help_usage[] = {
- N_("git help [--all] [--guides] [--man|--web|--info] [command]"),
+ N_("git help [--all] [--guides] [--man | --web | --info] [<command>]"),
NULL
};
@@ -321,16 +321,18 @@ static void setup_man_path(void)
{
struct strbuf new_path = STRBUF_INIT;
const char *old_path = getenv("MANPATH");
+ char *git_man_path = system_path(GIT_MAN_PATH);
/* We should always put ':' after our path. If there is no
* old_path, the ':' at the end will let 'man' to try
* system-wide paths after ours to find the manual page. If
* there is old_path, we need ':' as delimiter. */
- strbuf_addstr(&new_path, system_path(GIT_MAN_PATH));
+ strbuf_addstr(&new_path, git_man_path);
strbuf_addch(&new_path, ':');
if (old_path)
strbuf_addstr(&new_path, old_path);
+ free(git_man_path);
setenv("MANPATH", new_path.buf, 1);
strbuf_release(&new_path);
@@ -380,8 +382,10 @@ static void show_info_page(const char *git_cmd)
static void get_html_page_path(struct strbuf *page_path, const char *page)
{
struct stat st;
+ char *to_free = NULL;
+
if (!html_path)
- html_path = system_path(GIT_HTML_PATH);
+ html_path = to_free = system_path(GIT_HTML_PATH);
/* Check that we have a git documentation directory. */
if (!strstr(html_path, "://")) {
@@ -392,6 +396,7 @@ static void get_html_page_path(struct strbuf *page_path, const char *page)
strbuf_init(page_path, 0);
strbuf_addf(page_path, "%s/%s.html", html_path, page);
+ free(to_free);
}
/*
diff --git a/builtin/index-pack.c b/builtin/index-pack.c
index a369f55..4632117 100644
--- a/builtin/index-pack.c
+++ b/builtin/index-pack.c
@@ -447,7 +447,7 @@ static void *unpack_entry_data(unsigned long offset, unsigned long size,
if (type == OBJ_BLOB && size > big_file_threshold)
buf = fixed_buf;
else
- buf = xmalloc(size);
+ buf = xmallocz(size);
memset(&stream, 0, sizeof(stream));
git_inflate_init(&stream);
@@ -552,7 +552,7 @@ static void *unpack_data(struct object_entry *obj,
git_zstream stream;
int status;
- data = xmalloc(consume ? 64*1024 : obj->size);
+ data = xmallocz(consume ? 64*1024 : obj->size);
inbuf = xmalloc((len < 64*1024) ? len : 64*1024);
memset(&stream, 0, sizeof(stream));
diff --git a/builtin/init-db.c b/builtin/init-db.c
index aab44d2..6723d39 100644
--- a/builtin/init-db.c
+++ b/builtin/init-db.c
@@ -119,15 +119,18 @@ static void copy_templates(const char *template_dir)
DIR *dir;
const char *git_dir = get_git_dir();
int len = strlen(git_dir);
+ char *to_free = NULL;
if (!template_dir)
template_dir = getenv(TEMPLATE_DIR_ENVIRONMENT);
if (!template_dir)
template_dir = init_db_template_dir;
if (!template_dir)
- template_dir = system_path(DEFAULT_GIT_TEMPLATE_DIR);
- if (!template_dir[0])
+ template_dir = to_free = system_path(DEFAULT_GIT_TEMPLATE_DIR);
+ if (!template_dir[0]) {
+ free(to_free);
return;
+ }
template_len = strlen(template_dir);
if (PATH_MAX <= (template_len+strlen("/config")))
die(_("insanely long template path %s"), template_dir);
@@ -139,7 +142,7 @@ static void copy_templates(const char *template_dir)
dir = opendir(template_path);
if (!dir) {
warning(_("templates not found %s"), template_dir);
- return;
+ goto free_return;
}
/* Make sure that template is from the correct vintage */
@@ -155,8 +158,7 @@ static void copy_templates(const char *template_dir)
"a wrong format version %d from '%s'"),
repository_format_version,
template_dir);
- closedir(dir);
- return;
+ goto close_free_return;
}
memcpy(path, git_dir, len);
@@ -166,7 +168,10 @@ static void copy_templates(const char *template_dir)
copy_templates_1(path, len,
template_path, template_len,
dir);
+close_free_return:
closedir(dir);
+free_return:
+ free(to_free);
}
static int git_init_db_config(const char *k, const char *v, void *cb)
@@ -256,6 +261,8 @@ static int create_default_files(const char *template_path)
!lstat(path, &st2) &&
st1.st_mode != st2.st_mode &&
!chmod(path, st1.st_mode));
+ if (filemode && !reinit && (st1.st_mode & S_IXUSR))
+ filemode = 0;
}
git_config_set("core.filemode", filemode ? "true" : "false");
@@ -465,7 +472,7 @@ static int shared_callback(const struct option *opt, const char *arg, int unset)
}
static const char *const init_db_usage[] = {
- N_("git init [-q | --quiet] [--bare] [--template=<template-directory>] [--shared[=<permissions>]] [directory]"),
+ N_("git init [-q | --quiet] [--bare] [--template=<template-directory>] [--shared[=<permissions>]] [<directory>]"),
NULL
};
diff --git a/builtin/log.c b/builtin/log.c
index 734aab3..dd8f3fc 100644
--- a/builtin/log.c
+++ b/builtin/log.c
@@ -38,8 +38,8 @@ static const char *fmt_patch_subject_prefix = "PATCH";
static const char *fmt_pretty;
static const char * const builtin_log_usage[] = {
- N_("git log [<options>] [<revision range>] [[--] <path>...]\n")
- N_(" or: git show [options] <object>..."),
+ N_("git log [<options>] [<revision range>] [[--] <path>...]"),
+ N_("git show [<options>] <object>..."),
NULL
};
@@ -489,7 +489,7 @@ static int show_tag_object(const unsigned char *sha1, struct rev_info *rev)
}
static int show_tree_object(const unsigned char *sha1,
- const char *base, int baselen,
+ struct strbuf *base,
const char *pathname, unsigned mode, int stage, void *context)
{
printf("%s%s\n", pathname, S_ISDIR(mode) ? "/" : "");
@@ -705,7 +705,7 @@ static int git_format_config(const char *var, const char *value, void *cb)
return 0;
}
if (!strcmp(var, "diff.color") || !strcmp(var, "color.diff") ||
- !strcmp(var, "color.ui")) {
+ !strcmp(var, "color.ui") || !strcmp(var, "diff.submodule")) {
return 0;
}
if (!strcmp(var, "format.numbered")) {
@@ -1023,7 +1023,7 @@ static const char *set_outdir(const char *prefix, const char *output_directory)
}
static const char * const builtin_format_patch_usage[] = {
- N_("git format-patch [options] [<since> | <revision range>]"),
+ N_("git format-patch [<options>] [<since> | <revision-range>]"),
NULL
};
diff --git a/builtin/ls-files.c b/builtin/ls-files.c
index 99cee20..914054d 100644
--- a/builtin/ls-files.c
+++ b/builtin/ls-files.c
@@ -398,7 +398,7 @@ int report_path_error(const char *ps_matched,
}
static const char * const ls_files_usage[] = {
- N_("git ls-files [options] [<file>...]"),
+ N_("git ls-files [<options>] [<file>...]"),
NULL
};
diff --git a/builtin/ls-remote.c b/builtin/ls-remote.c
index b2a4b92..4554dbc 100644
--- a/builtin/ls-remote.c
+++ b/builtin/ls-remote.c
@@ -5,7 +5,7 @@
static const char ls_remote_usage[] =
"git ls-remote [--heads] [--tags] [-u <exec> | --upload-pack <exec>]\n"
-" [-q|--quiet] [--exit-code] [--get-url] [<repository> [<refs>...]]";
+" [-q | --quiet] [--exit-code] [--get-url] [<repository> [<refs>...]]";
/*
* Is there one among the list of patterns that match the tail part
diff --git a/builtin/ls-tree.c b/builtin/ls-tree.c
index 51184df..3b04a0f 100644
--- a/builtin/ls-tree.c
+++ b/builtin/ls-tree.c
@@ -61,10 +61,11 @@ static int show_recursive(const char *base, int baselen, const char *pathname)
}
}
-static int show_tree(const unsigned char *sha1, const char *base, int baselen,
+static int show_tree(const unsigned char *sha1, struct strbuf *base,
const char *pathname, unsigned mode, int stage, void *context)
{
int retval = 0;
+ int baselen;
const char *type = blob_type;
if (S_ISGITLINK(mode)) {
@@ -79,7 +80,7 @@ static int show_tree(const unsigned char *sha1, const char *base, int baselen,
*/
type = commit_type;
} else if (S_ISDIR(mode)) {
- if (show_recursive(base, baselen, pathname)) {
+ if (show_recursive(base->buf, base->len, pathname)) {
retval = READ_TREE_RECURSIVE;
if (!(ls_options & LS_SHOW_TREES))
return retval;
@@ -89,10 +90,6 @@ static int show_tree(const unsigned char *sha1, const char *base, int baselen,
else if (ls_options & LS_TREE_ONLY)
return 0;
- if (chomp_prefix &&
- (baselen < chomp_prefix || memcmp(ls_tree_prefix, base, chomp_prefix)))
- return 0;
-
if (!(ls_options & LS_NAME_ONLY)) {
if (ls_options & LS_SHOW_SIZE) {
char size_text[24];
@@ -112,8 +109,12 @@ static int show_tree(const unsigned char *sha1, const char *base, int baselen,
printf("%06o %s %s\t", mode, type,
find_unique_abbrev(sha1, abbrev));
}
- write_name_quotedpfx(base + chomp_prefix, baselen - chomp_prefix,
- pathname, stdout, line_termination);
+ baselen = base->len;
+ strbuf_addstr(base, pathname);
+ write_name_quoted_relative(base->buf,
+ chomp_prefix ? ls_tree_prefix : NULL,
+ stdout, line_termination);
+ strbuf_setlen(base, baselen);
return retval;
}
@@ -173,7 +174,8 @@ int cmd_ls_tree(int argc, const char **argv, const char *prefix)
* cannot be lifted until it is converted to use
* match_pathspec() or tree_entry_interesting()
*/
- parse_pathspec(&pathspec, PATHSPEC_GLOB | PATHSPEC_ICASE,
+ parse_pathspec(&pathspec, PATHSPEC_GLOB | PATHSPEC_ICASE |
+ PATHSPEC_EXCLUDE,
PATHSPEC_PREFER_CWD,
prefix, argv + 1);
for (i = 0; i < pathspec.nr; i++)
diff --git a/builtin/mailinfo.c b/builtin/mailinfo.c
index 6a14d29..999a525 100644
--- a/builtin/mailinfo.c
+++ b/builtin/mailinfo.c
@@ -15,6 +15,7 @@ static const char *metainfo_charset;
static struct strbuf line = STRBUF_INIT;
static struct strbuf name = STRBUF_INIT;
static struct strbuf email = STRBUF_INIT;
+static char *message_id;
static enum {
TE_DONTCARE, TE_QP, TE_BASE64
@@ -24,6 +25,7 @@ static struct strbuf charset = STRBUF_INIT;
static int patch_lines;
static struct strbuf **p_hdr_data, **s_hdr_data;
static int use_scissors;
+static int add_message_id;
static int use_inbody_headers = 1;
#define MAX_HDR_PARSED 10
@@ -198,6 +200,12 @@ static void handle_content_type(struct strbuf *line)
}
}
+static void handle_message_id(const struct strbuf *line)
+{
+ if (add_message_id)
+ message_id = strdup(line->buf);
+}
+
static void handle_content_transfer_encoding(const struct strbuf *line)
{
if (strcasestr(line->buf, "base64"))
@@ -342,6 +350,14 @@ static int check_header(const struct strbuf *line,
ret = 1;
goto check_header_out;
}
+ if (cmp_header(line, "Message-Id")) {
+ len = strlen("Message-Id: ");
+ strbuf_add(&sb, line->buf + len, line->len - len);
+ decode_header(&sb);
+ handle_message_id(&sb);
+ ret = 1;
+ goto check_header_out;
+ }
/* for inbody stuff */
if (starts_with(line->buf, ">From") && isspace(line->buf[5])) {
@@ -816,6 +832,8 @@ static int handle_commit_msg(struct strbuf *line)
}
if (patchbreak(line)) {
+ if (message_id)
+ fprintf(cmitmsg, "Message-Id: %s\n", message_id);
fclose(cmitmsg);
cmitmsg = NULL;
return 1;
@@ -1013,7 +1031,7 @@ static int git_mailinfo_config(const char *var, const char *value, void *unused)
}
static const char mailinfo_usage[] =
- "git mailinfo [-k|-b] [-u | --encoding=<encoding> | -n] [--scissors | --no-scissors] msg patch < mail >info";
+ "git mailinfo [-k | -b] [-m | --message-id] [-u | --encoding=<encoding> | -n] [--scissors | --no-scissors] <msg> <patch> < mail >info";
int cmd_mailinfo(int argc, const char **argv, const char *prefix)
{
@@ -1032,6 +1050,8 @@ int cmd_mailinfo(int argc, const char **argv, const char *prefix)
keep_subject = 1;
else if (!strcmp(argv[1], "-b"))
keep_non_patch_brackets_in_subject = 1;
+ else if (!strcmp(argv[1], "-m") || !strcmp(argv[1], "--message-id"))
+ add_message_id = 1;
else if (!strcmp(argv[1], "-u"))
metainfo_charset = def_charset;
else if (!strcmp(argv[1], "-n"))
diff --git a/builtin/merge-base.c b/builtin/merge-base.c
index 0ecde8d..08a8217 100644
--- a/builtin/merge-base.c
+++ b/builtin/merge-base.c
@@ -10,7 +10,7 @@ static int show_merge_base(struct commit **rev, int rev_nr, int show_all)
{
struct commit_list *result;
- result = get_merge_bases_many(rev[0], rev_nr - 1, rev + 1, 0);
+ result = get_merge_bases_many_dirty(rev[0], rev_nr - 1, rev + 1);
if (!result)
return 1;
@@ -26,8 +26,8 @@ static int show_merge_base(struct commit **rev, int rev_nr, int show_all)
}
static const char * const merge_base_usage[] = {
- N_("git merge-base [-a|--all] <commit> <commit>..."),
- N_("git merge-base [-a|--all] --octopus <commit>..."),
+ N_("git merge-base [-a | --all] <commit> <commit>..."),
+ N_("git merge-base [-a | --all] --octopus <commit>..."),
N_("git merge-base --independent <commit>..."),
N_("git merge-base --is-ancestor <commit> <commit>"),
N_("git merge-base --fork-point <ref> [<commit>]"),
@@ -176,7 +176,7 @@ static int handle_fork_point(int argc, const char **argv)
for (i = 0; i < revs.nr; i++)
revs.commit[i]->object.flags &= ~TMP_MARK;
- bases = get_merge_bases_many(derived, revs.nr, revs.commit, 0);
+ bases = get_merge_bases_many_dirty(derived, revs.nr, revs.commit);
/*
* There should be one and only one merge base, when we found
diff --git a/builtin/merge-file.c b/builtin/merge-file.c
index 844f84f..ea8093f 100644
--- a/builtin/merge-file.c
+++ b/builtin/merge-file.c
@@ -5,7 +5,7 @@
#include "parse-options.h"
static const char *const merge_file_usage[] = {
- N_("git merge-file [options] [-L name1 [-L orig [-L name2]]] file1 orig_file file2"),
+ N_("git merge-file [<options>] [-L <name1> [-L <orig> [-L <name2>]]] <file1> <orig-file> <file2>"),
NULL
};
@@ -42,7 +42,7 @@ int cmd_merge_file(int argc, const char **argv, const char *prefix)
N_("for conflicts, use this marker size")),
OPT__QUIET(&quiet, N_("do not warn about conflicts")),
OPT_CALLBACK('L', NULL, names, N_("name"),
- N_("set labels for file1/orig_file/file2"), &label_cb),
+ N_("set labels for file1/orig-file/file2"), &label_cb),
OPT_END(),
};
@@ -90,7 +90,8 @@ int cmd_merge_file(int argc, const char **argv, const char *prefix)
if (ret >= 0) {
const char *filename = argv[0];
- FILE *f = to_stdout ? stdout : fopen(filename, "wb");
+ const char *fpath = prefix_filename(prefix, prefixlen, argv[0]);
+ FILE *f = to_stdout ? stdout : fopen(fpath, "wb");
if (!f)
ret = error("Could not open %s for writing", filename);
diff --git a/builtin/merge-index.c b/builtin/merge-index.c
index b416d92..1a1eafa 100644
--- a/builtin/merge-index.c
+++ b/builtin/merge-index.c
@@ -75,7 +75,7 @@ int cmd_merge_index(int argc, const char **argv, const char *prefix)
signal(SIGCHLD, SIG_DFL);
if (argc < 3)
- usage("git merge-index [-o] [-q] <merge-program> (-a | [--] <filename>*)");
+ usage("git merge-index [-o] [-q] <merge-program> (-a | [--] [<filename>...])");
read_cache();
diff --git a/builtin/merge.c b/builtin/merge.c
index bebbe5b..3b0f8f9 100644
--- a/builtin/merge.c
+++ b/builtin/merge.c
@@ -29,6 +29,7 @@
#include "remote.h"
#include "fmt-merge-msg.h"
#include "gpg-interface.h"
+#include "sequencer.h"
#define DEFAULT_TWOHEAD (1<<0)
#define DEFAULT_OCTOPUS (1<<1)
@@ -41,8 +42,8 @@ struct strategy {
};
static const char * const builtin_merge_usage[] = {
- N_("git merge [options] [<commit>...]"),
- N_("git merge [options] <msg> HEAD <commit>"),
+ N_("git merge [<options>] [<commit>...]"),
+ N_("git merge [<options>] <msg> HEAD <commit>"),
N_("git merge --abort"),
NULL
};
@@ -880,28 +881,20 @@ static int finish_automerge(struct commit *head,
return 0;
}
-static int suggest_conflicts(int renormalizing)
+static int suggest_conflicts(void)
{
const char *filename;
FILE *fp;
- int pos;
+ struct strbuf msgbuf = STRBUF_INIT;
filename = git_path("MERGE_MSG");
fp = fopen(filename, "a");
if (!fp)
die_errno(_("Could not open '%s' for writing"), filename);
- fprintf(fp, "\nConflicts:\n");
- for (pos = 0; pos < active_nr; pos++) {
- const struct cache_entry *ce = active_cache[pos];
-
- if (ce_stage(ce)) {
- fprintf(fp, "\t%s\n", ce->name);
- while (pos + 1 < active_nr &&
- !strcmp(ce->name,
- active_cache[pos + 1]->name))
- pos++;
- }
- }
+
+ append_conflicts_hint(&msgbuf);
+ fputs(msgbuf.buf, fp);
+ strbuf_release(&msgbuf);
fclose(fp);
rerere(allow_rerere_auto);
printf(_("Automatic merge failed; "
@@ -1320,7 +1313,7 @@ int cmd_merge(int argc, const char **argv, const char *prefix)
if (!remoteheads)
; /* already up-to-date */
else if (!remoteheads->next)
- common = get_merge_bases(head_commit, remoteheads->item, 1);
+ common = get_merge_bases(head_commit, remoteheads->item);
else {
struct commit_list *list = remoteheads;
commit_list_insert(head_commit, &list);
@@ -1417,7 +1410,7 @@ int cmd_merge(int argc, const char **argv, const char *prefix)
* merge_bases again, otherwise "git merge HEAD^
* HEAD^^" would be missed.
*/
- common_one = get_merge_bases(head_commit, j->item, 1);
+ common_one = get_merge_bases(head_commit, j->item);
if (hashcmp(common_one->item->object.sha1,
j->item->object.sha1)) {
up_to_date = 0;
@@ -1550,7 +1543,7 @@ int cmd_merge(int argc, const char **argv, const char *prefix)
fprintf(stderr, _("Automatic merge went well; "
"stopped before committing as requested\n"));
else
- ret = suggest_conflicts(option_renormalize);
+ ret = suggest_conflicts();
done:
free(branch_to_free);
diff --git a/builtin/mv.c b/builtin/mv.c
index 563d05b..d1d4316 100644
--- a/builtin/mv.c
+++ b/builtin/mv.c
@@ -12,7 +12,7 @@
#include "submodule.h"
static const char * const builtin_mv_usage[] = {
- N_("git mv [options] <source>... <destination>"),
+ N_("git mv [<options>] <source>... <destination>"),
NULL
};
diff --git a/builtin/name-rev.c b/builtin/name-rev.c
index 3c8f319..9736d44 100644
--- a/builtin/name-rev.c
+++ b/builtin/name-rev.c
@@ -252,9 +252,9 @@ static void show_name(const struct object *obj,
}
static char const * const name_rev_usage[] = {
- N_("git name-rev [options] <commit>..."),
- N_("git name-rev [options] --all"),
- N_("git name-rev [options] --stdin"),
+ N_("git name-rev [<options>] <commit>..."),
+ N_("git name-rev [<options>] --all"),
+ N_("git name-rev [<options>] --stdin"),
NULL
};
diff --git a/builtin/notes.c b/builtin/notes.c
index a9f37d0..63f95fc 100644
--- a/builtin/notes.c
+++ b/builtin/notes.c
@@ -21,18 +21,18 @@
#include "notes-utils.h"
static const char * const git_notes_usage[] = {
- N_("git notes [--ref <notes_ref>] [list [<object>]]"),
- N_("git notes [--ref <notes_ref>] add [-f] [--allow-empty] [-m <msg> | -F <file> | (-c | -C) <object>] [<object>]"),
- N_("git notes [--ref <notes_ref>] copy [-f] <from-object> <to-object>"),
- N_("git notes [--ref <notes_ref>] append [--allow-empty] [-m <msg> | -F <file> | (-c | -C) <object>] [<object>]"),
- N_("git notes [--ref <notes_ref>] edit [--allow-empty] [<object>]"),
- N_("git notes [--ref <notes_ref>] show [<object>]"),
- N_("git notes [--ref <notes_ref>] merge [-v | -q] [-s <strategy> ] <notes_ref>"),
+ N_("git notes [--ref <notes-ref>] [list [<object>]]"),
+ N_("git notes [--ref <notes-ref>] add [-f] [--allow-empty] [-m <msg> | -F <file> | (-c | -C) <object>] [<object>]"),
+ N_("git notes [--ref <notes-ref>] copy [-f] <from-object> <to-object>"),
+ N_("git notes [--ref <notes-ref>] append [--allow-empty] [-m <msg> | -F <file> | (-c | -C) <object>] [<object>]"),
+ N_("git notes [--ref <notes-ref>] edit [--allow-empty] [<object>]"),
+ N_("git notes [--ref <notes-ref>] show [<object>]"),
+ N_("git notes [--ref <notes-ref>] merge [-v | -q] [-s <strategy>] <notes-ref>"),
N_("git notes merge --commit [-v | -q]"),
N_("git notes merge --abort [-v | -q]"),
- N_("git notes [--ref <notes_ref>] remove [<object>...]"),
- N_("git notes [--ref <notes_ref>] prune [-n | -v]"),
- N_("git notes [--ref <notes_ref>] get-ref"),
+ N_("git notes [--ref <notes-ref>] remove [<object>...]"),
+ N_("git notes [--ref <notes-ref>] prune [-n | -v]"),
+ N_("git notes [--ref <notes-ref>] get-ref"),
NULL
};
@@ -68,7 +68,7 @@ static const char * const git_notes_show_usage[] = {
};
static const char * const git_notes_merge_usage[] = {
- N_("git notes merge [<options>] <notes_ref>"),
+ N_("git notes merge [<options>] <notes-ref>"),
N_("git notes merge --commit [<options>]"),
N_("git notes merge --abort [<options>]"),
NULL
@@ -951,7 +951,7 @@ int cmd_notes(int argc, const char **argv, const char *prefix)
const char *override_notes_ref = NULL;
struct option options[] = {
OPT_STRING(0, "ref", &override_notes_ref, N_("notes-ref"),
- N_("use notes from <notes_ref>")),
+ N_("use notes from <notes-ref>")),
OPT_END()
};
diff --git a/builtin/pack-objects.c b/builtin/pack-objects.c
index 3f9f5c7..d816587 100644
--- a/builtin/pack-objects.c
+++ b/builtin/pack-objects.c
@@ -2613,6 +2613,7 @@ int cmd_pack_objects(int argc, const char **argv, const char *prefix)
{
int use_internal_rev_list = 0;
int thin = 0;
+ int shallow = 0;
int all_progress_implied = 0;
struct argv_array rp = ARGV_ARRAY_INIT;
int rev_list_unpacked = 0, rev_list_all = 0, rev_list_reflog = 0;
@@ -2677,6 +2678,8 @@ int cmd_pack_objects(int argc, const char **argv, const char *prefix)
PARSE_OPT_OPTARG, option_parse_unpack_unreachable },
OPT_BOOL(0, "thin", &thin,
N_("create thin packs")),
+ OPT_BOOL(0, "shallow", &shallow,
+ N_("create packs suitable for shallow fetches")),
OPT_BOOL(0, "honor-pack-keep", &ignore_packed_keep,
N_("ignore packs that have companion .keep file")),
OPT_INTEGER(0, "compression", &pack_compression_level,
@@ -2711,7 +2714,9 @@ int cmd_pack_objects(int argc, const char **argv, const char *prefix)
argv_array_push(&rp, "pack-objects");
if (thin) {
use_internal_rev_list = 1;
- argv_array_push(&rp, "--objects-edge");
+ argv_array_push(&rp, shallow
+ ? "--objects-edge-aggressive"
+ : "--objects-edge");
} else
argv_array_push(&rp, "--objects");
diff --git a/builtin/pack-redundant.c b/builtin/pack-redundant.c
index 649c3aa..d0532f6 100644
--- a/builtin/pack-redundant.c
+++ b/builtin/pack-redundant.c
@@ -11,7 +11,7 @@
#define BLKSIZE 512
static const char pack_redundant_usage[] =
-"git pack-redundant [ --verbose ] [ --alt-odb ] < --all | <.pack filename> ...>";
+"git pack-redundant [--verbose] [--alt-odb] (--all | <filename.pack>...)";
static int load_all_packs, verbose, alt_odb;
diff --git a/builtin/pack-refs.c b/builtin/pack-refs.c
index b20b1ec..39f9a55 100644
--- a/builtin/pack-refs.c
+++ b/builtin/pack-refs.c
@@ -3,7 +3,7 @@
#include "refs.h"
static char const * const pack_refs_usage[] = {
- N_("git pack-refs [options]"),
+ N_("git pack-refs [<options>]"),
NULL
};
diff --git a/builtin/prune-packed.c b/builtin/prune-packed.c
index f24a2c2..7cf900e 100644
--- a/builtin/prune-packed.c
+++ b/builtin/prune-packed.c
@@ -4,7 +4,7 @@
#include "parse-options.h"
static const char * const prune_packed_usage[] = {
- N_("git prune-packed [-n|--dry-run] [-q|--quiet]"),
+ N_("git prune-packed [-n | --dry-run] [-q | --quiet]"),
NULL
};
diff --git a/builtin/push.c b/builtin/push.c
index 12f5e69..fc771a9 100644
--- a/builtin/push.c
+++ b/builtin/push.c
@@ -487,6 +487,7 @@ int cmd_push(int argc, const char **argv, const char *prefix)
int flags = 0;
int tags = 0;
int rc;
+ int atomic = 0;
const char *repo = NULL; /* default repository */
struct option options[] = {
OPT__VERBOSITY(&verbosity),
@@ -518,6 +519,7 @@ int cmd_push(int argc, const char **argv, const char *prefix)
OPT_BIT(0, "follow-tags", &flags, N_("push missing but relevant tags"),
TRANSPORT_PUSH_FOLLOW_TAGS),
OPT_BIT(0, "signed", &flags, N_("GPG sign the push"), TRANSPORT_PUSH_CERT),
+ OPT_BOOL(0, "atomic", &atomic, N_("request atomic transaction on remote side")),
OPT_END()
};
@@ -533,6 +535,9 @@ int cmd_push(int argc, const char **argv, const char *prefix)
if (tags)
add_refspec("refs/tags/*");
+ if (atomic)
+ flags |= TRANSPORT_PUSH_ATOMIC;
+
if (argc > 0) {
repo = argv[0];
set_refspecs(argv + 1, argc - 1, repo);
diff --git a/builtin/receive-pack.c b/builtin/receive-pack.c
index e908d07..e0ce78e 100644
--- a/builtin/receive-pack.c
+++ b/builtin/receive-pack.c
@@ -26,7 +26,8 @@ enum deny_action {
DENY_UNCONFIGURED,
DENY_IGNORE,
DENY_WARN,
- DENY_REFUSE
+ DENY_REFUSE,
+ DENY_UPDATE_INSTEAD
};
static int deny_deletes;
@@ -37,9 +38,11 @@ static int receive_fsck_objects = -1;
static int transfer_fsck_objects = -1;
static int receive_unpack_limit = -1;
static int transfer_unpack_limit = -1;
+static int advertise_atomic_push = 1;
static int unpack_limit = 100;
static int report_status;
static int use_sideband;
+static int use_atomic;
static int quiet;
static int prefer_ofs_delta = 1;
static int auto_update_server_info;
@@ -66,6 +69,7 @@ static const char *NONCE_SLOP = "SLOP";
static const char *nonce_status;
static long nonce_stamp_slop;
static unsigned long nonce_stamp_slop_limit;
+static struct ref_transaction *transaction;
static enum deny_action parse_deny_action(const char *var, const char *value)
{
@@ -76,6 +80,8 @@ static enum deny_action parse_deny_action(const char *var, const char *value)
return DENY_WARN;
if (!strcasecmp(value, "refuse"))
return DENY_REFUSE;
+ if (!strcasecmp(value, "updateinstead"))
+ return DENY_UPDATE_INSTEAD;
}
if (git_config_bool(var, value))
return DENY_REFUSE;
@@ -157,6 +163,11 @@ static int receive_pack_config(const char *var, const char *value, void *cb)
return 0;
}
+ if (strcmp(var, "receive.advertiseatomic") == 0) {
+ advertise_atomic_push = git_config_bool(var, value);
+ return 0;
+ }
+
return git_default_config(var, value, cb);
}
@@ -172,6 +183,8 @@ static void show_ref(const char *path, const unsigned char *sha1)
strbuf_addstr(&cap,
"report-status delete-refs side-band-64k quiet");
+ if (advertise_atomic_push)
+ strbuf_addstr(&cap, " atomic");
if (prefer_ofs_delta)
strbuf_addstr(&cap, " ofs-delta");
if (push_cert_nonce)
@@ -730,11 +743,109 @@ static int update_shallow_ref(struct command *cmd, struct shallow_info *si)
return 0;
}
+static const char *push_to_deploy(unsigned char *sha1,
+ struct argv_array *env,
+ const char *work_tree)
+{
+ const char *update_refresh[] = {
+ "update-index", "-q", "--ignore-submodules", "--refresh", NULL
+ };
+ const char *diff_files[] = {
+ "diff-files", "--quiet", "--ignore-submodules", "--", NULL
+ };
+ const char *diff_index[] = {
+ "diff-index", "--quiet", "--cached", "--ignore-submodules",
+ "HEAD", "--", NULL
+ };
+ const char *read_tree[] = {
+ "read-tree", "-u", "-m", NULL, NULL
+ };
+ struct child_process child = CHILD_PROCESS_INIT;
+
+ child.argv = update_refresh;
+ child.env = env->argv;
+ child.dir = work_tree;
+ child.no_stdin = 1;
+ child.stdout_to_stderr = 1;
+ child.git_cmd = 1;
+ if (run_command(&child))
+ return "Up-to-date check failed";
+
+ /* run_command() does not clean up completely; reinitialize */
+ child_process_init(&child);
+ child.argv = diff_files;
+ child.env = env->argv;
+ child.dir = work_tree;
+ child.no_stdin = 1;
+ child.stdout_to_stderr = 1;
+ child.git_cmd = 1;
+ if (run_command(&child))
+ return "Working directory has unstaged changes";
+
+ child_process_init(&child);
+ child.argv = diff_index;
+ child.env = env->argv;
+ child.no_stdin = 1;
+ child.no_stdout = 1;
+ child.stdout_to_stderr = 0;
+ child.git_cmd = 1;
+ if (run_command(&child))
+ return "Working directory has staged changes";
+
+ read_tree[3] = sha1_to_hex(sha1);
+ child_process_init(&child);
+ child.argv = read_tree;
+ child.env = env->argv;
+ child.dir = work_tree;
+ child.no_stdin = 1;
+ child.no_stdout = 1;
+ child.stdout_to_stderr = 0;
+ child.git_cmd = 1;
+ if (run_command(&child))
+ return "Could not update working tree to new HEAD";
+
+ return NULL;
+}
+
+static const char *push_to_checkout_hook = "push-to-checkout";
+
+static const char *push_to_checkout(unsigned char *sha1,
+ struct argv_array *env,
+ const char *work_tree)
+{
+ argv_array_pushf(env, "GIT_WORK_TREE=%s", absolute_path(work_tree));
+ if (run_hook_le(env->argv, push_to_checkout_hook,
+ sha1_to_hex(sha1), NULL))
+ return "push-to-checkout hook declined";
+ else
+ return NULL;
+}
+
+static const char *update_worktree(unsigned char *sha1)
+{
+ const char *retval;
+ const char *work_tree = git_work_tree_cfg ? git_work_tree_cfg : "..";
+ struct argv_array env = ARGV_ARRAY_INIT;
+
+ if (is_bare_repository())
+ return "denyCurrentBranch = updateInstead needs a worktree";
+
+ argv_array_pushf(&env, "GIT_DIR=%s", absolute_path(get_git_dir()));
+
+ if (!find_hook(push_to_checkout_hook))
+ retval = push_to_deploy(sha1, &env, work_tree);
+ else
+ retval = push_to_checkout(sha1, &env, work_tree);
+
+ argv_array_clear(&env);
+ return retval;
+}
+
static const char *update(struct command *cmd, struct shallow_info *si)
{
const char *name = cmd->ref_name;
struct strbuf namespaced_name_buf = STRBUF_INIT;
- const char *namespaced_name;
+ const char *namespaced_name, *ret;
unsigned char *old_sha1 = cmd->old_sha1;
unsigned char *new_sha1 = cmd->new_sha1;
@@ -760,6 +871,11 @@ static const char *update(struct command *cmd, struct shallow_info *si)
if (deny_current_branch == DENY_UNCONFIGURED)
refuse_unconfigured_deny();
return "branch is currently checked out";
+ case DENY_UPDATE_INSTEAD:
+ ret = update_worktree(new_sha1);
+ if (ret)
+ return ret;
+ break;
}
}
@@ -784,10 +900,13 @@ static const char *update(struct command *cmd, struct shallow_info *si)
break;
case DENY_REFUSE:
case DENY_UNCONFIGURED:
+ case DENY_UPDATE_INSTEAD:
if (deny_delete_current == DENY_UNCONFIGURED)
refuse_unconfigured_deny_delete_current();
rp_error("refusing to delete the current branch: %s", name);
return "deletion of the current branch prohibited";
+ default:
+ return "Invalid denyDeleteCurrent setting";
}
}
}
@@ -821,6 +940,7 @@ static const char *update(struct command *cmd, struct shallow_info *si)
}
if (is_null_sha1(new_sha1)) {
+ struct strbuf err = STRBUF_INIT;
if (!parse_object(old_sha1)) {
old_sha1 = NULL;
if (ref_exists(name)) {
@@ -830,35 +950,36 @@ static const char *update(struct command *cmd, struct shallow_info *si)
cmd->did_not_exist = 1;
}
}
- if (delete_ref(namespaced_name, old_sha1, 0)) {
- rp_error("failed to delete %s", name);
+ if (ref_transaction_delete(transaction,
+ namespaced_name,
+ old_sha1,
+ 0, old_sha1 != NULL,
+ "push", &err)) {
+ rp_error("%s", err.buf);
+ strbuf_release(&err);
return "failed to delete";
}
+ strbuf_release(&err);
return NULL; /* good */
}
else {
struct strbuf err = STRBUF_INIT;
- struct ref_transaction *transaction;
-
if (shallow_update && si->shallow_ref[cmd->index] &&
update_shallow_ref(cmd, si))
return "shallow error";
- transaction = ref_transaction_begin(&err);
- if (!transaction ||
- ref_transaction_update(transaction, namespaced_name,
- new_sha1, old_sha1, 0, 1, "push",
- &err) ||
- ref_transaction_commit(transaction, &err)) {
- ref_transaction_free(transaction);
-
+ if (ref_transaction_update(transaction,
+ namespaced_name,
+ new_sha1, old_sha1,
+ 0, 1, "push",
+ &err)) {
rp_error("%s", err.buf);
strbuf_release(&err);
+
return "failed to update ref";
}
-
- ref_transaction_free(transaction);
strbuf_release(&err);
+
return NULL; /* good */
}
}
@@ -964,7 +1085,7 @@ static void check_aliased_updates(struct command *commands)
string_list_append(&ref_list, cmd->ref_name);
item->util = (void *)cmd;
}
- sort_string_list(&ref_list);
+ string_list_sort(&ref_list);
for (cmd = commands; cmd; cmd = cmd->next) {
if (!cmd->error_string)
@@ -1042,11 +1163,105 @@ static void reject_updates_to_hidden(struct command *commands)
}
}
+static int should_process_cmd(struct command *cmd)
+{
+ return !cmd->error_string && !cmd->skip_update;
+}
+
+static void warn_if_skipped_connectivity_check(struct command *commands,
+ struct shallow_info *si)
+{
+ struct command *cmd;
+ int checked_connectivity = 1;
+
+ for (cmd = commands; cmd; cmd = cmd->next) {
+ if (should_process_cmd(cmd) && si->shallow_ref[cmd->index]) {
+ error("BUG: connectivity check has not been run on ref %s",
+ cmd->ref_name);
+ checked_connectivity = 0;
+ }
+ }
+ if (!checked_connectivity)
+ die("BUG: connectivity check skipped???");
+}
+
+static void execute_commands_non_atomic(struct command *commands,
+ struct shallow_info *si)
+{
+ struct command *cmd;
+ struct strbuf err = STRBUF_INIT;
+
+ for (cmd = commands; cmd; cmd = cmd->next) {
+ if (!should_process_cmd(cmd))
+ continue;
+
+ transaction = ref_transaction_begin(&err);
+ if (!transaction) {
+ rp_error("%s", err.buf);
+ strbuf_reset(&err);
+ cmd->error_string = "transaction failed to start";
+ continue;
+ }
+
+ cmd->error_string = update(cmd, si);
+
+ if (!cmd->error_string
+ && ref_transaction_commit(transaction, &err)) {
+ rp_error("%s", err.buf);
+ strbuf_reset(&err);
+ cmd->error_string = "failed to update ref";
+ }
+ ref_transaction_free(transaction);
+ }
+ strbuf_release(&err);
+}
+
+static void execute_commands_atomic(struct command *commands,
+ struct shallow_info *si)
+{
+ struct command *cmd;
+ struct strbuf err = STRBUF_INIT;
+ const char *reported_error = "atomic push failure";
+
+ transaction = ref_transaction_begin(&err);
+ if (!transaction) {
+ rp_error("%s", err.buf);
+ strbuf_reset(&err);
+ reported_error = "transaction failed to start";
+ goto failure;
+ }
+
+ for (cmd = commands; cmd; cmd = cmd->next) {
+ if (!should_process_cmd(cmd))
+ continue;
+
+ cmd->error_string = update(cmd, si);
+
+ if (cmd->error_string)
+ goto failure;
+ }
+
+ if (ref_transaction_commit(transaction, &err)) {
+ rp_error("%s", err.buf);
+ reported_error = "atomic transaction failed";
+ goto failure;
+ }
+ goto cleanup;
+
+failure:
+ for (cmd = commands; cmd; cmd = cmd->next)
+ if (!cmd->error_string)
+ cmd->error_string = reported_error;
+
+cleanup:
+ ref_transaction_free(transaction);
+ strbuf_release(&err);
+}
+
static void execute_commands(struct command *commands,
const char *unpacker_error,
struct shallow_info *si)
{
- int checked_connectivity;
struct command *cmd;
unsigned char sha1[20];
struct iterate_data data;
@@ -1077,27 +1292,13 @@ static void execute_commands(struct command *commands,
free(head_name_to_free);
head_name = head_name_to_free = resolve_refdup("HEAD", 0, sha1, NULL);
- checked_connectivity = 1;
- for (cmd = commands; cmd; cmd = cmd->next) {
- if (cmd->error_string)
- continue;
-
- if (cmd->skip_update)
- continue;
-
- cmd->error_string = update(cmd, si);
- if (shallow_update && !cmd->error_string &&
- si->shallow_ref[cmd->index]) {
- error("BUG: connectivity check has not been run on ref %s",
- cmd->ref_name);
- checked_connectivity = 0;
- }
- }
+ if (use_atomic)
+ execute_commands_atomic(commands, si);
+ else
+ execute_commands_non_atomic(commands, si);
- if (shallow_update && !checked_connectivity)
- error("BUG: run 'git fsck' for safety.\n"
- "If there are errors, try to remove "
- "the reported refs above");
+ if (shallow_update)
+ warn_if_skipped_connectivity_check(commands, si);
}
static struct command **queue_command(struct command **tail,
@@ -1179,6 +1380,9 @@ static struct command *read_head_info(struct sha1_array *shallow)
use_sideband = LARGE_PACKET_MAX;
if (parse_feature_request(feature_list, "quiet"))
quiet = 1;
+ if (advertise_atomic_push
+ && parse_feature_request(feature_list, "atomic"))
+ use_atomic = 1;
}
if (!strcmp(line, "push-cert")) {
diff --git a/builtin/reflog.c b/builtin/reflog.c
index 2d85d26..49c64f9 100644
--- a/builtin/reflog.c
+++ b/builtin/reflog.c
@@ -22,18 +22,13 @@ static unsigned long default_reflog_expire_unreachable;
struct cmd_reflog_expire_cb {
struct rev_info revs;
- int dry_run;
int stalefix;
- int rewrite;
- int updateref;
- int verbose;
unsigned long expire_total;
unsigned long expire_unreachable;
int recno;
};
-struct expire_reflog_cb {
- FILE *newlog;
+struct expire_reflog_policy_cb {
enum {
UE_NORMAL,
UE_ALWAYS,
@@ -41,14 +36,16 @@ struct expire_reflog_cb {
} unreachable_expire_kind;
struct commit_list *mark_list;
unsigned long mark_limit;
- struct cmd_reflog_expire_cb *cmd;
- unsigned char last_kept_sha1[20];
+ struct cmd_reflog_expire_cb cmd;
+ struct commit *tip_commit;
+ struct commit_list *tips;
};
struct collected_reflog {
unsigned char sha1[20];
char reflog[FLEX_ARRAY];
};
+
struct collect_reflog_cb {
struct collected_reflog **e;
int alloc;
@@ -220,7 +217,7 @@ static int keep_entry(struct commit **it, unsigned char *sha1)
* the expire_limit and queue them back, so that the caller can call
* us again to restart the traversal with longer expire_limit.
*/
-static void mark_reachable(struct expire_reflog_cb *cb)
+static void mark_reachable(struct expire_reflog_policy_cb *cb)
{
struct commit *commit;
struct commit_list *pending;
@@ -259,7 +256,7 @@ static void mark_reachable(struct expire_reflog_cb *cb)
cb->mark_list = leftover;
}
-static int unreachable(struct expire_reflog_cb *cb, struct commit *commit, unsigned char *sha1)
+static int unreachable(struct expire_reflog_policy_cb *cb, struct commit *commit, unsigned char *sha1)
{
/*
* We may or may not have the commit yet - if not, look it
@@ -288,55 +285,39 @@ static int unreachable(struct expire_reflog_cb *cb, struct commit *commit, unsig
return !(commit->object.flags & REACHABLE);
}
-static int expire_reflog_ent(unsigned char *osha1, unsigned char *nsha1,
- const char *email, unsigned long timestamp, int tz,
- const char *message, void *cb_data)
+/*
+ * Return true iff the specified reflog entry should be expired.
+ */
+static int should_expire_reflog_ent(unsigned char *osha1, unsigned char *nsha1,
+ const char *email, unsigned long timestamp, int tz,
+ const char *message, void *cb_data)
{
- struct expire_reflog_cb *cb = cb_data;
+ struct expire_reflog_policy_cb *cb = cb_data;
struct commit *old, *new;
- if (timestamp < cb->cmd->expire_total)
- goto prune;
-
- if (cb->cmd->rewrite)
- osha1 = cb->last_kept_sha1;
+ if (timestamp < cb->cmd.expire_total)
+ return 1;
old = new = NULL;
- if (cb->cmd->stalefix &&
+ if (cb->cmd.stalefix &&
(!keep_entry(&old, osha1) || !keep_entry(&new, nsha1)))
- goto prune;
+ return 1;
- if (timestamp < cb->cmd->expire_unreachable) {
+ if (timestamp < cb->cmd.expire_unreachable) {
if (cb->unreachable_expire_kind == UE_ALWAYS)
- goto prune;
+ return 1;
if (unreachable(cb, old, osha1) || unreachable(cb, new, nsha1))
- goto prune;
+ return 1;
}
- if (cb->cmd->recno && --(cb->cmd->recno) == 0)
- goto prune;
-
- if (cb->newlog) {
- char sign = (tz < 0) ? '-' : '+';
- int zone = (tz < 0) ? (-tz) : tz;
- fprintf(cb->newlog, "%s %s %s %lu %c%04d\t%s",
- sha1_to_hex(osha1), sha1_to_hex(nsha1),
- email, timestamp, sign, zone,
- message);
- hashcpy(cb->last_kept_sha1, nsha1);
- }
- if (cb->cmd->verbose)
- printf("keep %s", message);
- return 0;
- prune:
- if (!cb->newlog)
- printf("would prune %s", message);
- else if (cb->cmd->verbose)
- printf("prune %s", message);
+ if (cb->cmd.recno && --(cb->cmd.recno) == 0)
+ return 1;
+
return 0;
}
-static int push_tip_to_list(const char *refname, const unsigned char *sha1, int flags, void *cb_data)
+static int push_tip_to_list(const char *refname, const unsigned char *sha1,
+ int flags, void *cb_data)
{
struct commit_list **list = cb_data;
struct commit *tip_commit;
@@ -349,104 +330,56 @@ static int push_tip_to_list(const char *refname, const unsigned char *sha1, int
return 0;
}
-static int expire_reflog(const char *ref, const unsigned char *sha1, int unused, void *cb_data)
+static void reflog_expiry_prepare(const char *refname,
+ const unsigned char *sha1,
+ void *cb_data)
{
- struct cmd_reflog_expire_cb *cmd = cb_data;
- struct expire_reflog_cb cb;
- struct ref_lock *lock;
- char *log_file, *newlog_path = NULL;
- struct commit *tip_commit;
- struct commit_list *tips;
- int status = 0;
-
- memset(&cb, 0, sizeof(cb));
-
- /*
- * we take the lock for the ref itself to prevent it from
- * getting updated.
- */
- lock = lock_any_ref_for_update(ref, sha1, 0, NULL);
- if (!lock)
- return error("cannot lock ref '%s'", ref);
- log_file = git_pathdup("logs/%s", ref);
- if (!reflog_exists(ref))
- goto finish;
- if (!cmd->dry_run) {
- newlog_path = git_pathdup("logs/%s.lock", ref);
- cb.newlog = fopen(newlog_path, "w");
- }
-
- cb.cmd = cmd;
+ struct expire_reflog_policy_cb *cb = cb_data;
- if (!cmd->expire_unreachable || !strcmp(ref, "HEAD")) {
- tip_commit = NULL;
- cb.unreachable_expire_kind = UE_HEAD;
+ if (!cb->cmd.expire_unreachable || !strcmp(refname, "HEAD")) {
+ cb->tip_commit = NULL;
+ cb->unreachable_expire_kind = UE_HEAD;
} else {
- tip_commit = lookup_commit_reference_gently(sha1, 1);
- if (!tip_commit)
- cb.unreachable_expire_kind = UE_ALWAYS;
+ cb->tip_commit = lookup_commit_reference_gently(sha1, 1);
+ if (!cb->tip_commit)
+ cb->unreachable_expire_kind = UE_ALWAYS;
else
- cb.unreachable_expire_kind = UE_NORMAL;
+ cb->unreachable_expire_kind = UE_NORMAL;
}
- if (cmd->expire_unreachable <= cmd->expire_total)
- cb.unreachable_expire_kind = UE_ALWAYS;
+ if (cb->cmd.expire_unreachable <= cb->cmd.expire_total)
+ cb->unreachable_expire_kind = UE_ALWAYS;
- cb.mark_list = NULL;
- tips = NULL;
- if (cb.unreachable_expire_kind != UE_ALWAYS) {
- if (cb.unreachable_expire_kind == UE_HEAD) {
+ cb->mark_list = NULL;
+ cb->tips = NULL;
+ if (cb->unreachable_expire_kind != UE_ALWAYS) {
+ if (cb->unreachable_expire_kind == UE_HEAD) {
struct commit_list *elem;
- for_each_ref(push_tip_to_list, &tips);
- for (elem = tips; elem; elem = elem->next)
- commit_list_insert(elem->item, &cb.mark_list);
+ for_each_ref(push_tip_to_list, &cb->tips);
+ for (elem = cb->tips; elem; elem = elem->next)
+ commit_list_insert(elem->item, &cb->mark_list);
} else {
- commit_list_insert(tip_commit, &cb.mark_list);
+ commit_list_insert(cb->tip_commit, &cb->mark_list);
}
- cb.mark_limit = cmd->expire_total;
- mark_reachable(&cb);
+ cb->mark_limit = cb->cmd.expire_total;
+ mark_reachable(cb);
}
+}
- for_each_reflog_ent(ref, expire_reflog_ent, &cb);
+static void reflog_expiry_cleanup(void *cb_data)
+{
+ struct expire_reflog_policy_cb *cb = cb_data;
- if (cb.unreachable_expire_kind != UE_ALWAYS) {
- if (cb.unreachable_expire_kind == UE_HEAD) {
+ if (cb->unreachable_expire_kind != UE_ALWAYS) {
+ if (cb->unreachable_expire_kind == UE_HEAD) {
struct commit_list *elem;
- for (elem = tips; elem; elem = elem->next)
+ for (elem = cb->tips; elem; elem = elem->next)
clear_commit_marks(elem->item, REACHABLE);
- free_commit_list(tips);
+ free_commit_list(cb->tips);
} else {
- clear_commit_marks(tip_commit, REACHABLE);
+ clear_commit_marks(cb->tip_commit, REACHABLE);
}
}
- finish:
- if (cb.newlog) {
- if (fclose(cb.newlog)) {
- status |= error("%s: %s", strerror(errno),
- newlog_path);
- unlink(newlog_path);
- } else if (cmd->updateref &&
- (write_in_full(lock->lock_fd,
- sha1_to_hex(cb.last_kept_sha1), 40) != 40 ||
- write_str_in_full(lock->lock_fd, "\n") != 1 ||
- close_ref(lock) < 0)) {
- status |= error("Couldn't write %s",
- lock->lk->filename.buf);
- unlink(newlog_path);
- } else if (rename(newlog_path, log_file)) {
- status |= error("cannot rename %s to %s",
- newlog_path, log_file);
- unlink(newlog_path);
- } else if (cmd->updateref && commit_ref(lock)) {
- status |= error("Couldn't set %s", lock->ref_name);
- } else {
- adjust_shared_perm(log_file);
- }
- }
- free(newlog_path);
- free(log_file);
- unlock_ref(lock);
- return status;
}
static int collect_reflog(const char *ref, const unsigned char *sha1, int unused, void *cb_data)
@@ -590,10 +523,11 @@ static void set_reflog_expiry_param(struct cmd_reflog_expire_cb *cb, int slot, c
static int cmd_reflog_expire(int argc, const char **argv, const char *prefix)
{
- struct cmd_reflog_expire_cb cb;
+ struct expire_reflog_policy_cb cb;
unsigned long now = time(NULL);
int i, status, do_all;
int explicit_expiry = 0;
+ unsigned int flags = 0;
default_reflog_expire_unreachable = now - 30 * 24 * 3600;
default_reflog_expire = now - 90 * 24 * 3600;
@@ -603,33 +537,33 @@ static int cmd_reflog_expire(int argc, const char **argv, const char *prefix)
do_all = status = 0;
memset(&cb, 0, sizeof(cb));
- cb.expire_total = default_reflog_expire;
- cb.expire_unreachable = default_reflog_expire_unreachable;
+ cb.cmd.expire_total = default_reflog_expire;
+ cb.cmd.expire_unreachable = default_reflog_expire_unreachable;
for (i = 1; i < argc; i++) {
const char *arg = argv[i];
if (!strcmp(arg, "--dry-run") || !strcmp(arg, "-n"))
- cb.dry_run = 1;
+ flags |= EXPIRE_REFLOGS_DRY_RUN;
else if (starts_with(arg, "--expire=")) {
- if (parse_expiry_date(arg + 9, &cb.expire_total))
+ if (parse_expiry_date(arg + 9, &cb.cmd.expire_total))
die(_("'%s' is not a valid timestamp"), arg);
explicit_expiry |= EXPIRE_TOTAL;
}
else if (starts_with(arg, "--expire-unreachable=")) {
- if (parse_expiry_date(arg + 21, &cb.expire_unreachable))
+ if (parse_expiry_date(arg + 21, &cb.cmd.expire_unreachable))
die(_("'%s' is not a valid timestamp"), arg);
explicit_expiry |= EXPIRE_UNREACH;
}
else if (!strcmp(arg, "--stale-fix"))
- cb.stalefix = 1;
+ cb.cmd.stalefix = 1;
else if (!strcmp(arg, "--rewrite"))
- cb.rewrite = 1;
+ flags |= EXPIRE_REFLOGS_REWRITE;
else if (!strcmp(arg, "--updateref"))
- cb.updateref = 1;
+ flags |= EXPIRE_REFLOGS_UPDATE_REF;
else if (!strcmp(arg, "--all"))
do_all = 1;
else if (!strcmp(arg, "--verbose"))
- cb.verbose = 1;
+ flags |= EXPIRE_REFLOGS_VERBOSE;
else if (!strcmp(arg, "--")) {
i++;
break;
@@ -645,12 +579,12 @@ static int cmd_reflog_expire(int argc, const char **argv, const char *prefix)
* even in older repository. We cannot trust what's reachable
* from reflog if the repository was pruned with older git.
*/
- if (cb.stalefix) {
- init_revisions(&cb.revs, prefix);
- if (cb.verbose)
+ if (cb.cmd.stalefix) {
+ init_revisions(&cb.cmd.revs, prefix);
+ if (flags & EXPIRE_REFLOGS_VERBOSE)
printf("Marking reachable objects...");
- mark_reachable_objects(&cb.revs, 0, 0, NULL);
- if (cb.verbose)
+ mark_reachable_objects(&cb.cmd.revs, 0, 0, NULL);
+ if (flags & EXPIRE_REFLOGS_VERBOSE)
putchar('\n');
}
@@ -662,8 +596,12 @@ static int cmd_reflog_expire(int argc, const char **argv, const char *prefix)
for_each_reflog(collect_reflog, &collected);
for (i = 0; i < collected.nr; i++) {
struct collected_reflog *e = collected.e[i];
- set_reflog_expiry_param(&cb, explicit_expiry, e->reflog);
- status |= expire_reflog(e->reflog, e->sha1, 0, &cb);
+ set_reflog_expiry_param(&cb.cmd, explicit_expiry, e->reflog);
+ status |= reflog_expire(e->reflog, e->sha1, flags,
+ reflog_expiry_prepare,
+ should_expire_reflog_ent,
+ reflog_expiry_cleanup,
+ &cb);
free(e);
}
free(collected.e);
@@ -676,8 +614,12 @@ static int cmd_reflog_expire(int argc, const char **argv, const char *prefix)
status |= error("%s points nowhere!", argv[i]);
continue;
}
- set_reflog_expiry_param(&cb, explicit_expiry, ref);
- status |= expire_reflog(ref, sha1, 0, &cb);
+ set_reflog_expiry_param(&cb.cmd, explicit_expiry, ref);
+ status |= reflog_expire(ref, sha1, flags,
+ reflog_expiry_prepare,
+ should_expire_reflog_ent,
+ reflog_expiry_cleanup,
+ &cb);
}
return status;
}
@@ -686,29 +628,30 @@ static int count_reflog_ent(unsigned char *osha1, unsigned char *nsha1,
const char *email, unsigned long timestamp, int tz,
const char *message, void *cb_data)
{
- struct cmd_reflog_expire_cb *cb = cb_data;
- if (!cb->expire_total || timestamp < cb->expire_total)
- cb->recno++;
+ struct expire_reflog_policy_cb *cb = cb_data;
+ if (!cb->cmd.expire_total || timestamp < cb->cmd.expire_total)
+ cb->cmd.recno++;
return 0;
}
static int cmd_reflog_delete(int argc, const char **argv, const char *prefix)
{
- struct cmd_reflog_expire_cb cb;
+ struct expire_reflog_policy_cb cb;
int i, status = 0;
+ unsigned int flags = 0;
memset(&cb, 0, sizeof(cb));
for (i = 1; i < argc; i++) {
const char *arg = argv[i];
if (!strcmp(arg, "--dry-run") || !strcmp(arg, "-n"))
- cb.dry_run = 1;
+ flags |= EXPIRE_REFLOGS_DRY_RUN;
else if (!strcmp(arg, "--rewrite"))
- cb.rewrite = 1;
+ flags |= EXPIRE_REFLOGS_REWRITE;
else if (!strcmp(arg, "--updateref"))
- cb.updateref = 1;
+ flags |= EXPIRE_REFLOGS_UPDATE_REF;
else if (!strcmp(arg, "--verbose"))
- cb.verbose = 1;
+ flags |= EXPIRE_REFLOGS_VERBOSE;
else if (!strcmp(arg, "--")) {
i++;
break;
@@ -740,15 +683,19 @@ static int cmd_reflog_delete(int argc, const char **argv, const char *prefix)
recno = strtoul(spec + 2, &ep, 10);
if (*ep == '}') {
- cb.recno = -recno;
+ cb.cmd.recno = -recno;
for_each_reflog_ent(ref, count_reflog_ent, &cb);
} else {
- cb.expire_total = approxidate(spec + 2);
+ cb.cmd.expire_total = approxidate(spec + 2);
for_each_reflog_ent(ref, count_reflog_ent, &cb);
- cb.expire_total = 0;
+ cb.cmd.expire_total = 0;
}
- status |= expire_reflog(ref, sha1, 0, &cb);
+ status |= reflog_expire(ref, sha1, flags,
+ reflog_expiry_prepare,
+ should_expire_reflog_ent,
+ reflog_expiry_cleanup,
+ &cb);
free(ref);
}
return status;
diff --git a/builtin/remote.c b/builtin/remote.c
index 7f28f92..5d3ab90 100644
--- a/builtin/remote.c
+++ b/builtin/remote.c
@@ -10,10 +10,10 @@
static const char * const builtin_remote_usage[] = {
N_("git remote [-v | --verbose]"),
- N_("git remote add [-t <branch>] [-m <master>] [-f] [--tags|--no-tags] [--mirror=<fetch|push>] <name> <url>"),
+ N_("git remote add [-t <branch>] [-m <master>] [-f] [--tags | --no-tags] [--mirror=<fetch|push>] <name> <url>"),
N_("git remote rename <old> <new>"),
N_("git remote remove <name>"),
- N_("git remote set-head <name> (-a | --auto | -d | --delete |<branch>)"),
+ N_("git remote set-head <name> (-a | --auto | -d | --delete | <branch>)"),
N_("git remote [-v | --verbose] show [-n] <name>"),
N_("git remote prune [-n | --dry-run] <name>"),
N_("git remote [-v | --verbose] update [-p | --prune] [(<group> | <remote>)...]"),
@@ -180,7 +180,9 @@ static int add(int argc, const char **argv)
url = argv[1];
remote = remote_get(name);
- if (remote && (remote->url_nr > 1 || strcmp(name, remote->url[0]) ||
+ if (remote && (remote->url_nr > 1 ||
+ (strcmp(name, remote->url[0]) &&
+ strcmp(url, remote->url[0])) ||
remote->fetch_refspec_nr))
die(_("remote %s already exists."), name);
@@ -352,9 +354,9 @@ static int get_ref_states(const struct ref *remote_refs, struct ref_states *stat
free_refs(stale_refs);
free_refs(fetch_map);
- sort_string_list(&states->new);
- sort_string_list(&states->tracked);
- sort_string_list(&states->stale);
+ string_list_sort(&states->new);
+ string_list_sort(&states->tracked);
+ string_list_sort(&states->stale);
return 0;
}
@@ -750,16 +752,11 @@ static int mv(int argc, const char **argv)
static int remove_branches(struct string_list *branches)
{
struct strbuf err = STRBUF_INIT;
- const char **branch_names;
int i, result = 0;
- branch_names = xmalloc(branches->nr * sizeof(*branch_names));
- for (i = 0; i < branches->nr; i++)
- branch_names[i] = branches->items[i].string;
- if (repack_without_refs(branch_names, branches->nr, &err))
+ if (repack_without_refs(branches, &err))
result |= error("%s", err.buf);
strbuf_release(&err);
- free(branch_names);
for (i = 0; i < branches->nr; i++) {
struct string_list_item *item = branches->items + i;
@@ -914,7 +911,7 @@ static int get_remote_ref_states(const char *name,
get_push_ref_states(remote_refs, states);
} else {
for_each_ref(append_ref_to_tracked_list, states);
- sort_string_list(&states->tracked);
+ string_list_sort(&states->tracked);
get_push_ref_states_noquery(states);
}
@@ -1133,7 +1130,7 @@ static int show_all(void)
if (!result) {
int i;
- sort_string_list(&list);
+ string_list_sort(&list);
for (i = 0; i < list.nr; i++) {
struct string_list_item *item = list.items + i;
if (verbose)
@@ -1314,10 +1311,10 @@ static int set_head(int argc, const char **argv)
static int prune_remote(const char *remote, int dry_run)
{
- int result = 0, i;
+ int result = 0;
struct ref_states states;
- struct string_list delete_refs_list = STRING_LIST_INIT_NODUP;
- const char **delete_refs;
+ struct string_list refs_to_prune = STRING_LIST_INIT_NODUP;
+ struct string_list_item *item;
const char *dangling_msg = dry_run
? _(" %s will become dangling!")
: _(" %s has become dangling!");
@@ -1325,30 +1322,30 @@ static int prune_remote(const char *remote, int dry_run)
memset(&states, 0, sizeof(states));
get_remote_ref_states(remote, &states, GET_REF_STATES);
- if (states.stale.nr) {
- printf_ln(_("Pruning %s"), remote);
- printf_ln(_("URL: %s"),
- states.remote->url_nr
- ? states.remote->url[0]
- : _("(no URL)"));
-
- delete_refs = xmalloc(states.stale.nr * sizeof(*delete_refs));
- for (i = 0; i < states.stale.nr; i++)
- delete_refs[i] = states.stale.items[i].util;
- if (!dry_run) {
- struct strbuf err = STRBUF_INIT;
- if (repack_without_refs(delete_refs, states.stale.nr,
- &err))
- result |= error("%s", err.buf);
- strbuf_release(&err);
- }
- free(delete_refs);
+ if (!states.stale.nr) {
+ free_remote_ref_states(&states);
+ return 0;
}
- for (i = 0; i < states.stale.nr; i++) {
- const char *refname = states.stale.items[i].util;
+ printf_ln(_("Pruning %s"), remote);
+ printf_ln(_("URL: %s"),
+ states.remote->url_nr
+ ? states.remote->url[0]
+ : _("(no URL)"));
+
+ for_each_string_list_item(item, &states.stale)
+ string_list_append(&refs_to_prune, item->util);
+ string_list_sort(&refs_to_prune);
+
+ if (!dry_run) {
+ struct strbuf err = STRBUF_INIT;
+ if (repack_without_refs(&refs_to_prune, &err))
+ result |= error("%s", err.buf);
+ strbuf_release(&err);
+ }
- string_list_insert(&delete_refs_list, refname);
+ for_each_string_list_item(item, &states.stale) {
+ const char *refname = item->util;
if (!dry_run)
result |= delete_ref(refname, NULL, 0);
@@ -1361,9 +1358,9 @@ static int prune_remote(const char *remote, int dry_run)
abbrev_ref(refname, "refs/remotes/"));
}
- warn_dangling_symrefs(stdout, dangling_msg, &delete_refs_list);
- string_list_clear(&delete_refs_list, 0);
+ warn_dangling_symrefs(stdout, dangling_msg, &refs_to_prune);
+ string_list_clear(&refs_to_prune, 0);
free_remote_ref_states(&states);
return result;
}
diff --git a/builtin/repack.c b/builtin/repack.c
index 83e91c7..28fbc70 100644
--- a/builtin/repack.c
+++ b/builtin/repack.c
@@ -14,7 +14,7 @@ static int write_bitmaps;
static char *packdir, *packtmp;
static const char *const git_repack_usage[] = {
- N_("git repack [options]"),
+ N_("git repack [<options>]"),
NULL
};
@@ -376,7 +376,7 @@ int cmd_repack(int argc, const char **argv, const char *prefix)
if (delete_redundant) {
int opts = 0;
- sort_string_list(&names);
+ string_list_sort(&names);
for_each_string_list_item(item, &existing_packs) {
char *sha1;
size_t len = strlen(item->string);
diff --git a/builtin/rerere.c b/builtin/rerere.c
index 98eb8c5..7afadd2 100644
--- a/builtin/rerere.c
+++ b/builtin/rerere.c
@@ -9,7 +9,7 @@
#include "pathspec.h"
static const char * const rerere_usage[] = {
- N_("git rerere [clear | forget path... | status | remaining | diff | gc]"),
+ N_("git rerere [clear | forget <path>... | status | remaining | diff | gc]"),
NULL,
};
diff --git a/builtin/rev-parse.c b/builtin/rev-parse.c
index 35d3c43..3626c61 100644
--- a/builtin/rev-parse.c
+++ b/builtin/rev-parse.c
@@ -279,7 +279,7 @@ static int try_difference(const char *arg)
struct commit *a, *b;
a = lookup_commit_reference(sha1);
b = lookup_commit_reference(end);
- exclude = get_merge_bases(a, b, 1);
+ exclude = get_merge_bases(a, b);
while (exclude) {
struct commit_list *n = exclude->next;
show_rev(REVERSED,
@@ -358,7 +358,7 @@ static int cmd_parseopt(int argc, const char **argv, const char *prefix)
{
static int keep_dashdash = 0, stop_at_non_option = 0;
static char const * const parseopt_usage[] = {
- N_("git rev-parse --parseopt [options] -- [<args>...]"),
+ N_("git rev-parse --parseopt [<options>] -- [<args>...]"),
NULL
};
static struct option parseopt_opts[] = {
@@ -496,9 +496,9 @@ static void die_no_single_rev(int quiet)
}
static const char builtin_rev_parse_usage[] =
-N_("git rev-parse --parseopt [options] -- [<args>...]\n"
+N_("git rev-parse --parseopt [<options>] -- [<args>...]\n"
" or: git rev-parse --sq-quote [<arg>...]\n"
- " or: git rev-parse [options] [<arg>...]\n"
+ " or: git rev-parse [<options>] [<arg>...]\n"
"\n"
"Run \"git rev-parse --parseopt -h\" for more information on the first usage.");
diff --git a/builtin/revert.c b/builtin/revert.c
index f9ed5bd..56a2c36 100644
--- a/builtin/revert.c
+++ b/builtin/revert.c
@@ -19,13 +19,13 @@
*/
static const char * const revert_usage[] = {
- N_("git revert [options] <commit-ish>..."),
+ N_("git revert [<options>] <commit-ish>..."),
N_("git revert <subcommand>"),
NULL
};
static const char * const cherry_pick_usage[] = {
- N_("git cherry-pick [options] <commit-ish>..."),
+ N_("git cherry-pick [<options>] <commit-ish>..."),
N_("git cherry-pick <subcommand>"),
NULL
};
diff --git a/builtin/rm.c b/builtin/rm.c
index d8a9c86..3304bff 100644
--- a/builtin/rm.c
+++ b/builtin/rm.c
@@ -14,7 +14,7 @@
#include "pathspec.h"
static const char * const builtin_rm_usage[] = {
- N_("git rm [options] [--] <file>..."),
+ N_("git rm [<options>] [--] <file>..."),
NULL
};
diff --git a/builtin/send-pack.c b/builtin/send-pack.c
index b564a77..b961e5a 100644
--- a/builtin/send-pack.c
+++ b/builtin/send-pack.c
@@ -13,7 +13,7 @@
#include "sha1-array.h"
static const char send_pack_usage[] =
-"git send-pack [--all | --mirror] [--dry-run] [--force] [--receive-pack=<git-receive-pack>] [--verbose] [--thin] [<host>:]<directory> [<ref>...]\n"
+"git send-pack [--all | --mirror] [--dry-run] [--force] [--receive-pack=<git-receive-pack>] [--verbose] [--thin] [--atomic] [<host>:]<directory> [<ref>...]\n"
" --all and explicit <ref> specification are mutually exclusive.";
static struct send_pack_args args;
@@ -170,6 +170,10 @@ int cmd_send_pack(int argc, const char **argv, const char *prefix)
args.use_thin_pack = 1;
continue;
}
+ if (!strcmp(arg, "--atomic")) {
+ args.atomic = 1;
+ continue;
+ }
if (!strcmp(arg, "--stateless-rpc")) {
args.stateless_rpc = 1;
continue;
diff --git a/builtin/shortlog.c b/builtin/shortlog.c
index 4b7e536..c0bab6a 100644
--- a/builtin/shortlog.c
+++ b/builtin/shortlog.c
@@ -10,7 +10,7 @@
#include "parse-options.h"
static char const * const shortlog_usage[] = {
- N_("git shortlog [<options>] [<revision range>] [[--] [<path>...]]"),
+ N_("git shortlog [<options>] [<revision-range>] [[--] [<path>...]]"),
NULL
};
diff --git a/builtin/show-branch.c b/builtin/show-branch.c
index 270e39c..f3fb5fb 100644
--- a/builtin/show-branch.c
+++ b/builtin/show-branch.c
@@ -6,8 +6,11 @@
#include "parse-options.h"
static const char* show_branch_usage[] = {
- N_("git show-branch [-a|--all] [-r|--remotes] [--topo-order | --date-order] [--current] [--color[=<when>] | --no-color] [--sparse] [--more=<n> | --list | --independent | --merge-base] [--no-name | --sha1-name] [--topics] [(<rev> | <glob>)...]"),
- N_("git show-branch (-g|--reflog)[=<n>[,<base>]] [--list] [<ref>]"),
+ N_("git show-branch [-a | --all] [-r | --remotes] [--topo-order | --date-order]\n"
+ " [--current] [--color[=<when>] | --no-color] [--sparse]\n"
+ " [--more=<n> | --list | --independent | --merge-base]\n"
+ " [--no-name | --sha1-name] [--topics] [(<rev> | <glob>)...]"),
+ N_("git show-branch (-g | --reflog)[=<n>[,<base>]] [--list] [<ref>]"),
NULL
};
diff --git a/builtin/show-ref.c b/builtin/show-ref.c
index 5ba1f30..afb1030 100644
--- a/builtin/show-ref.c
+++ b/builtin/show-ref.c
@@ -7,7 +7,7 @@
#include "parse-options.h"
static const char * const show_ref_usage[] = {
- N_("git show-ref [-q|--quiet] [--verify] [--head] [-d|--dereference] [-s|--hash[=<n>]] [--abbrev[=<n>]] [--tags] [--heads] [--] [pattern*] "),
+ N_("git show-ref [-q | --quiet] [--verify] [--head] [-d | --dereference] [-s | --hash[=<n>]] [--abbrev[=<n>]] [--tags] [--heads] [--] [<pattern>...]"),
N_("git show-ref --exclude-existing[=pattern] < ref-list"),
NULL
};
diff --git a/builtin/symbolic-ref.c b/builtin/symbolic-ref.c
index 29fb3f1..ce0fde7 100644
--- a/builtin/symbolic-ref.c
+++ b/builtin/symbolic-ref.c
@@ -4,8 +4,8 @@
#include "parse-options.h"
static const char * const git_symbolic_ref_usage[] = {
- N_("git symbolic-ref [options] name [ref]"),
- N_("git symbolic-ref -d [-q] name"),
+ N_("git symbolic-ref [<options>] <name> [<ref>]"),
+ N_("git symbolic-ref -d [-q] <name>"),
NULL
};
diff --git a/builtin/tag.c b/builtin/tag.c
index e633f4e..6dc85a9 100644
--- a/builtin/tag.c
+++ b/builtin/tag.c
@@ -19,9 +19,9 @@
#include "column.h"
static const char * const git_tag_usage[] = {
- N_("git tag [-a|-s|-u <key-id>] [-f] [-m <msg>|-F <file>] <tagname> [<head>]"),
+ N_("git tag [-a | -s | -u <key-id>] [-f] [-m <msg> | -F <file>] <tagname> [<head>]"),
N_("git tag -d <tagname>..."),
- N_("git tag -l [-n[<num>]] [--contains <commit>] [--points-at <object>] "
+ N_("git tag -l [-n[<num>]] [--contains <commit>] [--points-at <object>]"
"\n\t\t[<pattern>...]"),
N_("git tag -v <tagname>..."),
NULL
diff --git a/builtin/unpack-objects.c b/builtin/unpack-objects.c
index 855d94b..ac66672 100644
--- a/builtin/unpack-objects.c
+++ b/builtin/unpack-objects.c
@@ -91,7 +91,7 @@ static void use(int bytes)
static void *get_data(unsigned long size)
{
git_zstream stream;
- void *buf = xmalloc(size);
+ void *buf = xmallocz(size);
memset(&stream, 0, sizeof(stream));
diff --git a/builtin/update-index.c b/builtin/update-index.c
index b0e3dc9..5878986 100644
--- a/builtin/update-index.c
+++ b/builtin/update-index.c
@@ -400,7 +400,7 @@ static void read_index_info(int line_termination)
}
static const char * const update_index_usage[] = {
- N_("git update-index [options] [--] [<file>...]"),
+ N_("git update-index [<options>] [--] [<file>...]"),
NULL
};
diff --git a/builtin/update-ref.c b/builtin/update-ref.c
index 6c9be05..2497ba4 100644
--- a/builtin/update-ref.c
+++ b/builtin/update-ref.c
@@ -6,9 +6,9 @@
#include "argv-array.h"
static const char * const git_update_ref_usage[] = {
- N_("git update-ref [options] -d <refname> [<oldval>]"),
- N_("git update-ref [options] <refname> <newval> [<oldval>]"),
- N_("git update-ref [options] --stdin [-z]"),
+ N_("git update-ref [<options>] -d <refname> [<old-val>]"),
+ N_("git update-ref [<options>] <refname> <new-val> [<old-val>]"),
+ N_("git update-ref [<options>] --stdin [-z]"),
NULL
};
@@ -282,26 +282,22 @@ static const char *parse_cmd_verify(struct ref_transaction *transaction,
char *refname;
unsigned char new_sha1[20];
unsigned char old_sha1[20];
- int have_old;
refname = parse_refname(input, &next);
if (!refname)
die("verify: missing <ref>");
if (parse_next_sha1(input, &next, old_sha1, "verify", refname,
- PARSE_SHA1_OLD)) {
- hashclr(new_sha1);
- have_old = 0;
- } else {
- hashcpy(new_sha1, old_sha1);
- have_old = 1;
- }
+ PARSE_SHA1_OLD))
+ hashclr(old_sha1);
+
+ hashcpy(new_sha1, old_sha1);
if (*next != line_termination)
die("verify %s: extra input: %s", refname, next);
if (ref_transaction_update(transaction, refname, new_sha1, old_sha1,
- update_flags, have_old, msg, &err))
+ update_flags, 1, msg, &err))
die("%s", err.buf);
update_flags = 0;
diff --git a/builtin/verify-commit.c b/builtin/verify-commit.c
index b0f8504..ec0c4e3 100644
--- a/builtin/verify-commit.c
+++ b/builtin/verify-commit.c
@@ -14,7 +14,7 @@
#include "gpg-interface.h"
static const char * const verify_commit_usage[] = {
- N_("git verify-commit [-v|--verbose] <commit>..."),
+ N_("git verify-commit [-v | --verbose] <commit>..."),
NULL
};
diff --git a/builtin/verify-pack.c b/builtin/verify-pack.c
index 7747537..c94e156 100644
--- a/builtin/verify-pack.c
+++ b/builtin/verify-pack.c
@@ -51,7 +51,7 @@ static int verify_one_pack(const char *path, unsigned int flags)
}
static const char * const verify_pack_usage[] = {
- N_("git verify-pack [-v|--verbose] [-s|--stat-only] <pack>..."),
+ N_("git verify-pack [-v | --verbose] [-s | --stat-only] <pack>..."),
NULL
};
diff --git a/builtin/verify-tag.c b/builtin/verify-tag.c
index 9cdf332..53c68fc 100644
--- a/builtin/verify-tag.c
+++ b/builtin/verify-tag.c
@@ -14,7 +14,7 @@
#include "gpg-interface.h"
static const char * const verify_tag_usage[] = {
- N_("git verify-tag [-v|--verbose] <tag>..."),
+ N_("git verify-tag [-v | --verbose] <tag>..."),
NULL
};
diff --git a/cache.h b/cache.h
index 99ed096..4d02efc 100644
--- a/cache.h
+++ b/cache.h
@@ -65,13 +65,6 @@ unsigned long git_deflate_bound(git_zstream *, unsigned long);
*
* The value 0160000 is not normally a valid mode, and
* also just happens to be S_IFDIR + S_IFLNK
- *
- * NOTE! We *really* shouldn't depend on the S_IFxxx macros
- * always having the same values everywhere. We should use
- * our internal git values for these things, and then we can
- * translate that to the OS-specific value. It just so
- * happens that everybody shares the same bit representation
- * in the UNIX world (and apparently wider too..)
*/
#define S_IFGITLINK 0160000
#define S_ISGITLINK(m) (((m) & S_IFMT) == S_IFGITLINK)
@@ -617,6 +610,8 @@ extern int fsync_object_files;
extern int core_preload_index;
extern int core_apply_sparse_checkout;
extern int precomposed_unicode;
+extern int protect_hfs;
+extern int protect_ntfs;
/*
* The character that begins a commented line in user-editable file
@@ -831,6 +826,7 @@ int normalize_path_copy(char *dst, const char *src);
int longest_ancestor_length(const char *path, struct string_list *prefixes);
char *strip_path_suffix(const char *path, const char *suffix);
int daemon_avoid_alias(const char *path);
+extern int is_ntfs_dotgit(const char *name);
/* object replacement */
#define LOOKUP_REPLACE_OBJECT 1
@@ -1258,6 +1254,10 @@ extern int unpack_object_header(struct packed_git *, struct pack_window **, off_
*
* Any callback that is NULL will be ignored. Callbacks returning non-zero
* will end the iteration.
+ *
+ * In the "buf" variant, "path" is a strbuf which will also be used as a
+ * scratch buffer, but restored to its original contents before
+ * the function returns.
*/
typedef int each_loose_object_fn(const unsigned char *sha1,
const char *path,
@@ -1273,6 +1273,11 @@ int for_each_loose_file_in_objdir(const char *path,
each_loose_cruft_fn cruft_cb,
each_loose_subdir_fn subdir_cb,
void *data);
+int for_each_loose_file_in_objdir_buf(struct strbuf *path,
+ each_loose_object_fn obj_cb,
+ each_loose_cruft_fn cruft_cb,
+ each_loose_subdir_fn subdir_cb,
+ void *data);
/*
* Iterate over loose and packed objects in both the local
@@ -1502,7 +1507,7 @@ extern const char *pager_program;
extern int pager_in_use(void);
extern int pager_use_color;
extern int term_columns(void);
-extern int decimal_width(int);
+extern int decimal_width(uintmax_t);
extern int check_pager_config(const char *cmd);
extern const char *editor_program;
diff --git a/check-builtins.sh b/check-builtins.sh
index 07cff69..a0aaf3a 100755
--- a/check-builtins.sh
+++ b/check-builtins.sh
@@ -3,7 +3,7 @@
{
cat <<\EOF
sayIt:
- $(foreach b,$(BUILT_INS),echo XXX $b YYY;)
+ $(foreach b,$(BUILT_INS),echo XXX $(b:$X=) YYY;)
EOF
cat Makefile
} |
diff --git a/color.c b/color.c
index 7941e93..9027352 100644
--- a/color.c
+++ b/color.c
@@ -26,30 +26,110 @@ const char *column_colors_ansi[] = {
/* Ignore the RESET at the end when giving the size */
const int column_colors_ansi_max = ARRAY_SIZE(column_colors_ansi) - 1;
-static int parse_color(const char *name, int len)
+/* An individual foreground or background color. */
+struct color {
+ enum {
+ COLOR_UNSPECIFIED = 0,
+ COLOR_NORMAL,
+ COLOR_ANSI, /* basic 0-7 ANSI colors */
+ COLOR_256,
+ COLOR_RGB
+ } type;
+ /* The numeric value for ANSI and 256-color modes */
+ unsigned char value;
+ /* 24-bit RGB color values */
+ unsigned char red, green, blue;
+};
+
+/*
+ * "word" is a buffer of length "len"; does it match the NUL-terminated
+ * "match" exactly?
+ */
+static int match_word(const char *word, int len, const char *match)
{
+ return !strncasecmp(word, match, len) && !match[len];
+}
+
+static int get_hex_color(const char *in, unsigned char *out)
+{
+ unsigned int val;
+ val = (hexval(in[0]) << 4) | hexval(in[1]);
+ if (val & ~0xff)
+ return -1;
+ *out = val;
+ return 0;
+}
+
+static int parse_color(struct color *out, const char *name, int len)
+{
+ /* Positions in array must match ANSI color codes */
static const char * const color_names[] = {
- "normal", "black", "red", "green", "yellow",
+ "black", "red", "green", "yellow",
"blue", "magenta", "cyan", "white"
};
char *end;
int i;
+ long val;
+
+ /* First try the special word "normal"... */
+ if (match_word(name, len, "normal")) {
+ out->type = COLOR_NORMAL;
+ return 0;
+ }
+
+ /* Try a 24-bit RGB value */
+ if (len == 7 && name[0] == '#') {
+ if (!get_hex_color(name + 1, &out->red) &&
+ !get_hex_color(name + 3, &out->green) &&
+ !get_hex_color(name + 5, &out->blue)) {
+ out->type = COLOR_RGB;
+ return 0;
+ }
+ }
+
+ /* Then pick from our human-readable color names... */
for (i = 0; i < ARRAY_SIZE(color_names); i++) {
- const char *str = color_names[i];
- if (!strncasecmp(name, str, len) && !str[len])
- return i - 1;
+ if (match_word(name, len, color_names[i])) {
+ out->type = COLOR_ANSI;
+ out->value = i;
+ return 0;
+ }
}
- i = strtol(name, &end, 10);
- if (end - name == len && i >= -1 && i <= 255)
- return i;
- return -2;
+
+ /* And finally try a literal 256-color-mode number */
+ val = strtol(name, &end, 10);
+ if (end - name == len) {
+ /*
+ * Allow "-1" as an alias for "normal", but other negative
+ * numbers are bogus.
+ */
+ if (val < -1)
+ ; /* fall through to error */
+ else if (val < 0) {
+ out->type = COLOR_NORMAL;
+ return 0;
+ /* Rewrite low numbers as more-portable standard colors. */
+ } else if (val < 8) {
+ out->type = COLOR_ANSI;
+ out->value = val;
+ return 0;
+ } else if (val < 256) {
+ out->type = COLOR_256;
+ out->value = val;
+ return 0;
+ }
+ }
+
+ return -1;
}
static int parse_attr(const char *name, int len)
{
- static const int attr_values[] = { 1, 2, 4, 5, 7 };
+ static const int attr_values[] = { 1, 2, 4, 5, 7,
+ 22, 22, 24, 25, 27 };
static const char * const attr_names[] = {
- "bold", "dim", "ul", "blink", "reverse"
+ "bold", "dim", "ul", "blink", "reverse",
+ "nobold", "nodim", "noul", "noblink", "noreverse"
};
int i;
for (i = 0; i < ARRAY_SIZE(attr_names); i++) {
@@ -65,13 +145,44 @@ int color_parse(const char *value, char *dst)
return color_parse_mem(value, strlen(value), dst);
}
+/*
+ * Write the ANSI color codes for "c" to "out"; the string should
+ * already have the ANSI escape code in it. "out" should have enough
+ * space in it to fit any color.
+ */
+static char *color_output(char *out, const struct color *c, char type)
+{
+ switch (c->type) {
+ case COLOR_UNSPECIFIED:
+ case COLOR_NORMAL:
+ break;
+ case COLOR_ANSI:
+ *out++ = type;
+ *out++ = '0' + c->value;
+ break;
+ case COLOR_256:
+ out += sprintf(out, "%c8;5;%d", type, c->value);
+ break;
+ case COLOR_RGB:
+ out += sprintf(out, "%c8;2;%d;%d;%d", type,
+ c->red, c->green, c->blue);
+ break;
+ }
+ return out;
+}
+
+static int color_empty(const struct color *c)
+{
+ return c->type <= COLOR_NORMAL;
+}
+
int color_parse_mem(const char *value, int value_len, char *dst)
{
const char *ptr = value;
int len = value_len;
unsigned int attr = 0;
- int fg = -2;
- int bg = -2;
+ struct color fg = { COLOR_UNSPECIFIED };
+ struct color bg = { COLOR_UNSPECIFIED };
if (!strncasecmp(value, "reset", len)) {
strcpy(dst, GIT_COLOR_RESET);
@@ -81,6 +192,7 @@ int color_parse_mem(const char *value, int value_len, char *dst)
/* [fg [bg]] [attr]... */
while (len > 0) {
const char *word = ptr;
+ struct color c;
int val, wordlen = 0;
while (len > 0 && !isspace(word[wordlen])) {
@@ -94,14 +206,13 @@ int color_parse_mem(const char *value, int value_len, char *dst)
len--;
}
- val = parse_color(word, wordlen);
- if (val >= -1) {
- if (fg == -2) {
- fg = val;
+ if (!parse_color(&c, word, wordlen)) {
+ if (fg.type == COLOR_UNSPECIFIED) {
+ fg = c;
continue;
}
- if (bg == -2) {
- bg = val;
+ if (bg.type == COLOR_UNSPECIFIED) {
+ bg = c;
continue;
}
goto bad;
@@ -113,7 +224,7 @@ int color_parse_mem(const char *value, int value_len, char *dst)
goto bad;
}
- if (attr || fg >= 0 || bg >= 0) {
+ if (attr || !color_empty(&fg) || !color_empty(&bg)) {
int sep = 0;
int i;
@@ -127,27 +238,19 @@ int color_parse_mem(const char *value, int value_len, char *dst)
attr &= ~bit;
if (sep++)
*dst++ = ';';
- *dst++ = '0' + i;
+ dst += sprintf(dst, "%d", i);
}
- if (fg >= 0) {
+ if (!color_empty(&fg)) {
if (sep++)
*dst++ = ';';
- if (fg < 8) {
- *dst++ = '3';
- *dst++ = '0' + fg;
- } else {
- dst += sprintf(dst, "38;5;%d", fg);
- }
+ /* foreground colors are all in the 3x range */
+ dst = color_output(dst, &fg, '3');
}
- if (bg >= 0) {
+ if (!color_empty(&bg)) {
if (sep++)
*dst++ = ';';
- if (bg < 8) {
- *dst++ = '4';
- *dst++ = '0' + bg;
- } else {
- dst += sprintf(dst, "48;5;%d", bg);
- }
+ /* background colors are all in the 4x range */
+ dst = color_output(dst, &bg, '4');
}
*dst++ = 'm';
}
diff --git a/color.h b/color.h
index f5beab1..7fe77fb 100644
--- a/color.h
+++ b/color.h
@@ -8,15 +8,15 @@ struct strbuf;
/*
* The maximum length of ANSI color sequence we would generate:
* - leading ESC '[' 2
- * - attr + ';' 2 * 8 (e.g. "1;")
- * - fg color + ';' 9 (e.g. "38;5;2xx;")
- * - fg color + ';' 9 (e.g. "48;5;2xx;")
+ * - attr + ';' 3 * 10 (e.g. "1;")
+ * - fg color + ';' 17 (e.g. "38;2;255;255;255;")
+ * - bg color + ';' 17 (e.g. "48;2;255;255;255;")
* - terminating 'm' NUL 2
*
* The above overcounts attr (we only use 5 not 8) and one semicolon
* but it is close enough.
*/
-#define COLOR_MAXLEN 40
+#define COLOR_MAXLEN 70
/*
* IMPORTANT: Due to the way these color codes are emulated on Windows,
diff --git a/commit.c b/commit.c
index 19cf8f9..a8c7577 100644
--- a/commit.c
+++ b/commit.c
@@ -867,7 +867,7 @@ struct commit_list *get_octopus_merge_bases(struct commit_list *in)
for (j = ret; j; j = j->next) {
struct commit_list *bases;
- bases = get_merge_bases(i->item, j->item, 1);
+ bases = get_merge_bases(i->item, j->item);
if (!new)
new = bases;
else
@@ -936,10 +936,10 @@ static int remove_redundant(struct commit **array, int cnt)
return filled;
}
-struct commit_list *get_merge_bases_many(struct commit *one,
- int n,
- struct commit **twos,
- int cleanup)
+static struct commit_list *get_merge_bases_many_0(struct commit *one,
+ int n,
+ struct commit **twos,
+ int cleanup)
{
struct commit_list *list;
struct commit **rslt;
@@ -977,10 +977,23 @@ struct commit_list *get_merge_bases_many(struct commit *one,
return result;
}
-struct commit_list *get_merge_bases(struct commit *one, struct commit *two,
- int cleanup)
+struct commit_list *get_merge_bases_many(struct commit *one,
+ int n,
+ struct commit **twos)
{
- return get_merge_bases_many(one, 1, &two, cleanup);
+ return get_merge_bases_many_0(one, n, twos, 1);
+}
+
+struct commit_list *get_merge_bases_many_dirty(struct commit *one,
+ int n,
+ struct commit **twos)
+{
+ return get_merge_bases_many_0(one, n, twos, 0);
+}
+
+struct commit_list *get_merge_bases(struct commit *one, struct commit *two)
+{
+ return get_merge_bases_many_0(one, 1, &two, 1);
}
/*
@@ -1640,3 +1653,49 @@ const char *find_commit_header(const char *msg, const char *key, size_t *out_len
}
return NULL;
}
+
+/*
+ * Inspect sb and determine the true "end" of the log message, in
+ * order to find where to put a new Signed-off-by: line. Ignored are
+ * trailing comment lines and blank lines, and also the traditional
+ * "Conflicts:" block that is not commented out, so that we can use
+ * "git commit -s --amend" on an existing commit that forgot to remove
+ * it.
+ *
+ * Returns the number of bytes from the tail to ignore, to be fed as
+ * the second parameter to append_signoff().
+ */
+int ignore_non_trailer(struct strbuf *sb)
+{
+ int boc = 0;
+ int bol = 0;
+ int in_old_conflicts_block = 0;
+
+ while (bol < sb->len) {
+ char *next_line;
+
+ if (!(next_line = memchr(sb->buf + bol, '\n', sb->len - bol)))
+ next_line = sb->buf + sb->len;
+ else
+ next_line++;
+
+ if (sb->buf[bol] == comment_line_char || sb->buf[bol] == '\n') {
+ /* is this the first of the run of comments? */
+ if (!boc)
+ boc = bol;
+ /* otherwise, it is just continuing */
+ } else if (starts_with(sb->buf + bol, "Conflicts:\n")) {
+ in_old_conflicts_block = 1;
+ if (!boc)
+ boc = bol;
+ } else if (in_old_conflicts_block && sb->buf[bol] == '\t') {
+ ; /* a pathname in the conflicts block */
+ } else if (boc) {
+ /* the previous was not trailing comment */
+ boc = 0;
+ in_old_conflicts_block = 0;
+ }
+ bol = next_line - sb->buf;
+ }
+ return boc ? sb->len - boc : 0;
+}
diff --git a/commit.h b/commit.h
index bc68ccb..9f189cb 100644
--- a/commit.h
+++ b/commit.h
@@ -236,10 +236,13 @@ struct commit_graft *read_graft_line(char *buf, int len);
int register_commit_graft(struct commit_graft *, int);
struct commit_graft *lookup_commit_graft(const unsigned char *sha1);
-extern struct commit_list *get_merge_bases(struct commit *rev1, struct commit *rev2, int cleanup);
-extern struct commit_list *get_merge_bases_many(struct commit *one, int n, struct commit **twos, int cleanup);
+extern struct commit_list *get_merge_bases(struct commit *rev1, struct commit *rev2);
+extern struct commit_list *get_merge_bases_many(struct commit *one, int n, struct commit **twos);
extern struct commit_list *get_octopus_merge_bases(struct commit_list *in);
+/* To be used only when object flags after this call no longer matter */
+extern struct commit_list *get_merge_bases_many_dirty(struct commit *one, int n, struct commit **twos);
+
/* largest positive number a signed 32-bit integer can contain */
#define INFINITE_DEPTH 0x7fffffff
@@ -251,7 +254,6 @@ extern int for_each_commit_graft(each_commit_graft_fn, void *);
extern int is_repository_shallow(void);
extern struct commit_list *get_shallow_commits(struct object_array *heads,
int depth, int shallow_flag, int not_shallow_flag);
-extern void check_shallow_file_for_update(void);
extern void set_alternate_shallow_file(const char *path, int override);
extern int write_shallow_commits(struct strbuf *out, int use_pack_protocol,
const struct sha1_array *extra);
@@ -337,6 +339,9 @@ extern void free_commit_extra_headers(struct commit_extra_header *extra);
extern const char *find_commit_header(const char *msg, const char *key,
size_t *out_len);
+/* Find the end of the log message, the right place for a new trailer. */
+extern int ignore_non_trailer(struct strbuf *sb);
+
typedef void (*each_mergetag_fn)(struct commit *commit, struct commit_extra_header *extra,
void *cb_data);
diff --git a/compat/stat.c b/compat/stat.c
new file mode 100644
index 0000000..a2d3931
--- /dev/null
+++ b/compat/stat.c
@@ -0,0 +1,48 @@
+#define _POSIX_C_SOURCE 200112L
+#include <sys/stat.h> /* *stat, S_IS* */
+#include <sys/types.h> /* mode_t */
+
+static inline mode_t mode_native_to_git(mode_t native_mode)
+{
+ mode_t perm_bits = native_mode & 07777;
+ if (S_ISREG(native_mode))
+ return 0100000 | perm_bits;
+ if (S_ISDIR(native_mode))
+ return 0040000 | perm_bits;
+ if (S_ISLNK(native_mode))
+ return 0120000 | perm_bits;
+ if (S_ISBLK(native_mode))
+ return 0060000 | perm_bits;
+ if (S_ISCHR(native_mode))
+ return 0020000 | perm_bits;
+ if (S_ISFIFO(native_mode))
+ return 0010000 | perm_bits;
+ if (S_ISSOCK(native_mode))
+ return 0140000 | perm_bits;
+ /* Non-standard type bits were given. */
+ return perm_bits;
+}
+
+int git_stat(const char *path, struct stat *buf)
+{
+ int rc = stat(path, buf);
+ if (rc == 0)
+ buf->st_mode = mode_native_to_git(buf->st_mode);
+ return rc;
+}
+
+int git_fstat(int fd, struct stat *buf)
+{
+ int rc = fstat(fd, buf);
+ if (rc == 0)
+ buf->st_mode = mode_native_to_git(buf->st_mode);
+ return rc;
+}
+
+int git_lstat(const char *path, struct stat *buf)
+{
+ int rc = lstat(path, buf);
+ if (rc == 0)
+ buf->st_mode = mode_native_to_git(buf->st_mode);
+ return rc;
+}
diff --git a/config.c b/config.c
index ae1398f..66c0a51 100644
--- a/config.c
+++ b/config.c
@@ -73,8 +73,12 @@ static int config_buf_fgetc(struct config_source *conf)
static int config_buf_ungetc(int c, struct config_source *conf)
{
- if (conf->u.buf.pos > 0)
- return conf->u.buf.buf[--conf->u.buf.pos];
+ if (conf->u.buf.pos > 0) {
+ conf->u.buf.pos--;
+ if (conf->u.buf.buf[conf->u.buf.pos] != c)
+ die("BUG: config_buf can only ungetc the same character");
+ return c;
+ }
return EOF;
}
@@ -235,7 +239,8 @@ static int get_next_char(void)
/* DOS like systems */
c = cf->do_fgetc(cf);
if (c != '\n') {
- cf->do_ungetc(c, cf);
+ if (c != EOF)
+ cf->do_ungetc(c, cf);
c = '\r';
}
}
@@ -896,6 +901,16 @@ static int git_default_core_config(const char *var, const char *value)
return 0;
}
+ if (!strcmp(var, "core.protecthfs")) {
+ protect_hfs = git_config_bool(var, value);
+ return 0;
+ }
+
+ if (!strcmp(var, "core.protectntfs")) {
+ protect_ntfs = git_config_bool(var, value);
+ return 0;
+ }
+
/* Add other config variables here and to Documentation/config.txt. */
return 0;
}
@@ -1330,7 +1345,7 @@ static int configset_add_value(struct config_set *cs, const char *key, const cha
string_list_init(&e->value_list, 1);
hashmap_add(&cs->config_hash, e);
}
- si = string_list_append_nodup(&e->value_list, value ? xstrdup(value) : NULL);
+ si = string_list_append_nodup(&e->value_list, xstrdup_or_null(value));
ALLOC_GROW(cs->list.items, cs->list.nr + 1, cs->list.alloc);
l_item = &cs->list.items[cs->list.nr++];
diff --git a/config.mak.uname b/config.mak.uname
index a2f380f..b64b63c 100644
--- a/config.mak.uname
+++ b/config.mak.uname
@@ -35,6 +35,7 @@ ifeq ($(uname_S),Linux)
LIBC_CONTAINS_LIBINTL = YesPlease
HAVE_DEV_TTY = YesPlease
HAVE_CLOCK_GETTIME = YesPlease
+ HAVE_CLOCK_MONOTONIC = YesPlease
endif
ifeq ($(uname_S),GNU/kFreeBSD)
HAVE_ALLOCA_H = YesPlease
@@ -105,6 +106,7 @@ ifeq ($(uname_S),Darwin)
HAVE_DEV_TTY = YesPlease
COMPAT_OBJS += compat/precompose_utf8.o
BASIC_CFLAGS += -DPRECOMPOSE_UNICODE
+ BASIC_CFLAGS += -DPROTECT_HFS_DEFAULT=1
endif
ifeq ($(uname_S),SunOS)
NEEDS_SOCKET = YesPlease
@@ -373,6 +375,7 @@ ifeq ($(uname_S),Windows)
EXTLIBS = user32.lib advapi32.lib shell32.lib wininet.lib ws2_32.lib invalidcontinue.obj
PTHREAD_LIBS =
lib =
+ BASIC_CFLAGS += -DPROTECT_NTFS_DEFAULT=1
ifndef DEBUG
BASIC_CFLAGS += -GL -Os -MD
BASIC_LDFLAGS += -LTCG
@@ -514,6 +517,7 @@ ifneq (,$(findstring MINGW,$(uname_S)))
COMPAT_OBJS += compat/mingw.o compat/winansi.o \
compat/win32/pthread.o compat/win32/syslog.o \
compat/win32/dirent.o
+ BASIC_CFLAGS += -DPROTECT_NTFS_DEFAULT=1
BASIC_LDFLAGS += -Wl,--large-address-aware
EXTLIBS += -lws2_32
GITLIBS += git.res
diff --git a/configure.ac b/configure.ac
index 6af9647..55e5a9b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -754,6 +754,19 @@ AC_CHECK_TYPES([struct itimerval],
[#include <sys/time.h>])
GIT_CONF_SUBST([NO_STRUCT_ITIMERVAL])
#
+# Define USE_ST_TIMESPEC=YesPlease when stat.st_mtimespec.tv_nsec exists.
+# Define NO_NSEC=YesPlease when neither stat.st_mtim.tv_nsec nor
+# stat.st_mtimespec.tv_nsec exists.
+AC_CHECK_MEMBER([struct stat.st_mtimespec.tv_nsec])
+AC_CHECK_MEMBER([struct stat.st_mtim.tv_nsec])
+if test x$ac_cv_member_struct_stat_st_mtimespec_tv_nsec = xyes; then
+ USE_ST_TIMESPEC=YesPlease
+ GIT_CONF_SUBST([USE_ST_TIMESPEC])
+elif test x$ac_cv_member_struct_stat_st_mtim_tv_nsec != xyes; then
+ NO_NSEC=YesPlease
+ GIT_CONF_SUBST([NO_NSEC])
+fi
+#
# Define NO_D_INO_IN_DIRENT if you don't have d_ino in your struct dirent.
AC_CHECK_MEMBER(struct dirent.d_ino,
[NO_D_INO_IN_DIRENT=],
@@ -873,6 +886,29 @@ else
SNPRINTF_RETURNS_BOGUS=
fi
GIT_CONF_SUBST([SNPRINTF_RETURNS_BOGUS])
+#
+# Define NEEDS_MODE_TRANSLATION if your OS strays from the typical file type
+# bits in mode values.
+AC_CACHE_CHECK([whether the platform uses typical file type bits],
+ [ac_cv_sane_mode_bits], [
+AC_EGREP_CPP(yippeeyeswehaveit,
+ AC_LANG_PROGRAM([AC_INCLUDES_DEFAULT],
+[#if S_IFMT == 0170000 && \
+ S_IFREG == 0100000 && S_IFDIR == 0040000 && S_IFLNK == 0120000 && \
+ S_IFBLK == 0060000 && S_IFCHR == 0020000 && \
+ S_IFIFO == 0010000 && S_IFSOCK == 0140000
+yippeeyeswehaveit
+#endif
+]),
+ [ac_cv_sane_mode_bits=yes],
+ [ac_cv_sane_mode_bits=no])
+])
+if test $ac_cv_sane_mode_bits = yes; then
+ NEEDS_MODE_TRANSLATION=
+else
+ NEEDS_MODE_TRANSLATION=UnfortunatelyYes
+fi
+GIT_CONF_SUBST([NEEDS_MODE_TRANSLATION])
## Checks for library functions.
@@ -911,6 +947,32 @@ AC_CHECK_LIB([iconv], [locale_charset],
[CHARSET_LIB=-lcharset])])
GIT_CONF_SUBST([CHARSET_LIB])
#
+# Define NO_HMAC_CTX_CLEANUP=YesPlease if HMAC_CTX_cleanup is missing.
+AC_CHECK_LIB([crypto], [HMAC_CTX_cleanup],
+ [], [GIT_CONF_SUBST([NO_HMAC_CTX_CLEANUP], [YesPlease])])
+#
+# Define HAVE_CLOCK_GETTIME=YesPlease if clock_gettime is available.
+GIT_CHECK_FUNC(clock_gettime,
+ [HAVE_CLOCK_GETTIME=YesPlease],
+ [HAVE_CLOCK_GETTIME=])
+GIT_CONF_SUBST([HAVE_CLOCK_GETTIME])
+
+AC_DEFUN([CLOCK_MONOTONIC_SRC], [
+AC_LANG_PROGRAM([[
+#include <time.h>
+clockid_t id = CLOCK_MONOTONIC;
+]])])
+
+#
+# Define HAVE_CLOCK_MONOTONIC=YesPlease if CLOCK_MONOTONIC is available.
+AC_MSG_CHECKING([for CLOCK_MONOTONIC])
+AC_COMPILE_IFELSE([CLOCK_MONOTONIC_SRC],
+ [AC_MSG_RESULT([yes])
+ HAVE_CLOCK_MONOTONIC=YesPlease],
+ [AC_MSG_RESULT([no])
+ HAVE_CLOCK_MONOTONIC=])
+GIT_CONF_SUBST([HAVE_CLOCK_MONOTONIC])
+#
# Define NO_SETITIMER if you don't have setitimer.
GIT_CHECK_FUNC(setitimer,
[NO_SETITIMER=],
diff --git a/connect.c b/connect.c
index cb23bbc..062e133 100644
--- a/connect.c
+++ b/connect.c
@@ -93,7 +93,7 @@ static void annotate_refs_with_symref_info(struct ref *ref)
parse_one_symref_info(&symref, val, len);
feature_list = val + 1;
}
- sort_string_list(&symref);
+ string_list_sort(&symref);
for (; ref; ref = ref->next) {
struct string_list_item *item;
diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
index 2fece98..c21190d 100644
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -16,9 +16,9 @@
#
# To use these routines:
#
-# 1) Copy this file to somewhere (e.g. ~/.git-completion.sh).
+# 1) Copy this file to somewhere (e.g. ~/.git-completion.bash).
# 2) Add the following line to your .bashrc/.zshrc:
-# source ~/.git-completion.sh
+# source ~/.git-completion.bash
# 3) Consider changing your PS1 to also show the current branch,
# see git-prompt.sh for details.
#
@@ -1425,7 +1425,7 @@ __git_log_gitk_options="
# Options that go well for log and shortlog (not gitk)
__git_log_shortlog_options="
--author= --committer= --grep=
- --all-match
+ --all-match --invert-grep
"
__git_log_pretty_formats="oneline short medium full fuller email raw format:"
@@ -1693,6 +1693,7 @@ _git_rebase ()
--committer-date-is-author-date --ignore-date
--ignore-whitespace --whitespace=
--autosquash --fork-point --no-fork-point
+ --autostash
"
return
@@ -1875,6 +1876,10 @@ _git_config ()
__gitcomp "$__git_send_email_suppresscc_options"
return
;;
+ sendemail.transferencoding)
+ __gitcomp "7bit 8bit quoted-printable base64"
+ return
+ ;;
--get|--get-all|--unset|--unset-all)
__gitcomp_nl "$(__git_config_get_set_variables)"
return
@@ -2548,6 +2553,16 @@ _git_tag ()
__gitcomp_nl "$(__git_refs)"
;;
esac
+
+ case "$cur" in
+ --*)
+ __gitcomp "
+ --list --delete --verify --annotate --message --file
+ --sign --cleanup --local-user --force --column --sort
+ --contains --points-at
+ "
+ ;;
+ esac
}
_git_whatchanged ()
diff --git a/contrib/completion/git-completion.zsh b/contrib/completion/git-completion.zsh
index 9f6f0fa..e255413 100644
--- a/contrib/completion/git-completion.zsh
+++ b/contrib/completion/git-completion.zsh
@@ -9,7 +9,7 @@
#
# If your script is somewhere else, you can configure it on your ~/.zshrc:
#
-# zstyle ':completion:*:*:git:*' script ~/.git-completion.sh
+# zstyle ':completion:*:*:git:*' script ~/.git-completion.zsh
#
# The recommended way to install this script is to copy to '~/.zsh/_git', and
# then add the following to your ~/.zshrc file:
diff --git a/contrib/completion/git-prompt.sh b/contrib/completion/git-prompt.sh
index c5473dc..214e859 100644
--- a/contrib/completion/git-prompt.sh
+++ b/contrib/completion/git-prompt.sh
@@ -84,6 +84,11 @@
# GIT_PS1_SHOWCOLORHINTS to a nonempty value. The colors are based on
# the colored output of "git status -sb" and are available only when
# using __git_ps1 for PROMPT_COMMAND or precmd.
+#
+# If you would like __git_ps1 to do nothing in the case when the current
+# directory is set up to be ignored by git, then set
+# GIT_PS1_HIDE_IF_PWD_IGNORED to a nonempty value. Override this on the
+# repository level by setting bash.hideIfPwdIgnored to "false".
# check whether printf supports -v
__git_printf_supports_v=
@@ -270,7 +275,7 @@ __git_ps1_colorize_gitstring ()
__git_eread ()
{
- f="$1"
+ local f="$1"
shift
test -r "$f" && read "$@" <"$f"
}
@@ -288,6 +293,8 @@ __git_eread ()
# In this mode you can request colored hints using GIT_PS1_SHOWCOLORHINTS=true
__git_ps1 ()
{
+ # preserve exit status
+ local exit=$?
local pcmode=no
local detached=no
local ps1pc_start='\u@\h:\w '
@@ -299,10 +306,14 @@ __git_ps1 ()
ps1pc_start="$1"
ps1pc_end="$2"
printf_format="${3:-$printf_format}"
+ # set PS1 to a plain prompt so that we can
+ # simply return early if the prompt should not
+ # be decorated
+ PS1="$ps1pc_start$ps1pc_end"
;;
0|1) printf_format="${1:-$printf_format}"
;;
- *) return
+ *) return $exit
;;
esac
@@ -350,11 +361,7 @@ __git_ps1 ()
rev_parse_exit_code="$?"
if [ -z "$repo_info" ]; then
- if [ $pcmode = yes ]; then
- #In PC mode PS1 always needs to be set
- PS1="$ps1pc_start$ps1pc_end"
- fi
- return
+ return $exit
fi
local short_sha
@@ -369,6 +376,14 @@ __git_ps1 ()
local inside_gitdir="${repo_info##*$'\n'}"
local g="${repo_info%$'\n'*}"
+ if [ "true" = "$inside_worktree" ] &&
+ [ -n "${GIT_PS1_HIDE_IF_PWD_IGNORED-}" ] &&
+ [ "$(git config --bool bash.hideIfPwdIgnored)" != "false" ] &&
+ git check-ignore -q .
+ then
+ return $exit
+ fi
+
local r=""
local b=""
local step=""
@@ -412,10 +427,7 @@ __git_ps1 ()
else
local head=""
if ! __git_eread "$g/HEAD" head; then
- if [ $pcmode = yes ]; then
- PS1="$ps1pc_start$ps1pc_end"
- fi
- return
+ return $exit
fi
# is it a symbolic ref?
b="${head#ref: }"
@@ -511,4 +523,6 @@ __git_ps1 ()
else
printf -- "$printf_format" "$gitstring"
fi
+
+ return $exit
}
diff --git a/contrib/credential/wincred/git-credential-wincred.c b/contrib/credential/wincred/git-credential-wincred.c
index a1d38f0..0061340 100644
--- a/contrib/credential/wincred/git-credential-wincred.c
+++ b/contrib/credential/wincred/git-credential-wincred.c
@@ -111,14 +111,23 @@ static void write_item(const char *what, LPCWSTR wbuf, int wlen)
* Match an (optional) expected string and a delimiter in the target string,
* consuming the matched text by updating the target pointer.
*/
-static int match_part(LPCWSTR *ptarget, LPCWSTR want, LPCWSTR delim)
+
+static LPCWSTR wcsstr_last(LPCWSTR str, LPCWSTR find)
+{
+ LPCWSTR res = NULL, pos;
+ for (pos = wcsstr(str, find); pos; pos = wcsstr(pos + 1, find))
+ res = pos;
+ return res;
+}
+
+static int match_part_with_last(LPCWSTR *ptarget, LPCWSTR want, LPCWSTR delim, int last)
{
LPCWSTR delim_pos, start = *ptarget;
int len;
/* find start of delimiter (or end-of-string if delim is empty) */
if (*delim)
- delim_pos = wcsstr(start, delim);
+ delim_pos = last ? wcsstr_last(start, delim) : wcsstr(start, delim);
else
delim_pos = start + wcslen(start);
@@ -138,6 +147,16 @@ static int match_part(LPCWSTR *ptarget, LPCWSTR want, LPCWSTR delim)
return !want || (!wcsncmp(want, start, len) && !want[len]);
}
+static int match_part(LPCWSTR *ptarget, LPCWSTR want, LPCWSTR delim)
+{
+ return match_part_with_last(ptarget, want, delim, 0);
+}
+
+static int match_part_last(LPCWSTR *ptarget, LPCWSTR want, LPCWSTR delim)
+{
+ return match_part_with_last(ptarget, want, delim, 1);
+}
+
static int match_cred(const CREDENTIALW *cred)
{
LPCWSTR target = cred->TargetName;
@@ -146,7 +165,7 @@ static int match_cred(const CREDENTIALW *cred)
return match_part(&target, L"git", L":") &&
match_part(&target, protocol, L"://") &&
- match_part(&target, wusername, L"@") &&
+ match_part_last(&target, wusername, L"@") &&
match_part(&target, host, L"/") &&
match_part(&target, path, L"");
}
diff --git a/contrib/diff-highlight/README b/contrib/diff-highlight/README
index 502e03b..836b97a 100644
--- a/contrib/diff-highlight/README
+++ b/contrib/diff-highlight/README
@@ -58,6 +58,47 @@ following in your git configuration:
diff = diff-highlight | less
---------------------------------------------
+
+Color Config
+------------
+
+You can configure the highlight colors and attributes using git's
+config. The colors for "old" and "new" lines can be specified
+independently. There are two "modes" of configuration:
+
+ 1. You can specify a "highlight" color and a matching "reset" color.
+ This will retain any existing colors in the diff, and apply the
+ "highlight" and "reset" colors before and after the highlighted
+ portion.
+
+ 2. You can specify a "normal" color and a "highlight" color. In this
+ case, existing colors are dropped from that line. The non-highlighted
+ bits of the line get the "normal" color, and the highlights get the
+ "highlight" color.
+
+If no "new" colors are specified, they default to the "old" colors. If
+no "old" colors are specified, the default is to reverse the foreground
+and background for highlighted portions.
+
+Examples:
+
+---------------------------------------------
+# Underline highlighted portions
+[color "diff-highlight"]
+oldHighlight = ul
+oldReset = noul
+---------------------------------------------
+
+---------------------------------------------
+# Varying background intensities
+[color "diff-highlight"]
+oldNormal = "black #f8cbcb"
+oldHighlight = "black #ffaaaa"
+newNormal = "black #cbeecb"
+newHighlight = "black #aaffaa"
+---------------------------------------------
+
+
Bugs
----
diff --git a/contrib/diff-highlight/diff-highlight b/contrib/diff-highlight/diff-highlight
index 69a652e..08c88bb 100755
--- a/contrib/diff-highlight/diff-highlight
+++ b/contrib/diff-highlight/diff-highlight
@@ -5,8 +5,18 @@ use strict;
# Highlight by reversing foreground and background. You could do
# other things like bold or underline if you prefer.
-my $HIGHLIGHT = "\x1b[7m";
-my $UNHIGHLIGHT = "\x1b[27m";
+my @OLD_HIGHLIGHT = (
+ color_config('color.diff-highlight.oldnormal'),
+ color_config('color.diff-highlight.oldhighlight', "\x1b[7m"),
+ color_config('color.diff-highlight.oldreset', "\x1b[27m")
+);
+my @NEW_HIGHLIGHT = (
+ color_config('color.diff-highlight.newnormal', $OLD_HIGHLIGHT[0]),
+ color_config('color.diff-highlight.newhighlight', $OLD_HIGHLIGHT[1]),
+ color_config('color.diff-highlight.newreset', $OLD_HIGHLIGHT[2])
+);
+
+my $RESET = "\x1b[m";
my $COLOR = qr/\x1b\[[0-9;]*m/;
my $BORING = qr/$COLOR|\s/;
@@ -57,6 +67,17 @@ show_hunk(\@removed, \@added);
exit 0;
+# Ideally we would feed the default as a human-readable color to
+# git-config as the fallback value. But diff-highlight does
+# not otherwise depend on git at all, and there are reports
+# of it being used in other settings. Let's handle our own
+# fallback, which means we will work even if git can't be run.
+sub color_config {
+ my ($key, $default) = @_;
+ my $s = `git config --get-color $key 2>/dev/null`;
+ return length($s) ? $s : $default;
+}
+
sub show_hunk {
my ($a, $b) = @_;
@@ -132,8 +153,8 @@ sub highlight_pair {
}
if (is_pair_interesting(\@a, $pa, $sa, \@b, $pb, $sb)) {
- return highlight_line(\@a, $pa, $sa),
- highlight_line(\@b, $pb, $sb);
+ return highlight_line(\@a, $pa, $sa, \@OLD_HIGHLIGHT),
+ highlight_line(\@b, $pb, $sb, \@NEW_HIGHLIGHT);
}
else {
return join('', @a),
@@ -148,15 +169,30 @@ sub split_line {
}
sub highlight_line {
- my ($line, $prefix, $suffix) = @_;
-
- return join('',
- @{$line}[0..($prefix-1)],
- $HIGHLIGHT,
- @{$line}[$prefix..$suffix],
- $UNHIGHLIGHT,
- @{$line}[($suffix+1)..$#$line]
- );
+ my ($line, $prefix, $suffix, $theme) = @_;
+
+ my $start = join('', @{$line}[0..($prefix-1)]);
+ my $mid = join('', @{$line}[$prefix..$suffix]);
+ my $end = join('', @{$line}[($suffix+1)..$#$line]);
+
+ # If we have a "normal" color specified, then take over the whole line.
+ # Otherwise, we try to just manipulate the highlighted bits.
+ if (defined $theme->[0]) {
+ s/$COLOR//g for ($start, $mid, $end);
+ chomp $end;
+ return join('',
+ $theme->[0], $start, $RESET,
+ $theme->[1], $mid, $RESET,
+ $theme->[0], $end, $RESET,
+ "\n"
+ );
+ } else {
+ return join('',
+ $start,
+ $theme->[1], $mid, $theme->[2],
+ $end
+ );
+ }
}
# Pairs are interesting to highlight only if we are going to end up
diff --git a/contrib/subtree/git-subtree.txt b/contrib/subtree/git-subtree.txt
index 8272100..54e4b4a 100644
--- a/contrib/subtree/git-subtree.txt
+++ b/contrib/subtree/git-subtree.txt
@@ -81,12 +81,11 @@ merge::
changes into the latest <commit>. With '--squash',
creates only one commit that contains all the changes,
rather than merging in the entire history.
-
- If you use '--squash', the merge direction doesn't
- always have to be forward; you can use this command to
- go back in time from v2.5 to v2.4, for example. If your
- merge introduces a conflict, you can resolve it in the
- usual ways.
++
+If you use '--squash', the merge direction doesn't always have to be
+forward; you can use this command to go back in time from v2.5 to v2.4,
+for example. If your merge introduces a conflict, you can resolve it in
+the usual ways.
pull::
Exactly like 'merge', but parallels 'git pull' in that
@@ -107,21 +106,19 @@ split::
contents of <prefix> at the root of the project instead
of in a subdirectory. Thus, the newly created history
is suitable for export as a separate git repository.
-
- After splitting successfully, a single commit id is
- printed to stdout. This corresponds to the HEAD of the
- newly created tree, which you can manipulate however you
- want.
-
- Repeated splits of exactly the same history are
- guaranteed to be identical (i.e. to produce the same
- commit ids). Because of this, if you add new commits
- and then re-split, the new commits will be attached as
- commits on top of the history you generated last time,
- so 'git merge' and friends will work as expected.
-
- Note that if you use '--squash' when you merge, you
- should usually not just '--rejoin' when you split.
++
+After splitting successfully, a single commit id is printed to stdout.
+This corresponds to the HEAD of the newly created tree, which you can
+manipulate however you want.
++
+Repeated splits of exactly the same history are guaranteed to be
+identical (i.e. to produce the same commit ids). Because of this, if
+you add new commits and then re-split, the new commits will be attached
+as commits on top of the history you generated last time, so 'git merge'
+and friends will work as expected.
++
+Note that if you use '--squash' when you merge, you should usually not
+just '--rejoin' when you split.
OPTIONS
@@ -151,109 +148,96 @@ OPTIONS FOR add, merge, push, pull
--squash::
This option is only valid for add, merge, push and pull
commands.
-
- Instead of merging the entire history from the subtree
- project, produce only a single commit that contains all
- the differences you want to merge, and then merge that
- new commit into your project.
-
- Using this option helps to reduce log clutter. People
- rarely want to see every change that happened between
- v1.0 and v1.1 of the library they're using, since none of the
- interim versions were ever included in their application.
-
- Using '--squash' also helps avoid problems when the same
- subproject is included multiple times in the same
- project, or is removed and then re-added. In such a
- case, it doesn't make sense to combine the histories
- anyway, since it's unclear which part of the history
- belongs to which subtree.
-
- Furthermore, with '--squash', you can switch back and
- forth between different versions of a subtree, rather
- than strictly forward. 'git subtree merge --squash'
- always adjusts the subtree to match the exactly
- specified commit, even if getting to that commit would
- require undoing some changes that were added earlier.
-
- Whether or not you use '--squash', changes made in your
- local repository remain intact and can be later split
- and send upstream to the subproject.
++
+Instead of merging the entire history from the subtree project, produce
+only a single commit that contains all the differences you want to
+merge, and then merge that new commit into your project.
++
+Using this option helps to reduce log clutter. People rarely want to see
+every change that happened between v1.0 and v1.1 of the library they're
+using, since none of the interim versions were ever included in their
+application.
++
+Using '--squash' also helps avoid problems when the same subproject is
+included multiple times in the same project, or is removed and then
+re-added. In such a case, it doesn't make sense to combine the
+histories anyway, since it's unclear which part of the history belongs
+to which subtree.
++
+Furthermore, with '--squash', you can switch back and forth between
+different versions of a subtree, rather than strictly forward. 'git
+subtree merge --squash' always adjusts the subtree to match the exactly
+specified commit, even if getting to that commit would require undoing
+some changes that were added earlier.
++
+Whether or not you use '--squash', changes made in your local repository
+remain intact and can be later split and send upstream to the
+subproject.
OPTIONS FOR split
-----------------
--annotate=<annotation>::
This option is only valid for the split command.
-
- When generating synthetic history, add <annotation> as a
- prefix to each commit message. Since we're creating new
- commits with the same commit message, but possibly
- different content, from the original commits, this can help
- to differentiate them and avoid confusion.
-
- Whenever you split, you need to use the same
- <annotation>, or else you don't have a guarantee that
- the new re-created history will be identical to the old
- one. That will prevent merging from working correctly.
- git subtree tries to make it work anyway, particularly
- if you use --rejoin, but it may not always be effective.
++
+When generating synthetic history, add <annotation> as a prefix to each
+commit message. Since we're creating new commits with the same commit
+message, but possibly different content, from the original commits, this
+can help to differentiate them and avoid confusion.
++
+Whenever you split, you need to use the same <annotation>, or else you
+don't have a guarantee that the new re-created history will be identical
+to the old one. That will prevent merging from working correctly. git
+subtree tries to make it work anyway, particularly if you use --rejoin,
+but it may not always be effective.
-b <branch>::
--branch=<branch>::
This option is only valid for the split command.
-
- After generating the synthetic history, create a new
- branch called <branch> that contains the new history.
- This is suitable for immediate pushing upstream.
- <branch> must not already exist.
++
+After generating the synthetic history, create a new branch called
+<branch> that contains the new history. This is suitable for immediate
+pushing upstream. <branch> must not already exist.
--ignore-joins::
This option is only valid for the split command.
-
- If you use '--rejoin', git subtree attempts to optimize
- its history reconstruction to generate only the new
- commits since the last '--rejoin'. '--ignore-join'
- disables this behaviour, forcing it to regenerate the
- entire history. In a large project, this can take a
- long time.
++
+If you use '--rejoin', git subtree attempts to optimize its history
+reconstruction to generate only the new commits since the last
+'--rejoin'. '--ignore-join' disables this behaviour, forcing it to
+regenerate the entire history. In a large project, this can take a long
+time.
--onto=<onto>::
This option is only valid for the split command.
-
- If your subtree was originally imported using something
- other than git subtree, its history may not match what
- git subtree is expecting. In that case, you can specify
- the commit id <onto> that corresponds to the first
- revision of the subproject's history that was imported
- into your project, and git subtree will attempt to build
- its history from there.
-
- If you used 'git subtree add', you should never need
- this option.
++
+If your subtree was originally imported using something other than git
+subtree, its history may not match what git subtree is expecting. In
+that case, you can specify the commit id <onto> that corresponds to the
+first revision of the subproject's history that was imported into your
+project, and git subtree will attempt to build its history from there.
++
+If you used 'git subtree add', you should never need this option.
--rejoin::
This option is only valid for the split command.
-
- After splitting, merge the newly created synthetic
- history back into your main project. That way, future
- splits can search only the part of history that has
- been added since the most recent --rejoin.
-
- If your split commits end up merged into the upstream
- subproject, and then you want to get the latest upstream
- version, this will allow git's merge algorithm to more
- intelligently avoid conflicts (since it knows these
- synthetic commits are already part of the upstream
- repository).
-
- Unfortunately, using this option results in 'git log'
- showing an extra copy of every new commit that was
- created (the original, and the synthetic one).
-
- If you do all your merges with '--squash', don't use
- '--rejoin' when you split, because you don't want the
- subproject's history to be part of your project anyway.
++
+After splitting, merge the newly created synthetic history back into
+your main project. That way, future splits can search only the part of
+history that has been added since the most recent --rejoin.
++
+If your split commits end up merged into the upstream subproject, and
+then you want to get the latest upstream version, this will allow git's
+merge algorithm to more intelligently avoid conflicts (since it knows
+these synthetic commits are already part of the upstream repository).
++
+Unfortunately, using this option results in 'git log' showing an extra
+copy of every new commit that was created (the original, and the
+synthetic one).
++
+If you do all your merges with '--squash', don't use '--rejoin' when you
+split, because you don't want the subproject's history to be part of
+your project anyway.
EXAMPLE 1. Add command
diff --git a/contrib/workdir/git-new-workdir b/contrib/workdir/git-new-workdir
index 75e8b25..888c34a 100755
--- a/contrib/workdir/git-new-workdir
+++ b/contrib/workdir/git-new-workdir
@@ -10,6 +10,10 @@ die () {
exit 128
}
+failed () {
+ die "unable to create new workdir '$new_workdir'!"
+}
+
if test $# -lt 2 || test $# -gt 3
then
usage "$0 <repository> <new_workdir> [<branch>]"
@@ -35,7 +39,7 @@ esac
# don't link to a configured bare repository
isbare=$(git --git-dir="$git_dir" config --bool --get core.bare)
-if test ztrue = z$isbare
+if test ztrue = "z$isbare"
then
die "\"$git_dir\" has core.bare set to true," \
" remove from \"$git_dir/config\" to use $0"
@@ -48,35 +52,54 @@ then
"a complete repository."
fi
-# don't recreate a workdir over an existing repository
-if test -e "$new_workdir"
+# make sure the links in the workdir have full paths to the original repo
+git_dir=$(cd "$git_dir" && pwd) || exit 1
+
+# don't recreate a workdir over an existing directory, unless it's empty
+if test -d "$new_workdir"
then
- die "destination directory '$new_workdir' already exists."
+ if test $(ls -a1 "$new_workdir/." | wc -l) -ne 2
+ then
+ die "destination directory '$new_workdir' is not empty."
+ fi
+ cleandir="$new_workdir/.git"
+else
+ cleandir="$new_workdir"
fi
-# make sure the links use full paths
-git_dir=$(cd "$git_dir"; pwd)
+mkdir -p "$new_workdir/.git" || failed
+cleandir=$(cd "$cleandir" && pwd) || failed
-# create the workdir
-mkdir -p "$new_workdir/.git" || die "unable to create \"$new_workdir\"!"
+cleanup () {
+ rm -rf "$cleandir"
+}
+siglist="0 1 2 15"
+trap cleanup $siglist
# create the links to the original repo. explicitly exclude index, HEAD and
# logs/HEAD from the list since they are purely related to the current working
# directory, and should not be shared.
for x in config refs logs/refs objects info hooks packed-refs remotes rr-cache svn
do
+ # create a containing directory if needed
case $x in
*/*)
- mkdir -p "$(dirname "$new_workdir/.git/$x")"
+ mkdir -p "$new_workdir/.git/${x%/*}"
;;
esac
- ln -s "$git_dir/$x" "$new_workdir/.git/$x"
+
+ ln -s "$git_dir/$x" "$new_workdir/.git/$x" || failed
done
-# now setup the workdir
-cd "$new_workdir"
+# commands below this are run in the context of the new workdir
+cd "$new_workdir" || failed
+
# copy the HEAD from the original repository as a default branch
-cp "$git_dir/HEAD" .git/HEAD
-# checkout the branch (either the same as HEAD from the original repository, or
-# the one that was asked for)
+cp "$git_dir/HEAD" .git/HEAD || failed
+
+# the workdir is set up. if the checkout fails, the user can fix it.
+trap - $siglist
+
+# checkout the branch (either the same as HEAD from the original repository,
+# or the one that was asked for)
git checkout -f $branch
diff --git a/credential-store.c b/credential-store.c
index d435514..925d3f4 100644
--- a/credential-store.c
+++ b/credential-store.c
@@ -118,7 +118,7 @@ static int lookup_credential(const char *fn, struct credential *c)
int main(int argc, char **argv)
{
const char * const usage[] = {
- "git credential-store [options] <action>",
+ "git credential-store [<options>] <action>",
NULL
};
const char *op;
diff --git a/credential.c b/credential.c
index 1886ea5..b146ad8 100644
--- a/credential.c
+++ b/credential.c
@@ -173,6 +173,8 @@ int credential_read(struct credential *c, FILE *fp)
c->path = xstrdup(value);
} else if (!strcmp(key, "url")) {
credential_from_url(c, value);
+ } else if (!strcmp(key, "quit")) {
+ c->quit = !!git_config_bool("quit", value);
}
/*
* Ignore other lines; we don't know what they mean, but
@@ -274,6 +276,9 @@ void credential_fill(struct credential *c)
credential_do(c, c->helpers.items[i].string, "get");
if (c->username && c->password)
return;
+ if (c->quit)
+ die("credential helper '%s' told us to quit",
+ c->helpers.items[i].string);
}
credential_getpass(c);
diff --git a/credential.h b/credential.h
index 0c3e85e..6b0cd16 100644
--- a/credential.h
+++ b/credential.h
@@ -7,6 +7,7 @@ struct credential {
struct string_list helpers;
unsigned approved:1,
configured:1,
+ quit:1,
use_http_path:1;
char *username;
diff --git a/date.c b/date.c
index 59dfe57..3eba2df 100644
--- a/date.c
+++ b/date.c
@@ -405,9 +405,9 @@ static int is_date(int year, int month, int day, struct tm *now_tm, time_t now,
return 0;
}
-static int match_multi_number(unsigned long num, char c, const char *date, char *end, struct tm *tm)
+static int match_multi_number(unsigned long num, char c, const char *date,
+ char *end, struct tm *tm, time_t now)
{
- time_t now;
struct tm now_tm;
struct tm *refuse_future;
long num2, num3;
@@ -433,17 +433,18 @@ static int match_multi_number(unsigned long num, char c, const char *date, char
case '-':
case '/':
case '.':
- now = time(NULL);
+ if (!now)
+ now = time(NULL);
refuse_future = NULL;
if (gmtime_r(&now, &now_tm))
refuse_future = &now_tm;
if (num > 70) {
/* yyyy-mm-dd? */
- if (is_date(num, num2, num3, refuse_future, now, tm))
+ if (is_date(num, num2, num3, NULL, now, tm))
break;
/* yyyy-dd-mm? */
- if (is_date(num, num3, num2, refuse_future, now, tm))
+ if (is_date(num, num3, num2, NULL, now, tm))
break;
}
/* Our eastern European friends say dd.mm.yy[yy]
@@ -513,7 +514,7 @@ static int match_digit(const char *date, struct tm *tm, int *offset, int *tm_gmt
case '/':
case '-':
if (isdigit(end[1])) {
- int match = match_multi_number(num, *end, date, end, tm);
+ int match = match_multi_number(num, *end, date, end, tm, 0);
if (match)
return match;
}
@@ -1013,7 +1014,8 @@ static const char *approxidate_alpha(const char *date, struct tm *tm, struct tm
return end;
}
-static const char *approxidate_digit(const char *date, struct tm *tm, int *num)
+static const char *approxidate_digit(const char *date, struct tm *tm, int *num,
+ time_t now)
{
char *end;
unsigned long number = strtoul(date, &end, 10);
@@ -1024,7 +1026,8 @@ static const char *approxidate_digit(const char *date, struct tm *tm, int *num)
case '/':
case '-':
if (isdigit(end[1])) {
- int match = match_multi_number(number, *end, date, end, tm);
+ int match = match_multi_number(number, *end, date, end,
+ tm, now);
if (match)
return date + match;
}
@@ -1087,7 +1090,7 @@ static unsigned long approxidate_str(const char *date,
date++;
if (isdigit(c)) {
pending_number(&tm, &number);
- date = approxidate_digit(date-1, &tm, &number);
+ date = approxidate_digit(date-1, &tm, &number, time_sec);
touched = 1;
continue;
}
diff --git a/diff-lib.c b/diff-lib.c
index 875aff8..a85c497 100644
--- a/diff-lib.c
+++ b/diff-lib.c
@@ -101,6 +101,7 @@ int run_diff_files(struct rev_info *revs, unsigned int option)
struct cache_entry *ce = active_cache[i];
int changed;
unsigned dirty_submodule = 0;
+ const unsigned char *old_sha1, *new_sha1;
if (diff_can_quit_early(&revs->diffopt))
break;
@@ -224,9 +225,12 @@ int run_diff_files(struct rev_info *revs, unsigned int option)
continue;
}
oldmode = ce->ce_mode;
+ old_sha1 = ce->sha1;
+ new_sha1 = changed ? null_sha1 : ce->sha1;
diff_change(&revs->diffopt, oldmode, newmode,
- ce->sha1, (changed ? null_sha1 : ce->sha1),
- !is_null_sha1(ce->sha1), (changed ? 0 : !is_null_sha1(ce->sha1)),
+ old_sha1, new_sha1,
+ !is_null_sha1(old_sha1),
+ !is_null_sha1(new_sha1),
ce->name, 0, dirty_submodule);
}
diff --git a/diffcore-break.c b/diffcore-break.c
index 1d9e530..5473493 100644
--- a/diffcore-break.c
+++ b/diffcore-break.c
@@ -246,6 +246,13 @@ static void merge_broken(struct diff_filepair *p,
dp = diff_queue(outq, d->one, c->two);
dp->score = p->score;
+ /*
+ * We will be one extra user of the same src side of the
+ * broken pair, if it was used as the rename source for other
+ * paths elsewhere. Increment to mark that the path stays
+ * in the resulting tree.
+ */
+ d->one->rename_used++;
diff_free_filespec_data(d->two);
diff_free_filespec_data(c->one);
free(d);
diff --git a/environment.c b/environment.c
index 565f652..1ade5c9 100644
--- a/environment.c
+++ b/environment.c
@@ -64,6 +64,16 @@ int precomposed_unicode = -1; /* see probe_utf8_pathname_composition() */
struct startup_info *startup_info;
unsigned long pack_size_limit_cfg;
+#ifndef PROTECT_HFS_DEFAULT
+#define PROTECT_HFS_DEFAULT 0
+#endif
+int protect_hfs = PROTECT_HFS_DEFAULT;
+
+#ifndef PROTECT_NTFS_DEFAULT
+#define PROTECT_NTFS_DEFAULT 0
+#endif
+int protect_ntfs = PROTECT_NTFS_DEFAULT;
+
/*
* The character that begins a commented line in user-editable file
* that is subject to stripspace.
diff --git a/ewah/ewok.h b/ewah/ewok.h
index f6ad190..13c6e20 100644
--- a/ewah/ewok.h
+++ b/ewah/ewok.h
@@ -47,7 +47,8 @@ static inline uint32_t ewah_bit_popcount64(uint64_t x)
return (x * 0x0101010101010101ULL) >> 56;
}
-#ifdef __GNUC__
+/* __builtin_ctzll was not available until 3.4.0 */
+#if defined(__GNUC__) && (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR > 3))
#define ewah_bit_ctz64(x) __builtin_ctzll(x)
#else
static inline int ewah_bit_ctz64(uint64_t x)
diff --git a/exec_cmd.c b/exec_cmd.c
index 698e752..8ab37b5 100644
--- a/exec_cmd.c
+++ b/exec_cmd.c
@@ -6,7 +6,7 @@
static const char *argv_exec_path;
static const char *argv0_path;
-const char *system_path(const char *path)
+char *system_path(const char *path)
{
#ifdef RUNTIME_PREFIX
static const char *prefix;
@@ -16,7 +16,7 @@ const char *system_path(const char *path)
struct strbuf d = STRBUF_INIT;
if (is_absolute_path(path))
- return path;
+ return xstrdup(path);
#ifdef RUNTIME_PREFIX
assert(argv0_path);
@@ -34,8 +34,7 @@ const char *system_path(const char *path)
#endif
strbuf_addf(&d, "%s/%s", prefix, path);
- path = strbuf_detach(&d, NULL);
- return path;
+ return strbuf_detach(&d, NULL);
}
const char *git_extract_argv0_path(const char *argv0)
diff --git a/exec_cmd.h b/exec_cmd.h
index e4c9702..93b0c02 100644
--- a/exec_cmd.h
+++ b/exec_cmd.h
@@ -9,6 +9,6 @@ extern const char **prepare_git_cmd(const char **argv);
extern int execv_git_cmd(const char **argv); /* NULL terminated */
LAST_ARG_MUST_BE_NULL
extern int execl_git_cmd(const char *cmd, ...);
-extern const char *system_path(const char *path);
+extern char *system_path(const char *path);
#endif /* GIT_EXEC_CMD_H */
diff --git a/fsck.c b/fsck.c
index 2fffa43..10bcb65 100644
--- a/fsck.c
+++ b/fsck.c
@@ -7,6 +7,7 @@
#include "tag.h"
#include "fsck.h"
#include "refs.h"
+#include "utf8.h"
static int fsck_walk_tree(struct tree *tree, fsck_walk_func walk, void *data)
{
@@ -171,7 +172,9 @@ static int fsck_tree(struct tree *item, int strict, fsck_error error_func)
has_empty_name |= !*name;
has_dot |= !strcmp(name, ".");
has_dotdot |= !strcmp(name, "..");
- has_dotgit |= !strcmp(name, ".git");
+ has_dotgit |= (!strcmp(name, ".git") ||
+ is_hfs_dotgit(name) ||
+ is_ntfs_dotgit(name));
has_zero_pad |= *(char *)desc.buffer == '0';
update_tree_entry(&desc);
@@ -423,7 +426,8 @@ static int fsck_tag_buffer(struct tag *tag, const char *data,
}
strbuf_addf(&sb, "refs/tags/%.*s", (int)(eol - buffer), buffer);
if (check_refname_format(sb.buf, 0))
- error_func(&tag->object, FSCK_WARN, "invalid 'tag' name: %s", buffer);
+ error_func(&tag->object, FSCK_WARN, "invalid 'tag' name: %.*s",
+ (int)(eol - buffer), buffer);
buffer = eol + 1;
if (!skip_prefix(buffer, "tagger ", &buffer))
diff --git a/gettext.h b/gettext.h
index 7671d09..dc1722d 100644
--- a/gettext.h
+++ b/gettext.h
@@ -63,6 +63,30 @@ const char *Q_(const char *msgid, const char *plu, unsigned long n)
}
/* Mark msgid for translation but do not translate it. */
+#if !USE_PARENS_AROUND_GETTEXT_N
#define N_(msgid) msgid
+#else
+/*
+ * Strictly speaking, this will lead to invalid C when
+ * used this way:
+ * static const char s[] = N_("FOO");
+ * which will expand to
+ * static const char s[] = ("FOO");
+ * and in valid C, the initializer on the right hand side must
+ * be without the parentheses. But many compilers do accept it
+ * as a language extension and it will allow us to catch mistakes
+ * like:
+ * static const char *msgs[] = {
+ * N_("one")
+ * N_("two"),
+ * N_("three"),
+ * NULL
+ * };
+ * (notice the missing comma on one of the lines) by forcing
+ * a compilation error, because parenthesised ("one") ("two")
+ * will not get silently turned into ("onetwo").
+ */
+#define N_(msgid) (msgid)
+#endif
#endif
diff --git a/git-add--interactive.perl b/git-add--interactive.perl
index 1fadd69..77876d4 100755
--- a/git-add--interactive.perl
+++ b/git-add--interactive.perl
@@ -515,6 +515,9 @@ sub error_msg {
sub list_and_choose {
my ($opts, @stuff) = @_;
my (@chosen, @return);
+ if (!@stuff) {
+ return @return;
+ }
my $i;
my @prefixes = find_unique_prefixes(@stuff) unless $opts->{LIST_ONLY};
@@ -725,6 +728,8 @@ sub add_untracked_cmd {
if (@add) {
system(qw(git update-index --add --), @add);
say_n_paths('added', @add);
+ } else {
+ print "No untracked files.\n";
}
print "\n";
}
@@ -1356,6 +1361,7 @@ sub patch_update_file {
$patch_mode_flavour{TARGET},
" [y,n,q,a,d,/$other,?]? ";
my $line = prompt_single_character;
+ last unless defined $line;
if ($line) {
if ($line =~ /^y/i) {
$hunk[$ix]{USE} = 1;
diff --git a/git-am.sh b/git-am.sh
index ee61a77..a67d0f9 100755
--- a/git-am.sh
+++ b/git-am.sh
@@ -17,6 +17,7 @@ s,signoff add a Signed-off-by line to the commit message
u,utf8 recode into utf8 (default)
k,keep pass -k flag to git-mailinfo
keep-non-patch pass -b flag to git-mailinfo
+m,message-id pass -m flag to git-mailinfo
keep-cr pass --keep-cr flag to git-mailsplit for mbox format
no-keep-cr do not pass --keep-cr flag to git-mailsplit independent of am.keepcr
c,scissors strip everything before a scissors line
@@ -371,13 +372,18 @@ split_patches () {
prec=4
dotest="$GIT_DIR/rebase-apply"
sign= utf8=t keep= keepcr= skip= interactive= resolved= rebasing= abort=
-resolvemsg= resume= scissors= no_inbody_headers=
+messageid= resolvemsg= resume= scissors= no_inbody_headers=
git_apply_opt=
committer_date_is_author_date=
ignore_date=
allow_rerere_autoupdate=
gpg_sign_opt=
+if test "$(git config --bool --get am.messageid)" = true
+then
+ messageid=t
+fi
+
if test "$(git config --bool --get am.keepcr)" = true
then
keepcr=t
@@ -400,6 +406,10 @@ it will be removed. Please do not use it anymore."
utf8=t ;; # this is now default
--no-utf8)
utf8= ;;
+ -m|--message-id)
+ messageid=t ;;
+ --no-message-id)
+ messageid=f ;;
-k|--keep)
keep=t ;;
--keep-non-patch)
@@ -567,6 +577,7 @@ Use \"git am --abort\" to remove it.")"
echo "$sign" >"$dotest/sign"
echo "$utf8" >"$dotest/utf8"
echo "$keep" >"$dotest/keep"
+ echo "$messageid" >"$dotest/messageid"
echo "$scissors" >"$dotest/scissors"
echo "$no_inbody_headers" >"$dotest/no_inbody_headers"
echo "$GIT_QUIET" >"$dotest/quiet"
@@ -621,6 +632,12 @@ b)
*)
keep= ;;
esac
+case "$(cat "$dotest/messageid")" in
+t)
+ messageid=-m ;;
+f)
+ messageid= ;;
+esac
case "$(cat "$dotest/scissors")" in
t)
scissors=--scissors ;;
@@ -692,7 +709,7 @@ do
get_author_ident_from_commit "$commit" >"$dotest/author-script"
git diff-tree --root --binary --full-index "$commit" >"$dotest/patch"
else
- git mailinfo $keep $no_inbody_headers $scissors $utf8 "$dotest/msg" "$dotest/patch" \
+ git mailinfo $keep $no_inbody_headers $messageid $scissors $utf8 "$dotest/msg" "$dotest/patch" \
<"$dotest/$msgnum" >"$dotest/info" ||
stop_here $this
diff --git a/git-bisect.sh b/git-bisect.sh
index 6cda2b5..ae3fec2 100755
--- a/git-bisect.sh
+++ b/git-bisect.sh
@@ -127,7 +127,7 @@ bisect_start() {
if test "z$mode" != "z--no-checkout"
then
git checkout "$start_head" -- ||
- die "$(eval_gettext "Checking out '\$start_head' failed. Try 'git bisect reset <validbranch>'.")"
+ die "$(eval_gettext "Checking out '\$start_head' failed. Try 'git bisect reset <valid-branch>'.")"
fi
else
# Get rev from where we start.
@@ -237,15 +237,18 @@ bisect_state() {
check_expected_revs "$rev" ;;
2,bad|*,good|*,skip)
shift
- eval=''
+ hash_list=''
for rev in "$@"
do
sha=$(git rev-parse --verify "$rev^{commit}") ||
die "$(eval_gettext "Bad rev input: \$rev")"
- eval="$eval bisect_write '$state' '$sha'; "
+ hash_list="$hash_list $sha"
done
- eval "$eval"
- check_expected_revs "$@" ;;
+ for rev in $hash_list
+ do
+ bisect_write "$state" "$rev"
+ done
+ check_expected_revs $hash_list ;;
*,bad)
die "$(gettext "'git bisect bad' can take only one argument.")" ;;
*)
diff --git a/git-compat-util.h b/git-compat-util.h
index 400e921..3455c5e 100644
--- a/git-compat-util.h
+++ b/git-compat-util.h
@@ -75,7 +75,8 @@
# endif
#elif !defined(__APPLE__) && !defined(__FreeBSD__) && !defined(__USLC__) && \
!defined(_M_UNIX) && !defined(__sgi) && !defined(__DragonFly__) && \
- !defined(__TANDEM) && !defined(__QNX__) && !defined(__MirBSD__)
+ !defined(__TANDEM) && !defined(__QNX__) && !defined(__MirBSD__) && \
+ !defined(__CYGWIN__)
#define _XOPEN_SOURCE 600 /* glibc2 and AIX 5.3L need 500, OpenBSD needs 600 for S_ISLNK() */
#define _XOPEN_SOURCE_EXTENDED 1 /* AIX 5.3L needs this */
#endif
@@ -211,8 +212,18 @@ extern char *gitbasename(char *);
#endif
#ifndef NO_OPENSSL
+#ifdef __APPLE__
+#define __AVAILABILITY_MACROS_USES_AVAILABILITY 0
+#include <AvailabilityMacros.h>
+#undef DEPRECATED_ATTRIBUTE
+#define DEPRECATED_ATTRIBUTE
+#undef __AVAILABILITY_MACROS_USES_AVAILABILITY
+#endif
#include <openssl/ssl.h>
#include <openssl/err.h>
+#ifdef NO_HMAC_CTX_CLEANUP
+#define HMAC_CTX_cleanup HMAC_cleanup
+#endif
#endif
/* On most systems <netdb.h> would have given us this, but
@@ -474,6 +485,40 @@ extern int git_munmap(void *start, size_t length);
#define on_disk_bytes(st) ((st).st_blocks * 512)
#endif
+#ifdef NEEDS_MODE_TRANSLATION
+#undef S_IFMT
+#undef S_IFREG
+#undef S_IFDIR
+#undef S_IFLNK
+#undef S_IFBLK
+#undef S_IFCHR
+#undef S_IFIFO
+#undef S_IFSOCK
+#define S_IFMT 0170000
+#define S_IFREG 0100000
+#define S_IFDIR 0040000
+#define S_IFLNK 0120000
+#define S_IFBLK 0060000
+#define S_IFCHR 0020000
+#define S_IFIFO 0010000
+#define S_IFSOCK 0140000
+#ifdef stat
+#undef stat
+#endif
+#define stat(path, buf) git_stat(path, buf)
+extern int git_stat(const char *, struct stat *);
+#ifdef fstat
+#undef fstat
+#endif
+#define fstat(fd, buf) git_fstat(fd, buf)
+extern int git_fstat(int, struct stat *);
+#ifdef lstat
+#undef lstat
+#endif
+#define lstat(path, buf) git_lstat(path, buf)
+extern int git_lstat(const char *, struct stat *);
+#endif
+
#define DEFAULT_PACKED_GIT_LIMIT \
((1024L * 1024L) * (sizeof(void*) >= 8 ? 8192 : 256))
@@ -636,6 +681,11 @@ extern char *xgetcwd(void);
#define REALLOC_ARRAY(x, alloc) (x) = xrealloc((x), (alloc) * sizeof(*(x)))
+static inline char *xstrdup_or_null(const char *str)
+{
+ return str ? xstrdup(str) : NULL;
+}
+
static inline size_t xsize_t(off_t len)
{
if (len > (size_t) len)
@@ -828,4 +878,8 @@ struct tm *git_gmtime_r(const time_t *, struct tm *);
#define gmtime_r git_gmtime_r
#endif
+#if !defined(USE_PARENS_AROUND_GETTEXT_N) && defined(__GNUC__)
+#define USE_PARENS_AROUND_GETTEXT_N 1
+#endif
+
#endif
diff --git a/git-p4.py b/git-p4.py
index ff132b2..549022e 100755
--- a/git-p4.py
+++ b/git-p4.py
@@ -1442,7 +1442,7 @@ class P4Submit(Command, P4UserMap):
print " " + self.clientPath
print
print "To submit, use \"p4 submit\" to write a new description,"
- print "or \"p4 submit -i %s\" to use the one prepared by" \
+ print "or \"p4 submit -i <%s\" to use the one prepared by" \
" \"git p4\"." % fileName
print "You can delete the file \"%s\" when finished." % fileName
@@ -1915,7 +1915,10 @@ class P4Sync(Command, P4UserMap):
optparse.make_option("--keep-path", dest="keepRepoPath", action='store_true',
help="Keep entire BRANCH/DIR/SUBDIR prefix during import"),
optparse.make_option("--use-client-spec", dest="useClientSpec", action='store_true',
- help="Only sync files that are included in the Perforce Client Spec")
+ help="Only sync files that are included in the Perforce Client Spec"),
+ optparse.make_option("-/", dest="cloneExclude",
+ action="append", type="string",
+ help="exclude depot path"),
]
self.description = """Imports from Perforce into a git repository.\n
example:
@@ -1950,6 +1953,12 @@ class P4Sync(Command, P4UserMap):
if gitConfig("git-p4.syncFromOrigin") == "false":
self.syncWithOrigin = False
+ # This is required for the "append" cloneExclude action
+ def ensure_value(self, attr, value):
+ if not hasattr(self, attr) or getattr(self, attr) is None:
+ setattr(self, attr, value)
+ return getattr(self, attr)
+
# Force a checkpoint in fast-import and wait for it to finish
def checkpoint(self):
self.gitStream.write("checkpoint\n\n")
@@ -3101,9 +3110,6 @@ class P4Clone(P4Sync):
optparse.make_option("--destination", dest="cloneDestination",
action='store', default=None,
help="where to leave result of the clone"),
- optparse.make_option("-/", dest="cloneExclude",
- action="append", type="string",
- help="exclude depot path"),
optparse.make_option("--bare", dest="cloneBare",
action="store_true", default=False),
]
@@ -3111,12 +3117,6 @@ class P4Clone(P4Sync):
self.needsGit = False
self.cloneBare = False
- # This is required for the "append" cloneExclude action
- def ensure_value(self, attr, value):
- if not hasattr(self, attr) or getattr(self, attr) is None:
- setattr(self, attr, value)
- return getattr(self, attr)
-
def defaultDestination(self, args):
## TODO: use common prefix of args?
depotPath = args[0]
diff --git a/git-rebase--interactive.sh b/git-rebase--interactive.sh
index b64dd28..c96b984 100644
--- a/git-rebase--interactive.sh
+++ b/git-rebase--interactive.sh
@@ -961,14 +961,13 @@ else
revisions=$onto...$orig_head
shortrevisions=$shorthead
fi
-git rev-list $merges_option --pretty=oneline --abbrev-commit \
- --abbrev=7 --reverse --left-right --topo-order \
+git rev-list $merges_option --pretty=oneline --reverse --left-right --topo-order \
$revisions ${restrict_revision+^$restrict_revision} | \
sed -n "s/^>//p" |
-while read -r shortsha1 rest
+while read -r sha1 rest
do
- if test -z "$keep_empty" && is_empty_commit $shortsha1 && ! is_merge_commit $shortsha1
+ if test -z "$keep_empty" && is_empty_commit $sha1 && ! is_merge_commit $sha1
then
comment_out="$comment_char "
else
@@ -977,9 +976,8 @@ do
if test t != "$preserve_merges"
then
- printf '%s\n' "${comment_out}pick $shortsha1 $rest" >>"$todo"
+ printf '%s\n' "${comment_out}pick $sha1 $rest" >>"$todo"
else
- sha1=$(git rev-parse $shortsha1)
if test -z "$rebase_root"
then
preserve=t
@@ -996,7 +994,7 @@ do
if test f = "$preserve"
then
touch "$rewritten"/$sha1
- printf '%s\n' "${comment_out}pick $shortsha1 $rest" >>"$todo"
+ printf '%s\n' "${comment_out}pick $sha1 $rest" >>"$todo"
fi
fi
done
@@ -1020,8 +1018,8 @@ then
# just the history of its first-parent for others that will
# be rebasing on top of it
git rev-list --parents -1 $rev | cut -d' ' -s -f2 > "$dropped"/$rev
- short=$(git rev-list -1 --abbrev-commit --abbrev=7 $rev)
- sane_grep -v "^[a-z][a-z]* $short" <"$todo" > "${todo}2" ; mv "${todo}2" "$todo"
+ sha1=$(git rev-list -1 $rev)
+ sane_grep -v "^[a-z][a-z]* $sha1" <"$todo" > "${todo}2" ; mv "${todo}2" "$todo"
rm "$rewritten"/$rev
fi
done
@@ -1031,9 +1029,11 @@ test -s "$todo" || echo noop >> "$todo"
test -n "$autosquash" && rearrange_squash "$todo"
test -n "$cmd" && add_exec_commands "$todo"
+todocount=$(git stripspace --strip-comments <"$todo" | wc -l)
+
cat >>"$todo" <<EOF
-$comment_char Rebase $shortrevisions onto $shortonto
+$comment_char Rebase $shortrevisions onto $shortonto ($todocount TODO item(s))
EOF
append_todo_help
git stripspace --comment-lines >>"$todo" <<\EOF
@@ -1052,6 +1052,7 @@ has_action "$todo" ||
return 2
cp "$todo" "$todo".backup
+collapse_todo_ids
git_sequence_editor "$todo" ||
die_abort "Could not execute editor"
diff --git a/git-remote-testgit.sh b/git-remote-testgit.sh
index a9c75a2..752c763 100755
--- a/git-remote-testgit.sh
+++ b/git-remote-testgit.sh
@@ -1,7 +1,13 @@
#!/bin/sh
# Copyright (c) 2012 Felipe Contreras
-alias=$1
+# The first argument can be a url when the fetch/push command was a url
+# instead of a configured remote. In this case, use a generic alias.
+if test "$1" = "testgit::$2"; then
+ alias=_
+else
+ alias=$1
+fi
url=$2
dir="$GIT_DIR/testgit/$alias"
diff --git a/git-send-email.perl b/git-send-email.perl
index 9949db0..3092ab3 100755
--- a/git-send-email.perl
+++ b/git-send-email.perl
@@ -54,10 +54,12 @@ git send-email [options] <file | directory | rev-list options >
--[no-]bcc <str> * Email Bcc:
--subject <str> * Email "Subject:"
--in-reply-to <str> * Email "In-Reply-To:"
+ --[no-]xmailer * Add "X-Mailer:" header (default).
--[no-]annotate * Review each patch that will be sent in an editor.
--compose * Open an editor for introduction.
--compose-encoding <str> * Encoding to assume for introduction.
--8bit-encoding <str> * Encoding to assume 8bit mails if undeclared
+ --transfer-encoding <str> * Transfer encoding to use (quoted-printable, 8bit, base64)
Sending:
--envelope-sender <str> * Email envelope sender.
@@ -145,10 +147,15 @@ my $have_mail_address = eval { require Mail::Address; 1 };
my $smtp;
my $auth;
+# Regexes for RFC 2047 productions.
+my $re_token = qr/[^][()<>@,;:\\"\/?.= \000-\037\177-\377]+/;
+my $re_encoded_text = qr/[^? \000-\037\177-\377]+/;
+my $re_encoded_word = qr/=\?($re_token)\?($re_token)\?($re_encoded_text)\?=/;
+
# Variables we fill in automatically, or via prompting:
my (@to,$no_to,@initial_to,@cc,$no_cc,@initial_cc,@bcclist,$no_bcc,@xh,
$initial_reply_to,$initial_subject,@files,
- $author,$sender,$smtp_authpass,$annotate,$compose,$time);
+ $author,$sender,$smtp_authpass,$annotate,$use_xmailer,$compose,$time);
my $envelope_sender;
@@ -206,6 +213,7 @@ my ($validate, $confirm);
my (@suppress_cc);
my ($auto_8bit_encoding);
my ($compose_encoding);
+my ($target_xfer_encoding);
my ($debug_net_smtp) = 0; # Net::SMTP, see send_message()
@@ -219,7 +227,8 @@ my %config_bool_settings = (
"signedoffcc" => [\$signed_off_by_cc, undef], # Deprecated
"validate" => [\$validate, 1],
"multiedit" => [\$multiedit, undef],
- "annotate" => [\$annotate, undef]
+ "annotate" => [\$annotate, undef],
+ "xmailer" => [\$use_xmailer, 1]
);
my %config_settings = (
@@ -242,6 +251,7 @@ my %config_settings = (
"from" => \$sender,
"assume8bitencoding" => \$auto_8bit_encoding,
"composeencoding" => \$compose_encoding,
+ "transferencoding" => \$target_xfer_encoding,
);
my %config_path_settings = (
@@ -314,10 +324,12 @@ my $rc = GetOptions("h" => \$help,
"envelope-sender=s" => \$envelope_sender,
"thread!" => \$thread,
"validate!" => \$validate,
+ "transfer-encoding=s" => \$target_xfer_encoding,
"format-patch!" => \$format_patch,
"8bit-encoding=s" => \$auto_8bit_encoding,
"compose-encoding=s" => \$compose_encoding,
"force" => \$force,
+ "xmailer!" => \$use_xmailer,
);
usage() if $help;
@@ -913,15 +925,26 @@ $time = time - scalar $#files;
sub unquote_rfc2047 {
local ($_) = @_;
- my $encoding;
- s{=\?([^?]+)\?q\?(.*?)\?=}{
- $encoding = $1;
- my $e = $2;
- $e =~ s/_/ /g;
- $e =~ s/=([0-9A-F]{2})/chr(hex($1))/eg;
- $e;
+ my $charset;
+ my $sep = qr/[ \t]+/;
+ s{$re_encoded_word(?:$sep$re_encoded_word)*}{
+ my @words = split $sep, $&;
+ foreach (@words) {
+ m/$re_encoded_word/;
+ $charset = $1;
+ my $encoding = $2;
+ my $text = $3;
+ if ($encoding eq 'q' || $encoding eq 'Q') {
+ $_ = $text;
+ s/_/ /g;
+ s/=([0-9A-F]{2})/chr(hex($1))/egi;
+ } else {
+ # other encodings not supported yet
+ }
+ }
+ join '', @words;
}eg;
- return wantarray ? ($_, $encoding) : $_;
+ return wantarray ? ($_, $charset) : $_;
}
sub quote_rfc2047 {
@@ -934,10 +957,8 @@ sub quote_rfc2047 {
sub is_rfc2047_quoted {
my $s = shift;
- my $token = qr/[^][()<>@,;:"\/?.= \000-\037\177-\377]+/;
- my $encoded_text = qr/[!->@-~]+/;
length($s) <= 75 &&
- $s =~ m/^(?:"[[:ascii:]]*"|=\?$token\?$token\?$encoded_text\?=)$/o;
+ $s =~ m/^(?:"[[:ascii:]]*"|$re_encoded_word)$/o;
}
sub subject_needs_rfc2047_quoting {
@@ -1163,8 +1184,10 @@ To: $to${ccline}
Subject: $subject
Date: $date
Message-Id: $message_id
-X-Mailer: git-send-email $gitversion
";
+ if ($use_xmailer) {
+ $header .= "X-Mailer: git-send-email $gitversion\n";
+ }
if ($reply_to) {
$header .= "In-Reply-To: $reply_to\n";
@@ -1324,6 +1347,8 @@ foreach my $t (@files) {
my $author_encoding;
my $has_content_type;
my $body_encoding;
+ my $xfer_encoding;
+ my $has_mime_version;
@to = ();
@cc = ();
@xh = ();
@@ -1394,9 +1419,16 @@ foreach my $t (@files) {
}
push @xh, $_;
}
+ elsif (/^MIME-Version/i) {
+ $has_mime_version = 1;
+ push @xh, $_;
+ }
elsif (/^Message-Id: (.*)/i) {
$message_id = $1;
}
+ elsif (/^Content-Transfer-Encoding: (.*)/i) {
+ $xfer_encoding = $1 if not defined $xfer_encoding;
+ }
elsif (!/^Date:\s/i && /^[-A-Za-z]+:\s+\S/) {
push @xh, $_;
}
@@ -1444,10 +1476,9 @@ foreach my $t (@files) {
if defined $cc_cmd && !$suppress_cc{'cccmd'};
if ($broken_encoding{$t} && !$has_content_type) {
+ $xfer_encoding = '8bit' if not defined $xfer_encoding;
$has_content_type = 1;
- push @xh, "MIME-Version: 1.0",
- "Content-Type: text/plain; charset=$auto_8bit_encoding",
- "Content-Transfer-Encoding: 8bit";
+ push @xh, "Content-Type: text/plain; charset=$auto_8bit_encoding";
$body_encoding = $auto_8bit_encoding;
}
@@ -1467,14 +1498,25 @@ foreach my $t (@files) {
}
}
else {
+ $xfer_encoding = '8bit' if not defined $xfer_encoding;
$has_content_type = 1;
push @xh,
- 'MIME-Version: 1.0',
- "Content-Type: text/plain; charset=$author_encoding",
- 'Content-Transfer-Encoding: 8bit';
+ "Content-Type: text/plain; charset=$author_encoding";
}
}
}
+ if (defined $target_xfer_encoding) {
+ $xfer_encoding = '8bit' if not defined $xfer_encoding;
+ $message = apply_transfer_encoding(
+ $message, $xfer_encoding, $target_xfer_encoding);
+ $xfer_encoding = $target_xfer_encoding;
+ }
+ if (defined $xfer_encoding) {
+ push @xh, "Content-Transfer-Encoding: $xfer_encoding";
+ }
+ if (defined $xfer_encoding or $has_content_type) {
+ unshift @xh, 'MIME-Version: 1.0' unless $has_mime_version;
+ }
$needs_confirm = (
$confirm eq "always" or
@@ -1543,6 +1585,32 @@ sub cleanup_compose_files {
$smtp->quit if $smtp;
+sub apply_transfer_encoding {
+ my $message = shift;
+ my $from = shift;
+ my $to = shift;
+
+ return $message if ($from eq $to and $from ne '7bit');
+
+ require MIME::QuotedPrint;
+ require MIME::Base64;
+
+ $message = MIME::QuotedPrint::decode($message)
+ if ($from eq 'quoted-printable');
+ $message = MIME::Base64::decode($message)
+ if ($from eq 'base64');
+
+ die "cannot send message as 7bit"
+ if ($to eq '7bit' and $message =~ /[^[:ascii:]]/);
+ return $message
+ if ($to eq '7bit' or $to eq '8bit');
+ return MIME::QuotedPrint::encode($message, "\n", 0)
+ if ($to eq 'quoted-printable');
+ return MIME::Base64::encode($message, "\n")
+ if ($to eq 'base64');
+ die "invalid transfer encoding";
+}
+
sub unique_email_list {
my %seen;
my @emails;
diff --git a/git-sh-setup.sh b/git-sh-setup.sh
index d968760..c42c6e6 100644
--- a/git-sh-setup.sh
+++ b/git-sh-setup.sh
@@ -81,7 +81,7 @@ if test -n "$OPTIONS_SPEC"; then
echo exit $?
)"
else
- dashless=$(basename "$0" | sed -e 's/-/ /')
+ dashless=$(basename -- "$0" | sed -e 's/-/ /')
usage() {
die "usage: $dashless $USAGE"
}
diff --git a/git-submodule.sh b/git-submodule.sh
index 9245abf..36797c3 100755
--- a/git-submodule.sh
+++ b/git-submodule.sh
@@ -423,7 +423,7 @@ cmd_add()
sed -e '
s|//*|/|g
s|^\(\./\)*||
- s|/\./|/|g
+ s|/\(\./\)*|/|g
:start
s|\([^/]*\)/\.\./||
tstart
diff --git a/git-svn.perl b/git-svn.perl
index b6e2186..32d109e 100755
--- a/git-svn.perl
+++ b/git-svn.perl
@@ -115,7 +115,7 @@ my ($_stdin, $_help, $_edit,
$_before, $_after,
$_merge, $_strategy, $_preserve_merges, $_dry_run, $_parents, $_local,
$_prefix, $_no_checkout, $_url, $_verbose,
- $_commit_url, $_tag, $_merge_info, $_interactive);
+ $_commit_url, $_tag, $_merge_info, $_interactive, $_set_svn_props);
# This is a refactoring artifact so Git::SVN can get at this git-svn switch.
sub opt_prefix { return $_prefix || '' }
@@ -193,6 +193,7 @@ my %cmd = (
'dry-run|n' => \$_dry_run,
'fetch-all|all' => \$_fetch_all,
'commit-url=s' => \$_commit_url,
+ 'set-svn-props=s' => \$_set_svn_props,
'revision|r=i' => \$_revision,
'no-rebase' => \$_no_rebase,
'mergeinfo=s' => \$_merge_info,
@@ -228,6 +229,9 @@ my %cmd = (
'propget' => [ \&cmd_propget,
'Print the value of a property on a file or directory',
{ 'revision|r=i' => \$_revision } ],
+ 'propset' => [ \&cmd_propset,
+ 'Set the value of a property on a file or directory - will be set on commit',
+ {} ],
'proplist' => [ \&cmd_proplist,
'List all properties of a file or directory',
{ 'revision|r=i' => \$_revision } ],
@@ -333,6 +337,12 @@ for (my $i = 0; $i < @ARGV; $i++) {
# make sure we're always running at the top-level working directory
if ($cmd && $cmd =~ /(?:clone|init|multi-init)$/) {
$ENV{GIT_DIR} ||= ".git";
+ # catch the submodule case
+ if (-f $ENV{GIT_DIR}) {
+ open(my $fh, '<', $ENV{GIT_DIR}) or
+ die "failed to open $ENV{GIT_DIR}: $!\n";
+ $ENV{GIT_DIR} = $1 if <$fh> =~ /^gitdir: (.+)$/;
+ }
} else {
my ($git_dir, $cdup);
git_cmd_try {
@@ -1376,6 +1386,49 @@ sub cmd_propget {
print $props->{$prop} . "\n";
}
+# cmd_propset (PROPNAME, PROPVAL, PATH)
+# ------------------------
+# Adjust the SVN property PROPNAME to PROPVAL for PATH.
+sub cmd_propset {
+ my ($propname, $propval, $path) = @_;
+ $path = '.' if not defined $path;
+ $path = $cmd_dir_prefix . $path;
+ usage(1) if not defined $propname;
+ usage(1) if not defined $propval;
+ my $file = basename($path);
+ my $dn = dirname($path);
+ my $cur_props = Git::SVN::Editor::check_attr( "svn-properties", $path );
+ my @new_props;
+ if (!$cur_props || $cur_props eq "unset" || $cur_props eq "" || $cur_props eq "set") {
+ push @new_props, "$propname=$propval";
+ } else {
+ # TODO: handle combining properties better
+ my @props = split(/;/, $cur_props);
+ my $replaced_prop;
+ foreach my $prop (@props) {
+ # Parse 'name=value' syntax and set the property.
+ if ($prop =~ /([^=]+)=(.*)/) {
+ my ($n,$v) = ($1,$2);
+ if ($n eq $propname) {
+ $v = $propval;
+ $replaced_prop = 1;
+ }
+ push @new_props, "$n=$v";
+ }
+ }
+ if (!$replaced_prop) {
+ push @new_props, "$propname=$propval";
+ }
+ }
+ my $attrfile = "$dn/.gitattributes";
+ open my $attrfh, '>>', $attrfile or die "Can't open $attrfile: $!\n";
+ # TODO: don't simply append here if $file already has svn-properties
+ my $new_props = join(';', @new_props);
+ print $attrfh "$file svn-properties=$new_props\n" or
+ die "write to $attrfile: $!\n";
+ close $attrfh or die "close $attrfile: $!\n";
+}
+
# cmd_proplist (PATH)
# -------------------
# Print the list of SVN properties for PATH.
diff --git a/git.c b/git.c
index 82d7a1c..8c7ee9c 100644
--- a/git.c
+++ b/git.c
@@ -1,15 +1,12 @@
#include "builtin.h"
-#include "cache.h"
#include "exec_cmd.h"
#include "help.h"
-#include "quote.h"
#include "run-command.h"
-#include "commit.h"
const char git_usage_string[] =
"git [--version] [--help] [-C <path>] [-c name=value]\n"
" [--exec-path[=<path>]] [--html-path] [--man-path] [--info-path]\n"
- " [-p|--paginate|--no-pager] [--no-replace-objects] [--bare]\n"
+ " [-p | --paginate | --no-pager] [--no-replace-objects] [--bare]\n"
" [--git-dir=<path>] [--work-tree=<path>] [--namespace=<name>]\n"
" <command> [<args>]";
diff --git a/grep.c b/grep.c
index 6e085f8..b58c7c6 100644
--- a/grep.c
+++ b/grep.c
@@ -1661,8 +1661,8 @@ void grep_source_init(struct grep_source *gs, enum grep_source_type type,
const void *identifier)
{
gs->type = type;
- gs->name = name ? xstrdup(name) : NULL;
- gs->path = path ? xstrdup(path) : NULL;
+ gs->name = xstrdup_or_null(name);
+ gs->path = xstrdup_or_null(path);
gs->buf = NULL;
gs->size = 0;
gs->driver = NULL;
diff --git a/http-push.c b/http-push.c
index 952f8ed..0beb7ab 100644
--- a/http-push.c
+++ b/http-push.c
@@ -1577,6 +1577,9 @@ static void fetch_symref(const char *path, char **symref, unsigned char *sha1)
if (buffer.len == 0)
return;
+ /* Cut off trailing newline. */
+ strbuf_rtrim(&buffer);
+
/* If it's a symref, set the refname; otherwise try for a sha1 */
if (skip_prefix(buffer.buf, "ref: ", &name)) {
*symref = xmemdupz(name, buffer.len - (name - buffer.buf));
diff --git a/http.c b/http.c
index 040f362..efdab09 100644
--- a/http.c
+++ b/http.c
@@ -62,12 +62,17 @@ static const char *user_agent;
static struct credential cert_auth = CREDENTIAL_INIT;
static int ssl_cert_password_required;
+#ifdef LIBCURL_CAN_HANDLE_AUTH_ANY
+static unsigned long http_auth_methods = CURLAUTH_ANY;
+#endif
static struct curl_slist *pragma_header;
static struct curl_slist *no_pragma_header;
static struct active_request_slot *active_queue_head;
+static char *cached_accept_language;
+
size_t fread_buffer(char *ptr, size_t eltsize, size_t nmemb, void *buffer_)
{
size_t size = eltsize * nmemb;
@@ -114,6 +119,37 @@ size_t fwrite_null(char *ptr, size_t eltsize, size_t nmemb, void *strbuf)
return eltsize * nmemb;
}
+static void closedown_active_slot(struct active_request_slot *slot)
+{
+ active_requests--;
+ slot->in_use = 0;
+}
+
+static void finish_active_slot(struct active_request_slot *slot)
+{
+ closedown_active_slot(slot);
+ curl_easy_getinfo(slot->curl, CURLINFO_HTTP_CODE, &slot->http_code);
+
+ if (slot->finished != NULL)
+ (*slot->finished) = 1;
+
+ /* Store slot results so they can be read after the slot is reused */
+ if (slot->results != NULL) {
+ slot->results->curl_result = slot->curl_result;
+ slot->results->http_code = slot->http_code;
+#if LIBCURL_VERSION_NUM >= 0x070a08
+ curl_easy_getinfo(slot->curl, CURLINFO_HTTPAUTH_AVAIL,
+ &slot->results->auth_avail);
+#else
+ slot->results->auth_avail = 0;
+#endif
+ }
+
+ /* Run callback if appropriate */
+ if (slot->callback_func != NULL)
+ slot->callback_func(slot->callback_data);
+}
+
#ifdef USE_CURL_MULTI
static void process_curl_messages(void)
{
@@ -515,6 +551,9 @@ void http_cleanup(void)
cert_auth.password = NULL;
}
ssl_cert_password_required = 0;
+
+ free(cached_accept_language);
+ cached_accept_language = NULL;
}
struct active_request_slot *get_active_slot(void)
@@ -580,6 +619,9 @@ struct active_request_slot *get_active_slot(void)
curl_easy_setopt(slot->curl, CURLOPT_UPLOAD, 0);
curl_easy_setopt(slot->curl, CURLOPT_HTTPGET, 1);
curl_easy_setopt(slot->curl, CURLOPT_FAILONERROR, 1);
+#ifdef LIBCURL_CAN_HANDLE_AUTH_ANY
+ curl_easy_setopt(slot->curl, CURLOPT_HTTPAUTH, http_auth_methods);
+#endif
if (http_auth.password)
init_curl_http_auth(slot->curl);
@@ -730,12 +772,6 @@ void run_active_slot(struct active_request_slot *slot)
#endif
}
-static void closedown_active_slot(struct active_request_slot *slot)
-{
- active_requests--;
- slot->in_use = 0;
-}
-
static void release_active_slot(struct active_request_slot *slot)
{
closedown_active_slot(slot);
@@ -752,31 +788,6 @@ static void release_active_slot(struct active_request_slot *slot)
#endif
}
-void finish_active_slot(struct active_request_slot *slot)
-{
- closedown_active_slot(slot);
- curl_easy_getinfo(slot->curl, CURLINFO_HTTP_CODE, &slot->http_code);
-
- if (slot->finished != NULL)
- (*slot->finished) = 1;
-
- /* Store slot results so they can be read after the slot is reused */
- if (slot->results != NULL) {
- slot->results->curl_result = slot->curl_result;
- slot->results->http_code = slot->http_code;
-#if LIBCURL_VERSION_NUM >= 0x070a08
- curl_easy_getinfo(slot->curl, CURLINFO_HTTPAUTH_AVAIL,
- &slot->results->auth_avail);
-#else
- slot->results->auth_avail = 0;
-#endif
- }
-
- /* Run callback if appropriate */
- if (slot->callback_func != NULL)
- slot->callback_func(slot->callback_data);
-}
-
void finish_all_active_slots(void)
{
struct active_request_slot *slot = active_queue_head;
@@ -839,7 +850,7 @@ char *get_remote_object_url(const char *url, const char *hex,
return strbuf_detach(&buf, NULL);
}
-int handle_curl_result(struct slot_results *results)
+static int handle_curl_result(struct slot_results *results)
{
/*
* If we see a failing http code with CURLE_OK, we have turned off
@@ -870,6 +881,9 @@ int handle_curl_result(struct slot_results *results)
credential_reject(&http_auth);
return HTTP_NOAUTH;
} else {
+#ifdef LIBCURL_CAN_HANDLE_AUTH_ANY
+ http_auth_methods &= ~CURLAUTH_GSSNEGOTIATE;
+#endif
return HTTP_REAUTH;
}
} else {
@@ -986,6 +1000,143 @@ static void extract_content_type(struct strbuf *raw, struct strbuf *type,
strbuf_addstr(charset, "ISO-8859-1");
}
+
+/*
+ * Guess the user's preferred languages from the value in LANGUAGE environment
+ * variable and LC_MESSAGES locale category if NO_GETTEXT is not defined.
+ *
+ * The result can be a colon-separated list like "ko:ja:en".
+ */
+static const char *get_preferred_languages(void)
+{
+ const char *retval;
+
+ retval = getenv("LANGUAGE");
+ if (retval && *retval)
+ return retval;
+
+#ifndef NO_GETTEXT
+ retval = setlocale(LC_MESSAGES, NULL);
+ if (retval && *retval &&
+ strcmp(retval, "C") &&
+ strcmp(retval, "POSIX"))
+ return retval;
+#endif
+
+ return NULL;
+}
+
+static void write_accept_language(struct strbuf *buf)
+{
+ /*
+ * MAX_DECIMAL_PLACES must not be larger than 3. If it is larger than
+ * that, q-value will be smaller than 0.001, the minimum q-value the
+ * HTTP specification allows. See
+ * http://tools.ietf.org/html/rfc7231#section-5.3.1 for q-value.
+ */
+ const int MAX_DECIMAL_PLACES = 3;
+ const int MAX_LANGUAGE_TAGS = 1000;
+ const int MAX_ACCEPT_LANGUAGE_HEADER_SIZE = 4000;
+ char **language_tags = NULL;
+ int num_langs = 0;
+ const char *s = get_preferred_languages();
+ int i;
+ struct strbuf tag = STRBUF_INIT;
+
+ /* Don't add Accept-Language header if no language is preferred. */
+ if (!s)
+ return;
+
+ /*
+ * Split the colon-separated string of preferred languages into
+ * language_tags array.
+ */
+ do {
+ /* collect language tag */
+ for (; *s && (isalnum(*s) || *s == '_'); s++)
+ strbuf_addch(&tag, *s == '_' ? '-' : *s);
+
+ /* skip .codeset, @modifier and any other unnecessary parts */
+ while (*s && *s != ':')
+ s++;
+
+ if (tag.len) {
+ num_langs++;
+ REALLOC_ARRAY(language_tags, num_langs);
+ language_tags[num_langs - 1] = strbuf_detach(&tag, NULL);
+ if (num_langs >= MAX_LANGUAGE_TAGS - 1) /* -1 for '*' */
+ break;
+ }
+ } while (*s++);
+
+ /* write Accept-Language header into buf */
+ if (num_langs) {
+ int last_buf_len = 0;
+ int max_q;
+ int decimal_places;
+ char q_format[32];
+
+ /* add '*' */
+ REALLOC_ARRAY(language_tags, num_langs + 1);
+ language_tags[num_langs++] = "*"; /* it's OK; this won't be freed */
+
+ /* compute decimal_places */
+ for (max_q = 1, decimal_places = 0;
+ max_q < num_langs && decimal_places <= MAX_DECIMAL_PLACES;
+ decimal_places++, max_q *= 10)
+ ;
+
+ sprintf(q_format, ";q=0.%%0%dd", decimal_places);
+
+ strbuf_addstr(buf, "Accept-Language: ");
+
+ for (i = 0; i < num_langs; i++) {
+ if (i > 0)
+ strbuf_addstr(buf, ", ");
+
+ strbuf_addstr(buf, language_tags[i]);
+
+ if (i > 0)
+ strbuf_addf(buf, q_format, max_q - i);
+
+ if (buf->len > MAX_ACCEPT_LANGUAGE_HEADER_SIZE) {
+ strbuf_remove(buf, last_buf_len, buf->len - last_buf_len);
+ break;
+ }
+
+ last_buf_len = buf->len;
+ }
+ }
+
+ /* free language tags -- last one is a static '*' */
+ for (i = 0; i < num_langs - 1; i++)
+ free(language_tags[i]);
+ free(language_tags);
+}
+
+/*
+ * Get an Accept-Language header which indicates user's preferred languages.
+ *
+ * Examples:
+ * LANGUAGE= -> ""
+ * LANGUAGE=ko:en -> "Accept-Language: ko, en; q=0.9, *; q=0.1"
+ * LANGUAGE=ko_KR.UTF-8:sr@latin -> "Accept-Language: ko-KR, sr; q=0.9, *; q=0.1"
+ * LANGUAGE=ko LANG=en_US.UTF-8 -> "Accept-Language: ko, *; q=0.1"
+ * LANGUAGE= LANG=en_US.UTF-8 -> "Accept-Language: en-US, *; q=0.1"
+ * LANGUAGE= LANG=C -> ""
+ */
+static const char *get_accept_language(void)
+{
+ if (!cached_accept_language) {
+ struct strbuf buf = STRBUF_INIT;
+ write_accept_language(&buf);
+ if (buf.len > 0)
+ cached_accept_language = strbuf_detach(&buf, NULL);
+ }
+
+ return cached_accept_language;
+}
+
/* http_request() targets */
#define HTTP_REQUEST_STRBUF 0
#define HTTP_REQUEST_FILE 1
@@ -998,6 +1149,7 @@ static int http_request(const char *url,
struct slot_results results;
struct curl_slist *headers = NULL;
struct strbuf buf = STRBUF_INIT;
+ const char *accept_language;
int ret;
slot = get_active_slot();
@@ -1023,6 +1175,11 @@ static int http_request(const char *url,
fwrite_buffer);
}
+ accept_language = get_accept_language();
+
+ if (accept_language)
+ headers = curl_slist_append(headers, accept_language);
+
strbuf_addstr(&buf, "Pragma:");
if (options && options->no_cache)
strbuf_addstr(&buf, " no-cache");
@@ -1240,7 +1397,7 @@ static int fetch_and_setup_pack_index(struct packed_git **packs_head,
int ret;
if (has_pack_index(sha1)) {
- new_pack = parse_pack_index(sha1, NULL);
+ new_pack = parse_pack_index(sha1, sha1_pack_index_name(sha1));
if (!new_pack)
return -1; /* parse_pack_index() already issued error message */
goto add_pack;
diff --git a/http.h b/http.h
index 473179b..49afe39 100644
--- a/http.h
+++ b/http.h
@@ -85,9 +85,7 @@ extern curlioerr ioctl_buffer(CURL *handle, int cmd, void *clientp);
extern struct active_request_slot *get_active_slot(void);
extern int start_active_slot(struct active_request_slot *slot);
extern void run_active_slot(struct active_request_slot *slot);
-extern void finish_active_slot(struct active_request_slot *slot);
extern void finish_all_active_slots(void);
-extern int handle_curl_result(struct slot_results *results);
/*
* This will run one slot to completion in a blocking manner, similar to how
diff --git a/imap-send.c b/imap-send.c
index 70bcc7a..d69887d 100644
--- a/imap-send.c
+++ b/imap-send.c
@@ -26,11 +26,24 @@
#include "credential.h"
#include "exec_cmd.h"
#include "run-command.h"
+#include "parse-options.h"
#ifdef NO_OPENSSL
typedef void *SSL;
#endif
+#ifdef USE_CURL_FOR_IMAP_SEND
+#include "http.h"
+#endif
+
+static int verbosity;
+static int use_curl; /* strictly opt in */
-static const char imap_send_usage[] = "git imap-send < <mbox>";
+static const char * const imap_send_usage[] = { "git imap-send [-v] [-q] [--[no-]curl] < <mbox>", NULL };
+
+static struct option imap_send_options[] = {
+ OPT__VERBOSITY(&verbosity),
+ OPT_BOOL(0, "curl", &use_curl, "use libcurl to communicate with the IMAP server"),
+ OPT_END()
+};
#undef DRV_OK
#define DRV_OK 0
@@ -38,8 +51,6 @@ static const char imap_send_usage[] = "git imap-send < <mbox>";
#define DRV_BOX_BAD -2
#define DRV_STORE_BAD -3
-static int Verbose, Quiet;
-
__attribute__((format (printf, 1, 2)))
static void imap_info(const char *, ...);
__attribute__((format (printf, 1, 2)))
@@ -418,7 +429,7 @@ static int buffer_gets(struct imap_buffer *b, char **s)
if (b->buf[b->offset + 1] == '\n') {
b->buf[b->offset] = 0; /* terminate the string */
b->offset += 2; /* next line */
- if (Verbose)
+ if (0 < verbosity)
puts(*s);
return 0;
}
@@ -433,7 +444,7 @@ static void imap_info(const char *msg, ...)
{
va_list va;
- if (!Quiet) {
+ if (0 <= verbosity) {
va_start(va, msg);
vprintf(msg, va);
va_end(va);
@@ -445,7 +456,7 @@ static void imap_warn(const char *msg, ...)
{
va_list va;
- if (Quiet < 2) {
+ if (-2 < verbosity) {
va_start(va, msg);
vfprintf(stderr, msg, va);
va_end(va);
@@ -522,7 +533,7 @@ static struct imap_cmd *issue_imap_cmd(struct imap_store *ctx,
cmd->tag, cmd->cmd, cmd->cb.dlen,
CAP(LITERALPLUS) ? "+" : "");
- if (Verbose) {
+ if (0 < verbosity) {
if (imap->num_in_progress)
printf("(%d in progress) ", imap->num_in_progress);
if (!starts_with(cmd->cmd, "LOGIN"))
@@ -1338,26 +1349,166 @@ static void git_imap_config(void)
git_config_get_string("imap.authmethod", &server.auth_method);
}
-int main(int argc, char **argv)
+static int append_msgs_to_imap(struct imap_server_conf *server,
+ struct strbuf* all_msgs, int total)
{
- struct strbuf all_msgs = STRBUF_INIT;
struct strbuf msg = STRBUF_INIT;
struct imap_store *ctx = NULL;
int ofs = 0;
int r;
- int total, n = 0;
+ int n = 0;
+
+ ctx = imap_open_store(server, server->folder);
+ if (!ctx) {
+ fprintf(stderr, "failed to open store\n");
+ return 1;
+ }
+ ctx->name = server->folder;
+
+ fprintf(stderr, "sending %d message%s\n", total, (total != 1) ? "s" : "");
+ while (1) {
+ unsigned percent = n * 100 / total;
+
+ fprintf(stderr, "%4u%% (%d/%d) done\r", percent, n, total);
+
+ if (!split_msg(all_msgs, &msg, &ofs))
+ break;
+ if (server->use_html)
+ wrap_in_html(&msg);
+ r = imap_store_msg(ctx, &msg);
+ if (r != DRV_OK)
+ break;
+ n++;
+ }
+ fprintf(stderr, "\n");
+
+ imap_close_store(ctx);
+
+ return 0;
+}
+
+#ifdef USE_CURL_FOR_IMAP_SEND
+static CURL *setup_curl(struct imap_server_conf *srvc)
+{
+ CURL *curl;
+ struct strbuf path = STRBUF_INIT;
+
+ if (curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK)
+ die("curl_global_init failed");
+
+ curl = curl_easy_init();
+
+ if (!curl)
+ die("curl_easy_init failed");
+
+ curl_easy_setopt(curl, CURLOPT_USERNAME, server.user);
+ curl_easy_setopt(curl, CURLOPT_PASSWORD, server.pass);
+
+ strbuf_addstr(&path, server.host);
+ if (!path.len || path.buf[path.len - 1] != '/')
+ strbuf_addch(&path, '/');
+ strbuf_addstr(&path, server.folder);
+
+ curl_easy_setopt(curl, CURLOPT_URL, path.buf);
+ strbuf_release(&path);
+ curl_easy_setopt(curl, CURLOPT_PORT, server.port);
+
+ if (server.auth_method) {
+ struct strbuf auth = STRBUF_INIT;
+ strbuf_addstr(&auth, "AUTH=");
+ strbuf_addstr(&auth, server.auth_method);
+ curl_easy_setopt(curl, CURLOPT_LOGIN_OPTIONS, auth.buf);
+ strbuf_release(&auth);
+ }
+
+ if (!server.use_ssl)
+ curl_easy_setopt(curl, CURLOPT_USE_SSL, (long)CURLUSESSL_TRY);
+
+ curl_easy_setopt(curl, CURLOPT_SSL_VERIFYPEER, server.ssl_verify);
+ curl_easy_setopt(curl, CURLOPT_SSL_VERIFYHOST, server.ssl_verify);
+
+ curl_easy_setopt(curl, CURLOPT_READFUNCTION, fread_buffer);
+
+ curl_easy_setopt(curl, CURLOPT_UPLOAD, 1L);
+
+ if (0 < verbosity || getenv("GIT_CURL_VERBOSE"))
+ curl_easy_setopt(curl, CURLOPT_VERBOSE, 1L);
+
+ return curl;
+}
+
+static int curl_append_msgs_to_imap(struct imap_server_conf *server,
+ struct strbuf* all_msgs, int total) {
+ int ofs = 0;
+ int n = 0;
+ struct buffer msgbuf = { STRBUF_INIT, 0 };
+ CURL *curl;
+ CURLcode res = CURLE_OK;
+
+ curl = setup_curl(server);
+ curl_easy_setopt(curl, CURLOPT_READDATA, &msgbuf);
+
+ fprintf(stderr, "sending %d message%s\n", total, (total != 1) ? "s" : "");
+ while (1) {
+ unsigned percent = n * 100 / total;
+ int prev_len;
+
+ fprintf(stderr, "%4u%% (%d/%d) done\r", percent, n, total);
+
+ prev_len = msgbuf.buf.len;
+ if (!split_msg(all_msgs, &msgbuf.buf, &ofs))
+ break;
+ if (server->use_html)
+ wrap_in_html(&msgbuf.buf);
+ lf_to_crlf(&msgbuf.buf);
+
+ curl_easy_setopt(curl, CURLOPT_INFILESIZE_LARGE,
+ (curl_off_t)(msgbuf.buf.len-prev_len));
+
+ res = curl_easy_perform(curl);
+
+ if(res != CURLE_OK) {
+ fprintf(stderr, "curl_easy_perform() failed: %s\n",
+ curl_easy_strerror(res));
+ break;
+ }
+
+ n++;
+ }
+ fprintf(stderr, "\n");
+
+ curl_easy_cleanup(curl);
+ curl_global_cleanup();
+
+ return 0;
+}
+#endif
+
+int main(int argc, char **argv)
+{
+ struct strbuf all_msgs = STRBUF_INIT;
+ int total;
int nongit_ok;
git_extract_argv0_path(argv[0]);
git_setup_gettext();
- if (argc != 1)
- usage(imap_send_usage);
-
setup_git_directory_gently(&nongit_ok);
git_imap_config();
+ argc = parse_options(argc, (const char **)argv, "", imap_send_options, imap_send_usage, 0);
+
+ if (argc)
+ usage_with_options(imap_send_usage, imap_send_options);
+
+#ifndef USE_CURL_FOR_IMAP_SEND
+ if (use_curl) {
+ warning("--use-curl not supported in this build");
+ use_curl = 0;
+ }
+#endif
+
if (!server.port)
server.port = server.use_ssl ? 993 : 143;
@@ -1391,29 +1542,14 @@ int main(int argc, char **argv)
}
/* write it to the imap server */
- ctx = imap_open_store(&server, server.folder);
- if (!ctx) {
- fprintf(stderr, "failed to open store\n");
- return 1;
- }
-
- fprintf(stderr, "sending %d message%s\n", total, (total != 1) ? "s" : "");
- while (1) {
- unsigned percent = n * 100 / total;
- fprintf(stderr, "%4u%% (%d/%d) done\r", percent, n, total);
- if (!split_msg(&all_msgs, &msg, &ofs))
- break;
- if (server.use_html)
- wrap_in_html(&msg);
- r = imap_store_msg(ctx, &msg);
- if (r != DRV_OK)
- break;
- n++;
- }
- fprintf(stderr, "\n");
+ if (server.tunnel)
+ return append_msgs_to_imap(&server, &all_msgs, total);
- imap_close_store(ctx);
+#ifdef USE_CURL_FOR_IMAP_SEND
+ if (use_curl)
+ return curl_append_msgs_to_imap(&server, &all_msgs, total);
+#endif
- return 0;
+ return append_msgs_to_imap(&server, &all_msgs, total);
}
diff --git a/line-log.c b/line-log.c
index b7864ad..a490efe 100644
--- a/line-log.c
+++ b/line-log.c
@@ -237,7 +237,7 @@ static void diff_ranges_release(struct diff_ranges *diff)
range_set_release(&diff->target);
}
-void line_log_data_init(struct line_log_data *r)
+static void line_log_data_init(struct line_log_data *r)
{
memset(r, 0, sizeof(struct line_log_data));
range_set_init(&r->ranges, 0);
diff --git a/line-log.h b/line-log.h
index a9212d8..7a5c24e 100644
--- a/line-log.h
+++ b/line-log.h
@@ -54,8 +54,6 @@ struct line_log_data {
struct diff_ranges diff;
};
-extern void line_log_data_init(struct line_log_data *r);
-
extern void line_log_init(struct rev_info *rev, const char *prefix, struct string_list *args);
extern int line_log_filter(struct rev_info *rev);
diff --git a/list-objects.c b/list-objects.c
index 2910bec..2a139b6 100644
--- a/list-objects.c
+++ b/list-objects.c
@@ -157,7 +157,7 @@ void mark_edges_uninteresting(struct rev_info *revs, show_edge_fn show_edge)
if (commit->object.flags & UNINTERESTING) {
mark_tree_uninteresting(commit->tree);
- if (revs->edge_hint && !(commit->object.flags & SHOWN)) {
+ if (revs->edge_hint_aggressive && !(commit->object.flags & SHOWN)) {
commit->object.flags |= SHOWN;
show_edge(commit);
}
@@ -165,7 +165,7 @@ void mark_edges_uninteresting(struct rev_info *revs, show_edge_fn show_edge)
}
mark_edge_parents_uninteresting(commit, revs, show_edge);
}
- if (revs->edge_hint) {
+ if (revs->edge_hint_aggressive) {
for (i = 0; i < revs->cmdline.nr; i++) {
struct object *obj = revs->cmdline.rev[i].item;
struct commit *commit = (struct commit *)obj;
diff --git a/lockfile.c b/lockfile.c
index 4f16ee7..9889277 100644
--- a/lockfile.c
+++ b/lockfile.c
@@ -128,9 +128,17 @@ static int lock_file(struct lock_file *lk, const char *path, int flags)
path);
}
- strbuf_add(&lk->filename, path, pathlen);
- if (!(flags & LOCK_NO_DEREF))
- resolve_symlink(&lk->filename);
+ if (flags & LOCK_NO_DEREF) {
+ strbuf_add_absolute_path(&lk->filename, path);
+ } else {
+ struct strbuf resolved_path = STRBUF_INIT;
+
+ strbuf_add(&resolved_path, path, pathlen);
+ resolve_symlink(&resolved_path);
+ strbuf_add_absolute_path(&lk->filename, resolved_path.buf);
+ strbuf_release(&resolved_path);
+ }
+
strbuf_addstr(&lk->filename, LOCK_SUFFIX);
lk->fd = open(lk->filename.buf, O_RDWR | O_CREAT | O_EXCL, 0666);
if (lk->fd < 0) {
diff --git a/mailmap.c b/mailmap.c
index 81890a6..9e95897 100644
--- a/mailmap.c
+++ b/mailmap.c
@@ -71,22 +71,17 @@ static void add_mapping(struct string_list *map,
char *old_name, char *old_email)
{
struct mailmap_entry *me;
- int index;
+ struct string_list_item *item;
if (old_email == NULL) {
old_email = new_email;
new_email = NULL;
}
- if ((index = string_list_find_insert_index(map, old_email, 1)) < 0) {
- /* mailmap entry exists, invert index value */
- index = -1 - index;
- me = (struct mailmap_entry *)map->items[index].util;
+ item = string_list_insert(map, old_email);
+ if (item->util) {
+ me = (struct mailmap_entry *)item->util;
} else {
- /* create mailmap entry */
- struct string_list_item *item;
-
- item = string_list_insert_at_index(map, index, old_email);
me = xcalloc(1, sizeof(struct mailmap_entry));
me->namemap.strdup_strings = 1;
me->namemap.cmp = namemap_cmp;
@@ -94,8 +89,8 @@ static void add_mapping(struct string_list *map,
}
if (old_name == NULL) {
- debug_mm("mailmap: adding (simple) entry for %s at index %d\n",
- old_email, index);
+ debug_mm("mailmap: adding (simple) entry for '%s'\n", old_email);
+
/* Replace current name and new email for simple entry */
if (new_name) {
free(me->name);
@@ -107,8 +102,7 @@ static void add_mapping(struct string_list *map,
}
} else {
struct mailmap_info *mi = xcalloc(1, sizeof(struct mailmap_info));
- debug_mm("mailmap: adding (complex) entry for %s at index %d\n",
- old_email, index);
+ debug_mm("mailmap: adding (complex) entry for '%s'\n", old_email);
if (new_name)
mi->name = xstrdup(new_name);
if (new_email)
diff --git a/merge-recursive.c b/merge-recursive.c
index fdb7d0f..771f5e2 100644
--- a/merge-recursive.c
+++ b/merge-recursive.c
@@ -275,23 +275,20 @@ struct tree *write_tree_from_memory(struct merge_options *o)
}
static int save_files_dirs(const unsigned char *sha1,
- const char *base, int baselen, const char *path,
+ struct strbuf *base, const char *path,
unsigned int mode, int stage, void *context)
{
- int len = strlen(path);
- char *newpath = xmalloc(baselen + len + 1);
+ int baselen = base->len;
struct merge_options *o = context;
- memcpy(newpath, base, baselen);
- memcpy(newpath + baselen, path, len);
- newpath[baselen + len] = '\0';
+ strbuf_addstr(base, path);
if (S_ISDIR(mode))
- string_list_insert(&o->current_directory_set, newpath);
+ string_list_insert(&o->current_directory_set, base->buf);
else
- string_list_insert(&o->current_file_set, newpath);
- free(newpath);
+ string_list_insert(&o->current_file_set, base->buf);
+ strbuf_setlen(base, baselen);
return (S_ISDIR(mode) ? READ_TREE_RECURSIVE : 0);
}
@@ -1904,7 +1901,7 @@ int merge_recursive(struct merge_options *o,
}
if (!ca) {
- ca = get_merge_bases(h1, h2, 1);
+ ca = get_merge_bases(h1, h2);
ca = reverse_commit_list(ca);
}
diff --git a/notes-merge.c b/notes-merge.c
index 7eb9d7a..109ff4e 100644
--- a/notes-merge.c
+++ b/notes-merge.c
@@ -594,7 +594,7 @@ int notes_merge(struct notes_merge_options *o,
assert(local && remote);
/* Find merge bases */
- bases = get_merge_bases(local, remote, 1);
+ bases = get_merge_bases(local, remote);
if (!bases) {
base_sha1 = null_sha1;
base_tree_sha1 = EMPTY_TREE_SHA1_BIN;
diff --git a/notes-utils.c b/notes-utils.c
index b64dc1b..ccbf073 100644
--- a/notes-utils.c
+++ b/notes-utils.c
@@ -44,8 +44,7 @@ void commit_notes(struct notes_tree *t, const char *msg)
/* Prepare commit message and reflog message */
strbuf_addstr(&buf, msg);
- if (buf.buf[buf.len - 1] != '\n')
- strbuf_addch(&buf, '\n'); /* Make sure msg ends with newline */
+ strbuf_complete_line(&buf);
create_notes_commit(t, NULL, buf.buf, buf.len, commit_sha1);
strbuf_insert(&buf, 0, "notes: ", 7); /* commit message starts at index 7 */
diff --git a/notes.c b/notes.c
index 62bc6e1..2be4d7f 100644
--- a/notes.c
+++ b/notes.c
@@ -902,7 +902,7 @@ int combine_notes_cat_sort_uniq(unsigned char *cur_sha1,
if (string_list_add_note_lines(&sort_uniq_list, new_sha1))
goto out;
string_list_remove_empty_items(&sort_uniq_list, 0);
- sort_string_list(&sort_uniq_list);
+ string_list_sort(&sort_uniq_list);
string_list_remove_duplicates(&sort_uniq_list, 0);
/* create a new blob object from sort_uniq_list */
@@ -1006,7 +1006,7 @@ void init_notes(struct notes_tree *t, const char *notes_ref,
t->root = (struct int_node *) xcalloc(1, sizeof(struct int_node));
t->first_non_note = NULL;
t->prev_non_note = NULL;
- t->ref = notes_ref ? xstrdup(notes_ref) : NULL;
+ t->ref = xstrdup_or_null(notes_ref);
t->combine_notes = combine_notes;
t->initialized = 1;
t->dirty = 0;
diff --git a/pack-bitmap.c b/pack-bitmap.c
index 6a81841..365f9d9 100644
--- a/pack-bitmap.c
+++ b/pack-bitmap.c
@@ -60,7 +60,7 @@ static struct bitmap_index {
struct ewah_bitmap *blobs;
struct ewah_bitmap *tags;
- /* Map from SHA1 -> `stored_bitmap` for all the bitmapped comits */
+ /* Map from SHA1 -> `stored_bitmap` for all the bitmapped commits */
khash_sha1 *bitmaps;
/* Number of bitmapped commits */
@@ -252,6 +252,20 @@ static int load_bitmap_entries_v1(struct bitmap_index *index)
return 0;
}
+static char *pack_bitmap_filename(struct packed_git *p)
+{
+ char *idx_name;
+ int len;
+
+ len = strlen(p->pack_name) - strlen(".pack");
+ idx_name = xmalloc(len + strlen(".bitmap") + 1);
+
+ memcpy(idx_name, p->pack_name, len);
+ memcpy(idx_name + len, ".bitmap", strlen(".bitmap") + 1);
+
+ return idx_name;
+}
+
static int open_pack_bitmap_1(struct packed_git *packfile)
{
int fd;
@@ -322,20 +336,6 @@ failed:
return -1;
}
-char *pack_bitmap_filename(struct packed_git *p)
-{
- char *idx_name;
- int len;
-
- len = strlen(p->pack_name) - strlen(".pack");
- idx_name = xmalloc(len + strlen(".bitmap") + 1);
-
- memcpy(idx_name, p->pack_name, len);
- memcpy(idx_name + len, ".bitmap", strlen(".bitmap") + 1);
-
- return idx_name;
-}
-
static int open_pack_bitmap(void)
{
struct packed_git *p;
diff --git a/pack-bitmap.h b/pack-bitmap.h
index 487600b..0adcef7 100644
--- a/pack-bitmap.h
+++ b/pack-bitmap.h
@@ -38,7 +38,6 @@ int prepare_bitmap_git(void);
void count_bitmap_commit_list(uint32_t *commits, uint32_t *trees, uint32_t *blobs, uint32_t *tags);
void traverse_bitmap_commit_list(show_reachable_fn show_reachable);
void test_bitmap_walk(struct rev_info *revs);
-char *pack_bitmap_filename(struct packed_git *p);
int prepare_bitmap_walk(struct rev_info *revs);
int reuse_partial_packfile_from_bitmap(struct packed_git **packfile, uint32_t *entries, off_t *up_to);
int rebuild_existing_bitmaps(struct packing_data *mapping, khash_sha1 *reused_bitmaps, int show_progress);
diff --git a/pager.c b/pager.c
index f6e8c33..98b2682 100644
--- a/pager.c
+++ b/pager.c
@@ -133,12 +133,12 @@ int term_columns(void)
/*
* How many columns do we need to show this number in decimal?
*/
-int decimal_width(int number)
+int decimal_width(uintmax_t number)
{
- int i, width;
+ int width;
- for (width = 1, i = 10; i <= number; width++)
- i *= 10;
+ for (width = 1; number >= 10; width++)
+ number /= 10;
return width;
}
diff --git a/path.c b/path.c
index f68df0c..e608993 100644
--- a/path.c
+++ b/path.c
@@ -823,3 +823,36 @@ int daemon_avoid_alias(const char *p)
}
}
}
+
+static int only_spaces_and_periods(const char *path, size_t len, size_t skip)
+{
+ if (len < skip)
+ return 0;
+ len -= skip;
+ path += skip;
+ while (len-- > 0) {
+ char c = *(path++);
+ if (c != ' ' && c != '.')
+ return 0;
+ }
+ return 1;
+}
+
+int is_ntfs_dotgit(const char *name)
+{
+ int len;
+
+ for (len = 0; ; len++)
+ if (!name[len] || name[len] == '\\' || is_dir_sep(name[len])) {
+ if (only_spaces_and_periods(name, len, 4) &&
+ !strncasecmp(name, ".git", 4))
+ return 1;
+ if (only_spaces_and_periods(name, len, 5) &&
+ !strncasecmp(name, "git~1", 5))
+ return 1;
+ if (name[len] != '\\')
+ return 0;
+ name += len + 1;
+ len = -1;
+ }
+}
diff --git a/perl/Git/SVN.pm b/perl/Git/SVN.pm
index d9a52a5..8e4af71 100644
--- a/perl/Git/SVN.pm
+++ b/perl/Git/SVN.pm
@@ -2365,7 +2365,7 @@ sub _new {
# Older repos imported by us used $GIT_DIR/svn/foo instead of
# $GIT_DIR/svn/refs/remotes/foo when tracking refs/remotes/foo
- if ($ref_id =~ m{^refs/remotes/(.*)}) {
+ if ($ref_id =~ m{^refs/remotes/(.+)}) {
my $old_dir = "$ENV{GIT_DIR}/svn/$1";
if (-d $old_dir && ! -d $dir) {
$dir = $old_dir;
diff --git a/perl/Git/SVN/Editor.pm b/perl/Git/SVN/Editor.pm
index 34e8af9..4088f13 100644
--- a/perl/Git/SVN/Editor.pm
+++ b/perl/Git/SVN/Editor.pm
@@ -288,6 +288,40 @@ sub apply_autoprops {
}
}
+sub check_attr {
+ my ($attr,$path) = @_;
+ my $val = command_oneline("check-attr", $attr, "--", $path);
+ if ($val) { $val =~ s/^[^:]*:\s*[^:]*:\s*(.*)\s*$/$1/; }
+ return $val;
+}
+
+sub apply_manualprops {
+ my ($self, $file, $fbat) = @_;
+ my $pending_properties = check_attr( "svn-properties", $file );
+ if ($pending_properties eq "") { return; }
+ # Parse the list of properties to set.
+ my @props = split(/;/, $pending_properties);
+ # TODO: get existing properties to compare to
+ # - this fails for add so currently not done
+ # my $existing_props = ::get_svnprops($file);
+ my $existing_props = {};
+ # TODO: caching svn properties or storing them in .gitattributes
+ # would make that faster
+ foreach my $prop (@props) {
+ # Parse 'name=value' syntax and set the property.
+ if ($prop =~ /([^=]+)=(.*)/) {
+ my ($n,$v) = ($1,$2);
+ for ($n, $v) {
+ s/^\s+//; s/\s+$//;
+ }
+ my $existing = $existing_props->{$n};
+ if (!defined($existing) || $existing ne $v) {
+ $self->change_file_prop($fbat, $n, $v);
+ }
+ }
+ }
+}
+
sub A {
my ($self, $m, $deletions) = @_;
my ($dir, $file) = split_path($m->{file_b});
@@ -296,6 +330,7 @@ sub A {
undef, -1);
print "\tA\t$m->{file_b}\n" unless $::_q;
$self->apply_autoprops($file, $fbat);
+ $self->apply_manualprops($m->{file_b}, $fbat);
$self->chg_file($fbat, $m);
$self->close_file($fbat,undef,$self->{pool});
}
@@ -311,6 +346,7 @@ sub C {
my $fbat = $self->add_file($self->repo_path($m->{file_b}), $pbat,
$upa, $self->{r});
print "\tC\t$m->{file_a} => $m->{file_b}\n" unless $::_q;
+ $self->apply_manualprops($m->{file_b}, $fbat);
$self->chg_file($fbat, $m);
$self->close_file($fbat,undef,$self->{pool});
}
@@ -333,6 +369,7 @@ sub R {
$upa, $self->{r});
print "\tR\t$m->{file_a} => $m->{file_b}\n" unless $::_q;
$self->apply_autoprops($file, $fbat);
+ $self->apply_manualprops($m->{file_b}, $fbat);
$self->chg_file($fbat, $m);
$self->close_file($fbat,undef,$self->{pool});
@@ -348,6 +385,7 @@ sub M {
my $fbat = $self->open_file($self->repo_path($m->{file_b}),
$pbat,$self->{r},$self->{pool});
print "\t$m->{chg}\t$m->{file_b}\n" unless $::_q;
+ $self->apply_manualprops($m->{file_b}, $fbat);
$self->chg_file($fbat, $m);
$self->close_file($fbat,undef,$self->{pool});
}
diff --git a/pkt-line.c b/pkt-line.c
index 8bc89b1..187a229 100644
--- a/pkt-line.c
+++ b/pkt-line.c
@@ -64,44 +64,45 @@ void packet_buf_flush(struct strbuf *buf)
}
#define hex(a) (hexchar[(a) & 15])
-static char buffer[1000];
-static unsigned format_packet(const char *fmt, va_list args)
+static void format_packet(struct strbuf *out, const char *fmt, va_list args)
{
static char hexchar[] = "0123456789abcdef";
- unsigned n;
+ size_t orig_len, n;
- n = vsnprintf(buffer + 4, sizeof(buffer) - 4, fmt, args);
- if (n >= sizeof(buffer)-4)
+ orig_len = out->len;
+ strbuf_addstr(out, "0000");
+ strbuf_vaddf(out, fmt, args);
+ n = out->len - orig_len;
+
+ if (n > LARGE_PACKET_MAX)
die("protocol error: impossibly long line");
- n += 4;
- buffer[0] = hex(n >> 12);
- buffer[1] = hex(n >> 8);
- buffer[2] = hex(n >> 4);
- buffer[3] = hex(n);
- packet_trace(buffer+4, n-4, 1);
- return n;
+
+ out->buf[orig_len + 0] = hex(n >> 12);
+ out->buf[orig_len + 1] = hex(n >> 8);
+ out->buf[orig_len + 2] = hex(n >> 4);
+ out->buf[orig_len + 3] = hex(n);
+ packet_trace(out->buf + orig_len + 4, n - 4, 1);
}
void packet_write(int fd, const char *fmt, ...)
{
+ static struct strbuf buf = STRBUF_INIT;
va_list args;
- unsigned n;
+ strbuf_reset(&buf);
va_start(args, fmt);
- n = format_packet(fmt, args);
+ format_packet(&buf, fmt, args);
va_end(args);
- write_or_die(fd, buffer, n);
+ write_or_die(fd, buf.buf, buf.len);
}
void packet_buf_write(struct strbuf *buf, const char *fmt, ...)
{
va_list args;
- unsigned n;
va_start(args, fmt);
- n = format_packet(fmt, args);
+ format_packet(buf, fmt, args);
va_end(args);
- strbuf_add(buf, buffer, n);
}
static int get_packet_data(int fd, char **src_buf, size_t *src_size,
diff --git a/po/ca.po b/po/ca.po
index 1fea047..a649508 100644
--- a/po/ca.po
+++ b/po/ca.po
@@ -7,8 +7,8 @@ msgid ""
msgstr ""
"Project-Id-Version: Git\n"
"Report-Msgid-Bugs-To: Git Mailing List <git@vger.kernel.org>\n"
-"POT-Creation-Date: 2014-11-20 09:42+0800\n"
-"PO-Revision-Date: 2014-11-20 16:10+0800\n"
+"POT-Creation-Date: 2015-01-18 11:24+0800\n"
+"PO-Revision-Date: 2015-01-30 15:01-0700\n"
"Last-Translator: Alex Henrie <alexhenrie24@gmail.com>\n"
"Language-Team: Catalan\n"
"Language: ca\n"
@@ -16,12 +16,12 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-"X-Generator: Poedit 1.6.10\n"
+"X-Generator: Poedit 1.7.3\n"
#: advice.c:55
#, c-format
msgid "hint: %.*s\n"
-msgstr "indirecta: %.*s\n"
+msgstr "pista: %.*s\n"
#: advice.c:88
msgid ""
@@ -34,7 +34,7 @@ msgstr ""
#: archive.c:11
msgid "git archive [options] <tree-ish> [<path>...]"
-msgstr "git archive [opcions] <arbre> [<ruta>...]"
+msgstr "git archive [opcions] <arbre> [<camí>...]"
#: archive.c:12
msgid "git archive --list"
@@ -44,140 +44,144 @@ msgstr "git archive --list"
msgid ""
"git archive --remote <repo> [--exec <cmd>] [options] <tree-ish> [<path>...]"
msgstr ""
-"git archive --remote <dipòsit> [--exec <ordre>] [opcions] <arbre> [<ruta>...]"
+"git archive --remote <dipòsit> [--exec <ordre>] [opcions] <arbre> [<camí>...]"
#: archive.c:14
msgid "git archive --remote <repo> [--exec <cmd>] --list"
msgstr "git archive --remote <dipòsit> [--exec <ordre>] --list"
-#: archive.c:334 builtin/add.c:137 builtin/add.c:427 builtin/rm.c:328
+#: archive.c:342 builtin/add.c:137 builtin/add.c:427 builtin/rm.c:328
#, c-format
msgid "pathspec '%s' did not match any files"
-msgstr "L'especificació de ruta '%s' no ha concordat amb cap fitxer"
+msgstr "L'especificació de camí '%s' no ha coincidit amb cap fitxer"
-#: archive.c:419
+#: archive.c:427
msgid "fmt"
msgstr "format"
-#: archive.c:419
+#: archive.c:427
msgid "archive format"
msgstr "format d'arxiu"
-#: archive.c:420 builtin/log.c:1204
+#: archive.c:428 builtin/log.c:1204
msgid "prefix"
msgstr "prefix"
-#: archive.c:421
+#: archive.c:429
msgid "prepend prefix to each pathname in the archive"
-msgstr "anteposa el prefix a cada nom de ruta en l'arxiu"
+msgstr "anteposa el prefix a cada nom de camí en l'arxiu"
-#: archive.c:422 builtin/archive.c:88 builtin/blame.c:2517
+#: archive.c:430 builtin/archive.c:88 builtin/blame.c:2517
#: builtin/blame.c:2518 builtin/config.c:57 builtin/fast-export.c:986
#: builtin/fast-export.c:988 builtin/grep.c:712 builtin/hash-object.c:101
-#: builtin/ls-files.c:489 builtin/ls-files.c:492 builtin/notes.c:411
-#: builtin/notes.c:568 builtin/read-tree.c:109 parse-options.h:151
+#: builtin/ls-files.c:489 builtin/ls-files.c:492 builtin/notes.c:394
+#: builtin/notes.c:557 builtin/read-tree.c:109 parse-options.h:151
msgid "file"
msgstr "fitxer"
-#: archive.c:423 builtin/archive.c:89
+#: archive.c:431 builtin/archive.c:89
msgid "write the archive to this file"
msgstr "escriu l'arxiu a aquest fitxer"
-#: archive.c:425
+#: archive.c:433
msgid "read .gitattributes in working directory"
msgstr "llegeix .gitattributes en el directori de treball"
-#: archive.c:426
+#: archive.c:434
msgid "report archived files on stderr"
msgstr "informa de fitxers arxivats en stderr"
-#: archive.c:427
+#: archive.c:435
msgid "store only"
msgstr "només emmagatzemar"
-#: archive.c:428
+#: archive.c:436
msgid "compress faster"
msgstr "comprimeix més ràpid"
-#: archive.c:436
+#: archive.c:444
msgid "compress better"
msgstr "comprimeix millor"
-#: archive.c:439
+#: archive.c:447
msgid "list supported archive formats"
-msgstr "allista els formats d'arxiu suportats"
+msgstr "allista els formats d'arxiu admesos"
-#: archive.c:441 builtin/archive.c:90 builtin/clone.c:85
+#: archive.c:449 builtin/archive.c:90 builtin/clone.c:86
msgid "repo"
msgstr "dipòsit"
-#: archive.c:442 builtin/archive.c:91
+#: archive.c:450 builtin/archive.c:91
msgid "retrieve the archive from remote repository <repo>"
msgstr "recupera l'arxiu del dipòsit remot <dipòsit>"
-#: archive.c:443 builtin/archive.c:92 builtin/notes.c:490
+#: archive.c:451 builtin/archive.c:92 builtin/notes.c:478
msgid "command"
msgstr "ordre"
-#: archive.c:444 builtin/archive.c:93
+#: archive.c:452 builtin/archive.c:93
msgid "path to the remote git-upload-archive command"
-msgstr "ruta a l'ordre git-upload-archive remot"
+msgstr "camí a l'ordre git-upload-archive remot"
#: attr.c:258
msgid ""
"Negative patterns are ignored in git attributes\n"
"Use '\\!' for literal leading exclamation."
msgstr ""
-"Els patrons negatius s'ignoren en els atributes de git\n"
+"Els patrons negatius s'ignoren en els atributs de git\n"
"Useu '\\!' per exclamació capdavantera literal."
#: branch.c:60
#, c-format
msgid "Not setting branch %s as its own upstream."
-msgstr "No establint la rama %s com a la seva pròpia font."
+msgstr "No establint la branca %s com a la seva pròpia font."
#: branch.c:83
#, c-format
msgid "Branch %s set up to track remote branch %s from %s by rebasing."
msgstr ""
-"La rama %s està configurada per a seguir la rama remota %s de %s per rebasar."
+"La branca %s està configurada per a seguir la branca remota %s de %s per "
+"rebasar."
#: branch.c:84
#, c-format
msgid "Branch %s set up to track remote branch %s from %s."
-msgstr "La rama %s està configurada per a seguir la rama remota %s de %s."
+msgstr "La branca %s està configurada per a seguir la branca remota %s de %s."
#: branch.c:88
#, c-format
msgid "Branch %s set up to track local branch %s by rebasing."
-msgstr "La rama %s està configurada per a seguir la rama local %s per rebasar."
+msgstr ""
+"La branca %s està configurada per a seguir la branca local %s per rebasar."
#: branch.c:89
#, c-format
msgid "Branch %s set up to track local branch %s."
-msgstr "La rama %s està configurada per a seguir la rama local %s."
+msgstr "La branca %s està configurada per a seguir la branca local %s."
#: branch.c:94
#, c-format
msgid "Branch %s set up to track remote ref %s by rebasing."
msgstr ""
-"La rama %s està configurada per a seguir la referència remota %s per rebasar."
+"La branca %s està configurada per a seguir la referència remota %s per "
+"rebasar."
#: branch.c:95
#, c-format
msgid "Branch %s set up to track remote ref %s."
-msgstr "La rama %s està configurada per a seguir la referència remota %s."
+msgstr "La branca %s està configurada per a seguir la referència remota %s."
#: branch.c:99
#, c-format
msgid "Branch %s set up to track local ref %s by rebasing."
msgstr ""
-"La rama %s està configurada per a seguir la referència local %s per rebasar."
+"La branca %s està configurada per a seguir la referència local %s per "
+"rebasar."
#: branch.c:100
#, c-format
msgid "Branch %s set up to track local ref %s."
-msgstr "La rama %s està configurada per a seguir la referència local %s."
+msgstr "La branca %s està configurada per a seguir la referència local %s."
#: branch.c:133
#, c-format
@@ -187,28 +191,28 @@ msgstr "No seguint: informació ambigua per a la referència %s"
#: branch.c:162
#, c-format
msgid "'%s' is not a valid branch name."
-msgstr "'%s' no és un nom de rama vàlid."
+msgstr "'%s' no és un nom de branca vàlid."
#: branch.c:167
#, c-format
msgid "A branch named '%s' already exists."
-msgstr "Una rama amb nom '%s' ja existeix."
+msgstr "Una branca amb nom '%s' ja existeix."
#: branch.c:175
msgid "Cannot force update the current branch."
-msgstr "No es pot actualitzar la rama actual a la força."
+msgstr "No es pot actualitzar la branca actual a la força."
#: branch.c:195
#, c-format
msgid "Cannot setup tracking information; starting point '%s' is not a branch."
msgstr ""
"No es pot configurar la informació de seguiment; el punt inicial '%s' no és "
-"una rama."
+"una branca."
#: branch.c:197
#, c-format
msgid "the requested upstream branch '%s' does not exist"
-msgstr "la rama font demanada '%s' no existeix"
+msgstr "la branca font demanada '%s' no existeix"
#: branch.c:199
msgid ""
@@ -222,14 +226,14 @@ msgid ""
"\"git push -u\" to set the upstream config as you push."
msgstr ""
"\n"
-"Si planeu basar el teu treball en una rama font que ja\n"
-"existeix al remot, pot que necessiteu executar\n"
-"\"git fetch\" per a obtenir-la.\n"
+"Si teniu pensat basar el vostre treball en una branca\n"
+"font que ja existeix al remot, pot ser que necessiteu\n"
+"executar \"git fetch\" per a obtenir-la.\n"
"\n"
-"Si planeu pujar una rama local nova que seguirà la seva\n"
-"contrapart remota, pot que voleu usar\n"
-"\"git push -u\" per establir la configuració font mentre\n"
-"pugeu."
+"Si teniu pensat pujar una branca local nova que seguirà\n"
+"la seva contrapart remota, pot ser que vulgueu usar\n"
+"\"git push -u\" per a establir la configuració font\n"
+"mentre pugeu."
#: branch.c:243
#, c-format
@@ -249,14 +253,14 @@ msgstr "No és un punt de ramificació vàlid: '%s'."
#: bundle.c:34
#, c-format
msgid "'%s' does not look like a v2 bundle file"
-msgstr "'%s' no sembla a un fitxer d'embolic v2"
+msgstr "'%s' no sembla un fitxer de farcell v2"
#: bundle.c:61
#, c-format
msgid "unrecognized header: %s%s (%d)"
msgstr "capçalera no reconeguda: %s%s (%d)"
-#: bundle.c:87 builtin/commit.c:788
+#: bundle.c:87 builtin/commit.c:770
#, c-format
msgid "could not open '%s'"
msgstr "no s'ha pogut obrir '%s'"
@@ -265,9 +269,9 @@ msgstr "no s'ha pogut obrir '%s'"
msgid "Repository lacks these prerequisite commits:"
msgstr "Al dipòsit li manquen aquestes comissions prerequisits:"
-#: bundle.c:163 sequencer.c:641 sequencer.c:1096 builtin/blame.c:2706
-#: builtin/branch.c:652 builtin/commit.c:1085 builtin/log.c:330
-#: builtin/log.c:823 builtin/log.c:1432 builtin/log.c:1669 builtin/merge.c:357
+#: bundle.c:163 sequencer.c:645 sequencer.c:1100 builtin/blame.c:2706
+#: builtin/branch.c:652 builtin/commit.c:1049 builtin/log.c:330
+#: builtin/log.c:823 builtin/log.c:1432 builtin/log.c:1669 builtin/merge.c:358
#: builtin/shortlog.c:158
msgid "revision walk setup failed"
msgstr "la configuració del passeig per revisions ha fallat"
@@ -276,19 +280,19 @@ msgstr "la configuració del passeig per revisions ha fallat"
#, c-format
msgid "The bundle contains this ref:"
msgid_plural "The bundle contains these %d refs:"
-msgstr[0] "L'embolic conté aquesta referència:"
-msgstr[1] "L'embolic conté aquestes %d referències:"
+msgstr[0] "El farcell conté aquesta referència:"
+msgstr[1] "El farcell conté aquestes %d referències:"
#: bundle.c:192
msgid "The bundle records a complete history."
-msgstr "L'embolic registra una història completa."
+msgstr "El farcell registra una història completa."
#: bundle.c:194
#, c-format
msgid "The bundle requires this ref:"
msgid_plural "The bundle requires these %d refs:"
-msgstr[0] "L'embolic requereix aquesta referència:"
-msgstr[1] "L'embolic requereix aquestes %d referències:"
+msgstr[0] "El farcell requereix aquesta referència:"
+msgstr[1] "El farcell requereix aquestes %d referències:"
#: bundle.c:251
msgid "Could not spawn pack-objects"
@@ -314,7 +318,7 @@ msgstr "paràmetre no reconegut: %s"
#: bundle.c:444
msgid "Refusing to create empty bundle."
-msgstr "Refusant crear un embolic buit."
+msgstr "Refusant crear un farcell buit."
#: bundle.c:454
#, c-format
@@ -325,10 +329,10 @@ msgstr "no es pot crear '%s'"
msgid "index-pack died"
msgstr "L'index-pack s'ha mort"
-#: color.c:157
+#: color.c:259
#, c-format
msgid "invalid color value: %.*s"
-msgstr "valor de color invàlid: %.*s"
+msgstr "valor de color no vàlid: %.*s"
#: commit.c:40
#, c-format
@@ -372,28 +376,27 @@ msgstr "nivell de compressió de zlib dolent %d"
#: config.c:885
#, c-format
msgid "invalid mode for object creation: %s"
-msgstr "mode de creació d'objecte invàlid: %s"
+msgstr "mode de creació d'objecte no vàlid: %s"
-#: config.c:1201
+#: config.c:1211
msgid "unable to parse command-line config"
-msgstr "incapaç de analitzar la configuració de la línia d'ordres"
+msgstr "no s'ha pogut analitzar la configuració de la línia d'ordres"
-#: config.c:1262
+#: config.c:1272
msgid "unknown error occured while reading the configuration files"
-msgstr ""
-"s'ha ocorregut un error desconegut en llegir els fitxers de configuració"
+msgstr "ha ocorregut un error desconegut en llegir els fitxers de configuració"
-#: config.c:1586
+#: config.c:1596
#, c-format
msgid "unable to parse '%s' from command-line config"
-msgstr "incapaç d'analitzar '%s' de la configuració de la línia d'ordres"
+msgstr "no s'ha pogut analitzar '%s' de la configuració de la línia d'ordres"
-#: config.c:1588
+#: config.c:1598
#, c-format
msgid "bad config variable '%s' in file '%s' at line %d"
-msgstr "variable de configuració dolent '%s' en el fitxer '%s' a la línia %d"
+msgstr "variable de configuració dolenta '%s' en el fitxer '%s' a la línia %d"
-#: config.c:1647
+#: config.c:1657
#, c-format
msgid "%s has multiple values"
msgstr "%s té múltiples valors"
@@ -470,8 +473,8 @@ msgstr[1] "%lu anys"
#, c-format
msgid "%s, %lu month ago"
msgid_plural "%s, %lu months ago"
-msgstr[0] "%s, fa %lu mes"
-msgstr[1] "%s, fa %lu mesos"
+msgstr[0] "fa %s i %lu mes"
+msgstr[1] "fa %s i %lu mesos"
#: date.c:154 date.c:159
#, c-format
@@ -487,7 +490,7 @@ msgstr "s'ha fallat en llegir el fitxer d'ordres '%s'"
#: diffcore-rename.c:516
msgid "Performing inexact rename detection"
-msgstr "Realitzant detecció inexacte de canvis de nom"
+msgstr "Realitzant detecció inexacta de canvis de nom"
#: diff.c:114
#, c-format
@@ -503,7 +506,7 @@ msgstr " Paràmetre de dirstat desconegut '%s'\n"
#, c-format
msgid "Unknown value for 'diff.submodule' config variable: '%s'"
msgstr ""
-"Valor desconegut del variable de configuració de 'diff.submodule': '%s'"
+"Valor desconegut de la variable de configuració de 'diff.submodule': '%s'"
#: diff.c:266
#, c-format
@@ -511,7 +514,7 @@ msgid ""
"Found errors in 'diff.dirstat' config variable:\n"
"%s"
msgstr ""
-"Errors trobat en el variable de configuració 'diff.dirstat':\n"
+"Errors trobats en la variable de configuració 'diff.dirstat':\n"
"%s"
#: diff.c:2957
@@ -521,7 +524,7 @@ msgstr "El diff external s'ha mort, aturant a %s"
#: diff.c:3352
msgid "--follow requires exactly one pathspec"
-msgstr "--follow requereix exactament una especificació de ruta"
+msgstr "--follow requereix exactament una especificació de camí"
#: diff.c:3515
#, c-format
@@ -562,7 +565,7 @@ msgstr "s'ha fallat en escriure la firma separada a '%s': %s"
#: grep.c:1718
#, c-format
msgid "'%s': unable to read %s"
-msgstr "'%s': incapaç de llegir %s"
+msgstr "'%s': no s'ha pogut llegir %s"
#: grep.c:1735
#, c-format
@@ -581,11 +584,11 @@ msgstr "ordres de git disponibles en '%s'"
#: help.c:214
msgid "git commands available from elsewhere on your $PATH"
-msgstr "ordres de git disponibles d'altres llocs en la vostra $PATH"
+msgstr "ordres de git disponibles d'altres llocs en el vostre $PATH"
#: help.c:230
msgid "The most commonly used git commands are:"
-msgstr "Els ordres de git més freqüentment usats són:"
+msgstr "Les ordres de git més freqüentment usades són:"
#: help.c:289
#, c-format
@@ -593,8 +596,8 @@ msgid ""
"'%s' appears to be a git command, but we were not\n"
"able to execute it. Maybe git-%s is broken?"
msgstr ""
-"'%s' sembla un ordre git, però no hem pogut\n"
-"executar-lo. Pot ser que git-%s està estropejat?"
+"'%s' sembla una ordre git, però no hem pogut\n"
+"executar-la. Pot ser que git-%s estigui estropejat?"
#: help.c:346
msgid "Uh oh. Your system reports no Git commands at all."
@@ -606,8 +609,8 @@ msgid ""
"WARNING: You called a Git command named '%s', which does not exist.\n"
"Continuing under the assumption that you meant '%s'"
msgstr ""
-"AVÍS: Heu invocat un ordre de Git amb nom '%s', el qual no existeix.\n"
-"Continuant baix l'assumpció que volíeu dir '%s'"
+"AVÍS: Heu invocat una ordre de Git amb nom '%s', la qual no existeix.\n"
+"Continuant sota l'assumpció que volíeu dir '%s'"
#: help.c:373
#, c-format
@@ -617,7 +620,7 @@ msgstr "en %0.1f segons automàticament..."
#: help.c:380
#, c-format
msgid "git: '%s' is not a git command. See 'git --help'."
-msgstr "git: '%s' no és un ordre de git. Veu 'git --help'."
+msgstr "git: '%s' no és una ordre de git. Vegeu 'git --help'."
#: help.c:384 help.c:444
msgid ""
@@ -638,11 +641,11 @@ msgstr[1] ""
msgid "%s: %s - %s"
msgstr "%s: %s - %s"
-#: lockfile.c:275
+#: lockfile.c:283
msgid "BUG: reopen a lockfile that is still open"
msgstr "BUG: reobrir un fitxer de bloqueig que encara està obert"
-#: lockfile.c:277
+#: lockfile.c:285
msgid "BUG: reopen a lockfile that has been committed"
msgstr "BUG: reobrir un fitxer de bloqueig que s'ha comès"
@@ -650,10 +653,10 @@ msgstr "BUG: reobrir un fitxer de bloqueig que s'ha comès"
msgid "failed to read the cache"
msgstr "s'ha fallat en llegir la memòria cau"
-#: merge.c:94 builtin/checkout.c:356 builtin/checkout.c:562
-#: builtin/clone.c:659
+#: merge.c:94 builtin/checkout.c:374 builtin/checkout.c:580
+#: builtin/clone.c:662
msgid "unable to write new index file"
-msgstr "incapaç d'escriure un fitxer d'índex nou"
+msgstr "no s'ha pogut escriure un fitxer d'índex nou"
#: merge-recursive.c:189
#, c-format
@@ -663,70 +666,70 @@ msgstr "(comissió dolenta)\n"
#: merge-recursive.c:209
#, c-format
msgid "addinfo_cache failed for path '%s'"
-msgstr "addinfo_cache ha fallat per a la ruta '%s'"
+msgstr "addinfo_cache ha fallat per al camí '%s'"
#: merge-recursive.c:270
msgid "error building trees"
msgstr "error en construir arbres"
-#: merge-recursive.c:691
+#: merge-recursive.c:688
#, c-format
msgid "failed to create path '%s'%s"
-msgstr "s'ha fallat en crear la ruta '%s' %s"
+msgstr "s'ha fallat en crear el camí '%s' %s"
-#: merge-recursive.c:702
+#: merge-recursive.c:699
#, c-format
msgid "Removing %s to make room for subdirectory\n"
-msgstr "Traient %s per a fer espai per al subdirectori\n"
+msgstr "Eliminant %s per a fer espai per al subdirectori\n"
-#: merge-recursive.c:716 merge-recursive.c:737
+#: merge-recursive.c:713 merge-recursive.c:734
msgid ": perhaps a D/F conflict?"
msgstr ": potser un conflicte D/F?"
-#: merge-recursive.c:727
+#: merge-recursive.c:724
#, c-format
msgid "refusing to lose untracked file at '%s'"
msgstr "refusant perdre el fitxer no seguit a '%s'"
-#: merge-recursive.c:767
+#: merge-recursive.c:764
#, c-format
msgid "cannot read object %s '%s'"
msgstr "no es pot llegir l'objecte %s '%s'"
-#: merge-recursive.c:769
+#: merge-recursive.c:766
#, c-format
msgid "blob expected for %s '%s'"
msgstr "blob esperat per a %s '%s'"
-#: merge-recursive.c:792 builtin/clone.c:318
+#: merge-recursive.c:789 builtin/clone.c:321
#, c-format
msgid "failed to open '%s'"
msgstr "s'ha fallat en obrir '%s'"
-#: merge-recursive.c:800
+#: merge-recursive.c:797
#, c-format
msgid "failed to symlink '%s'"
msgstr "s'ha fallat en fer l'enllaç simbòlic '%s'"
-#: merge-recursive.c:803
+#: merge-recursive.c:800
#, c-format
msgid "do not know what to do with %06o %s '%s'"
msgstr "no es sap què fer amb %06o %s '%s'"
-#: merge-recursive.c:941
+#: merge-recursive.c:938
msgid "Failed to execute internal merge"
msgstr "S'ha fallat en executar la fusió interna"
-#: merge-recursive.c:945
+#: merge-recursive.c:942
#, c-format
msgid "Unable to add %s to database"
-msgstr "Incapaç d'afegir %s a la base de dades"
+msgstr "no s'ha pogut afegir %s a la base de dades"
-#: merge-recursive.c:961
+#: merge-recursive.c:958
msgid "unsupported object type in the tree"
-msgstr "tipus d'objecte no suportat en l'arbre"
+msgstr "tipus d'objecte no compatible en l'arbre"
-#: merge-recursive.c:1036 merge-recursive.c:1050
+#: merge-recursive.c:1033 merge-recursive.c:1047
#, c-format
msgid ""
"CONFLICT (%s/delete): %s deleted in %s and %s in %s. Version %s of %s left "
@@ -735,7 +738,7 @@ msgstr ""
"CONFLICTE: (%s/supressió): %s suprimit en %s i %s en %s. La versió %s de %s "
"s'ha deixat en l'arbre."
-#: merge-recursive.c:1042 merge-recursive.c:1055
+#: merge-recursive.c:1039 merge-recursive.c:1052
#, c-format
msgid ""
"CONFLICT (%s/delete): %s deleted in %s and %s in %s. Version %s of %s left "
@@ -744,188 +747,188 @@ msgstr ""
"CONFLICTE: (%s/supressió): %s suprimit en %s i %s en %s. La versió %s de %s "
"s'ha deixat en l'arbre a %s."
-#: merge-recursive.c:1096
+#: merge-recursive.c:1093
msgid "rename"
msgstr "canvia de nom"
-#: merge-recursive.c:1096
+#: merge-recursive.c:1093
msgid "renamed"
msgstr "canviat de nom"
-#: merge-recursive.c:1152
+#: merge-recursive.c:1149
#, c-format
msgid "%s is a directory in %s adding as %s instead"
msgstr "%s és un directori en %s; afegint com a %s en lloc"
-#: merge-recursive.c:1174
+#: merge-recursive.c:1171
#, c-format
msgid ""
"CONFLICT (rename/rename): Rename \"%s\"->\"%s\" in branch \"%s\" rename \"%s"
"\"->\"%s\" in \"%s\"%s"
msgstr ""
"CONFLICTE (canvi de nom/canvi de nom): Canvi de nom \"%s\"->\"%s\" en la "
-"rama \"%s\" canvi de nom \"%s\"->\"%s\" en \"%s\"%s"
+"branca \"%s\" canvi de nom \"%s\"->\"%s\" en \"%s\"%s"
-#: merge-recursive.c:1179
+#: merge-recursive.c:1176
msgid " (left unresolved)"
msgstr " (deixat sense resolució)"
-#: merge-recursive.c:1233
+#: merge-recursive.c:1230
#, c-format
msgid "CONFLICT (rename/rename): Rename %s->%s in %s. Rename %s->%s in %s"
msgstr ""
"CONFLICTE (canvi de nom/canvi de nom): Canvi de nom %s->%s en %s. Canvi de "
"nom %s->%s en %s"
-#: merge-recursive.c:1263
+#: merge-recursive.c:1260
#, c-format
msgid "Renaming %s to %s and %s to %s instead"
-msgstr "Canviant el nom de %s a %s i %s a %s en lloc"
+msgstr "Canviant el nom de %s a %s i %s a %s en lloc d'això"
-#: merge-recursive.c:1462
+#: merge-recursive.c:1459
#, c-format
msgid "CONFLICT (rename/add): Rename %s->%s in %s. %s added in %s"
msgstr ""
"CONFLICTE (supressió/afegiment): Canvi de nom %s->%s en %s. %s afegit en %s"
-#: merge-recursive.c:1472
+#: merge-recursive.c:1469
#, c-format
msgid "Adding merged %s"
msgstr "Afegint %s fusionat"
-#: merge-recursive.c:1477 merge-recursive.c:1675
+#: merge-recursive.c:1474 merge-recursive.c:1672
#, c-format
msgid "Adding as %s instead"
-msgstr "Afegint com a %s en lloc"
+msgstr "Afegint com a %s en lloc d'això"
-#: merge-recursive.c:1528
+#: merge-recursive.c:1525
#, c-format
msgid "cannot read object %s"
msgstr "no es pot llegir l'objecte %s"
-#: merge-recursive.c:1531
+#: merge-recursive.c:1528
#, c-format
msgid "object %s is not a blob"
msgstr "L'objecte %s no és un blob"
-#: merge-recursive.c:1579
+#: merge-recursive.c:1576
msgid "modify"
msgstr "modifica"
-#: merge-recursive.c:1579
+#: merge-recursive.c:1576
msgid "modified"
msgstr "modificat"
-#: merge-recursive.c:1589
+#: merge-recursive.c:1586
msgid "content"
msgstr "contingut"
-#: merge-recursive.c:1596
+#: merge-recursive.c:1593
msgid "add/add"
msgstr "afegiment/afegiment"
-#: merge-recursive.c:1630
+#: merge-recursive.c:1627
#, c-format
msgid "Skipped %s (merged same as existing)"
msgstr "%s saltat (el fusionat és igual a l'existent)"
-#: merge-recursive.c:1644
+#: merge-recursive.c:1641
#, c-format
msgid "Auto-merging %s"
msgstr "Autofusionant %s"
-#: merge-recursive.c:1648 git-submodule.sh:1150
+#: merge-recursive.c:1645 git-submodule.sh:1150
msgid "submodule"
msgstr "submòdul"
-#: merge-recursive.c:1649
+#: merge-recursive.c:1646
#, c-format
msgid "CONFLICT (%s): Merge conflict in %s"
msgstr "CONFLICTE (%s): Conflicte de fusió en %s"
-#: merge-recursive.c:1735
+#: merge-recursive.c:1732
#, c-format
msgid "Removing %s"
-msgstr "Traient %s"
+msgstr "Eliminant %s"
-#: merge-recursive.c:1760
+#: merge-recursive.c:1757
msgid "file/directory"
msgstr "fitxer/directori"
-#: merge-recursive.c:1766
+#: merge-recursive.c:1763
msgid "directory/file"
msgstr "directori/fitxer"
-#: merge-recursive.c:1771
+#: merge-recursive.c:1768
#, c-format
msgid "CONFLICT (%s): There is a directory with name %s in %s. Adding %s as %s"
msgstr ""
-"CONFLICTE (%s=: Hi ha un directori amb nom %s en %s. Afegint %s com a %s"
+"CONFLICTE (%s): Hi ha un directori amb nom %s en %s. Afegint %s com a %s"
-#: merge-recursive.c:1781
+#: merge-recursive.c:1778
#, c-format
msgid "Adding %s"
msgstr "Afegint %s"
-#: merge-recursive.c:1798
+#: merge-recursive.c:1795
msgid "Fatal merge failure, shouldn't happen."
msgstr "Fallat de fusió fatal; això no ha de passar."
-#: merge-recursive.c:1817
+#: merge-recursive.c:1814
msgid "Already up-to-date!"
msgstr "Ja al dia!"
-#: merge-recursive.c:1826
+#: merge-recursive.c:1823
#, c-format
msgid "merging of trees %s and %s failed"
msgstr "la fusió dels arbres %s i %s ha fallat"
-#: merge-recursive.c:1856
+#: merge-recursive.c:1853
#, c-format
msgid "Unprocessed path??? %s"
-msgstr "Ruta no processat??? %s"
+msgstr "Camí no processat??? %s"
-#: merge-recursive.c:1901
+#: merge-recursive.c:1898
msgid "Merging:"
msgstr "Fusionant:"
-#: merge-recursive.c:1914
+#: merge-recursive.c:1911
#, c-format
msgid "found %u common ancestor:"
msgid_plural "found %u common ancestors:"
msgstr[0] "s'ha trobat %u avantpassat:"
msgstr[1] "s'han trobat %u avantpassats:"
-#: merge-recursive.c:1951
+#: merge-recursive.c:1948
msgid "merge returned no commit"
msgstr "la fusió no ha retornat cap comissió"
-#: merge-recursive.c:2008
+#: merge-recursive.c:2005
#, c-format
msgid "Could not parse object '%s'"
msgstr "No s'ha pogut analitzar l'objecte '%s'"
-#: merge-recursive.c:2019 builtin/merge.c:666
+#: merge-recursive.c:2016 builtin/merge.c:667
msgid "Unable to write index."
-msgstr "Incapaç d'escriure l'índex."
+msgstr "No s'ha pogut escriure l'índex."
#: notes-utils.c:41
msgid "Cannot commit uninitialized/unreferenced notes tree"
msgstr "No es pot cometre un arbre de notes no inicialitzat / no referenciat"
-#: notes-utils.c:83
+#: notes-utils.c:82
#, c-format
msgid "Bad notes.rewriteMode value: '%s'"
msgstr "Valor de notes.rewriteMode dolent: '%s'"
-#: notes-utils.c:93
+#: notes-utils.c:92
#, c-format
msgid "Refusing to rewrite notes in %s (outside of refs/notes/)"
msgstr "Refusant reescriure les notes en %s (fora de refs/notes/)"
#. TRANSLATORS: The first %s is the name of the
#. environment variable, the second %s is its value
-#: notes-utils.c:120
+#: notes-utils.c:119
#, c-format
msgid "Bad %s value: '%s'"
msgstr "Valor dolent de %s: '%s'"
@@ -933,7 +936,7 @@ msgstr "Valor dolent de %s: '%s'"
#: object.c:241
#, c-format
msgid "unable to parse object: %s"
-msgstr "incapaç d'analitzar l'objecte: %s"
+msgstr "no s'ha pogut analitzar l'objecte: %s"
#: parse-options.c:546
msgid "..."
@@ -949,7 +952,7 @@ msgstr "ús: %s"
#: parse-options.c:568
#, c-format
msgid " or: %s"
-msgstr " o: %s"
+msgstr " o: %s"
#: parse-options.c:571
#, c-format
@@ -963,7 +966,7 @@ msgstr "-NUM"
#: pathspec.c:133
msgid "global 'glob' and 'noglob' pathspec settings are incompatible"
msgstr ""
-"els ajusts d'especificació de ruta 'glob' i 'noglob' globals són "
+"els ajusts d'especificació de camí 'glob' i 'noglob' globals són "
"incompatibles"
#: pathspec.c:143
@@ -971,27 +974,27 @@ msgid ""
"global 'literal' pathspec setting is incompatible with all other global "
"pathspec settings"
msgstr ""
-"l'ajust d'especificació de ruta 'literal' global és incompatible amb tots "
-"els altres ajusts d'especificació de ruta globals"
+"l'ajust d'especificació de camí 'literal' global és incompatible amb tots "
+"els altres ajusts d'especificació de camí globals"
#: pathspec.c:177
msgid "invalid parameter for pathspec magic 'prefix'"
-msgstr "paràmetre invàlid per a la màgica d'especificació de ruta 'prefix'"
+msgstr "paràmetre no vàlid per a la màgia d'especificació de camí 'prefix'"
#: pathspec.c:183
#, c-format
msgid "Invalid pathspec magic '%.*s' in '%s'"
-msgstr "Màgica d'especificació de ruta invàlida '%.*s' en '%s'"
+msgstr "Màgia d'especificació de camí no vàlida '%.*s' en '%s'"
#: pathspec.c:187
#, c-format
msgid "Missing ')' at the end of pathspec magic in '%s'"
-msgstr "')' mancant al final de la màgica d'especificació de ruta en '%s'"
+msgstr "')' mancant al final de la màgia d'especificació de camí en '%s'"
#: pathspec.c:205
#, c-format
msgid "Unimplemented pathspec magic '%c' in '%s'"
-msgstr "Màgica d'especificació de ruta no implementada '%c' en '%s'"
+msgstr "Màgia d'especificació de camí no implementada '%c' en '%s'"
#: pathspec.c:230
#, c-format
@@ -1011,12 +1014,13 @@ msgstr "L'especificació '%s' és en el submòdul '%.*s'"
#: pathspec.c:353
#, c-format
msgid "%s: pathspec magic not supported by this command: %s"
-msgstr "%s: aquest ordre no suporta la màgica d'especificació de ruta: %s"
+msgstr ""
+"%s: aquesta ordre no és compatible amb la màgia d'especificació de camí: %s"
#: pathspec.c:432
#, c-format
msgid "pathspec '%s' is beyond a symbolic link"
-msgstr "l'especificació de ruta '%s' és més allà d'un enllaç simbòlic"
+msgstr "l'especificació de camí '%s' és més enllà d'un enllaç simbòlic"
#: pathspec.c:441
msgid ""
@@ -1028,34 +1032,34 @@ msgstr ""
#: pretty.c:968
msgid "unable to parse --pretty format"
-msgstr "incapaç d'analitzar el format --pretty"
+msgstr "no s'ha pogut analitzar el format --pretty"
#: progress.c:225
msgid "done"
msgstr "fet"
-#: read-cache.c:1261
+#: read-cache.c:1267
#, c-format
msgid ""
"index.version set, but the value is invalid.\n"
"Using version %i"
msgstr ""
-"index.version establert, però el valor és invàlid.\n"
+"index.version establert, però el valor no és vàlid.\n"
"Usant la versió %i"
-#: read-cache.c:1271
+#: read-cache.c:1277
#, c-format
msgid ""
"GIT_INDEX_VERSION set, but the value is invalid.\n"
"Using version %i"
msgstr ""
-"GIT_INDEX_VERSION establert, però el valor és invàlid.\n"
+"GIT_INDEX_VERSION establert, però el valor no és vàlid.\n"
"Usant la versió %i"
#: remote.c:782
#, c-format
msgid "Cannot fetch both %s and %s to %s"
-msgstr "No és pot obtenir ambdós %s i %s a %s"
+msgstr "No es pot obtenir ambdós %s i %s a %s"
#: remote.c:786
#, c-format
@@ -1071,48 +1075,48 @@ msgstr "%s segueix ambdós %s i %s"
msgid "Internal error"
msgstr "Error intern"
-#: remote.c:1968
+#: remote.c:1980
#, c-format
msgid "Your branch is based on '%s', but the upstream is gone.\n"
-msgstr "La teva rama està basada en '%s', però la font no és.\n"
+msgstr "La vostra branca està basada en '%s', però la font no hi és.\n"
-#: remote.c:1972
+#: remote.c:1984
msgid " (use \"git branch --unset-upstream\" to fixup)\n"
msgstr " (useu \"git branch --unset-upstream\" per a arreglar)\n"
-#: remote.c:1975
+#: remote.c:1987
#, c-format
msgid "Your branch is up-to-date with '%s'.\n"
-msgstr "La vostra rama està al dia amb '%s'.\n"
+msgstr "La vostra branca està al dia amb '%s'.\n"
-#: remote.c:1979
+#: remote.c:1991
#, c-format
msgid "Your branch is ahead of '%s' by %d commit.\n"
msgid_plural "Your branch is ahead of '%s' by %d commits.\n"
-msgstr[0] "La vostra rama està davant de '%s' per %d comissions.\n"
-msgstr[1] "La vostra rama està davant de '%s' per %d comissions.\n"
+msgstr[0] "La vostra branca està davant de '%s' per %d comissió.\n"
+msgstr[1] "La vostra branca està davant de '%s' per %d comissions.\n"
-#: remote.c:1985
+#: remote.c:1997
msgid " (use \"git push\" to publish your local commits)\n"
msgstr " (useu \"git push\" per a publicar les vostres comissions locals)\n"
-#: remote.c:1988
+#: remote.c:2000
#, c-format
msgid "Your branch is behind '%s' by %d commit, and can be fast-forwarded.\n"
msgid_plural ""
"Your branch is behind '%s' by %d commits, and can be fast-forwarded.\n"
msgstr[0] ""
-"La vostra rama està darrere de '%s' per %d comissió, i pot avançar-se "
+"La vostra branca està darrere de '%s' per %d comissió, i pot avançar-se "
"ràpidament.\n"
msgstr[1] ""
-"La vostra rama està darrere de '%s' per %d comissions, i pot avançar-se "
+"La vostra branca està darrere de '%s' per %d comissions, i pot avançar-se "
"ràpidament.\n"
-#: remote.c:1996
+#: remote.c:2008
msgid " (use \"git pull\" to update your local branch)\n"
-msgstr " (useu \"git pull\" per a actualitzar la vostra rama local)\n"
+msgstr " (useu \"git pull\" per a actualitzar la vostra branca local)\n"
-#: remote.c:1999
+#: remote.c:2011
#, c-format
msgid ""
"Your branch and '%s' have diverged,\n"
@@ -1121,15 +1125,15 @@ msgid_plural ""
"Your branch and '%s' have diverged,\n"
"and have %d and %d different commits each, respectively.\n"
msgstr[0] ""
-"La vostra rama i '%s' s'han divergit,\n"
+"La vostra branca i '%s' s'han divergit,\n"
"i tenen %d i %d comissió distinta cada una, respectivament.\n"
msgstr[1] ""
-"La vostra rama i '%s' s'han divergit,\n"
+"La vostra branca i '%s' s'han divergit,\n"
"i tenen %d i %d comissions distintes cada una, respectivament.\n"
-#: remote.c:2009
+#: remote.c:2021
msgid " (use \"git pull\" to merge the remote branch into yours)\n"
-msgstr " (useu \"git pull\" per a fusionar la rama remota a la vostra)\n"
+msgstr " (useu \"git pull\" per a fusionar la branca remota a la vostra)\n"
#: run-command.c:87
msgid "open /dev/null failed"
@@ -1140,22 +1144,22 @@ msgstr "s'ha fallat en obrir /dev/null"
msgid "dup2(%d,%d) failed"
msgstr "dup2(%d,%d) ha fallat"
-#: send-pack.c:265
+#: send-pack.c:268
msgid "failed to sign the push certificate"
msgstr "s'ha fallat en firmar el certificat de pujada"
-#: send-pack.c:322
+#: send-pack.c:325
msgid "the receiving end does not support --signed push"
-msgstr "el destí rebent no suporta el pujar --signed"
+msgstr "el destí receptor no admet pujar --signed"
-#: sequencer.c:172 builtin/merge.c:781 builtin/merge.c:892
-#: builtin/merge.c:1002 builtin/merge.c:1012
+#: sequencer.c:172 builtin/merge.c:782 builtin/merge.c:893 builtin/merge.c:995
+#: builtin/merge.c:1005
#, c-format
msgid "Could not open '%s' for writing"
msgstr "No s'ha pogut obrir '%s' per a escriptura"
-#: sequencer.c:174 builtin/merge.c:343 builtin/merge.c:784
-#: builtin/merge.c:1004 builtin/merge.c:1017
+#: sequencer.c:174 builtin/merge.c:344 builtin/merge.c:785 builtin/merge.c:997
+#: builtin/merge.c:1010
#, c-format
msgid "Could not write to '%s'"
msgstr "No s'ha pogut escriure al '%s'"
@@ -1165,8 +1169,8 @@ msgid ""
"after resolving the conflicts, mark the corrected paths\n"
"with 'git add <paths>' or 'git rm <paths>'"
msgstr ""
-"després de resoldre els conflictes, marqueu les rutes\n"
-"corregides amb 'git add <rutes>' o 'git rm <rutes>'"
+"després de resoldre els conflictes, marqueu els camins\n"
+"corregits amb 'git add <camins>' o 'git rm <camins>'"
#: sequencer.c:198
msgid ""
@@ -1174,11 +1178,11 @@ msgid ""
"with 'git add <paths>' or 'git rm <paths>'\n"
"and commit the result with 'git commit'"
msgstr ""
-"després de resoldre els conflictes, marqueu les rutes\n"
-"corregides amb 'git add <rutes>' o 'git rm <rutes>'\n"
+"després de resoldre els conflictes, marqueu els camins\n"
+"corregits amb 'git add <camins>' o 'git rm <camins>'\n"
"i cometeu el resultat amb 'git commit'"
-#: sequencer.c:211 sequencer.c:852 sequencer.c:935
+#: sequencer.c:211 sequencer.c:856 sequencer.c:939
#, c-format
msgid "Could not write to %s"
msgstr "No s'ha pogut escriure a %s"
@@ -1186,7 +1190,7 @@ msgstr "No s'ha pogut escriure a %s"
#: sequencer.c:214
#, c-format
msgid "Error wrapping up %s"
-msgstr "Error en terminar %s"
+msgstr "Error en finalitzar %s"
#: sequencer.c:229
msgid "Your local changes would be overwritten by cherry-pick."
@@ -1201,44 +1205,44 @@ msgid "Commit your changes or stash them to proceed."
msgstr "Cometeu els vostres canvis o emmagatzemeu-los per a procedir."
#. TRANSLATORS: %s will be "revert" or "cherry-pick"
-#: sequencer.c:304
+#: sequencer.c:321
#, c-format
msgid "%s: Unable to write new index file"
-msgstr "%s: Incapaç d'escriure un fitxer d'índex nou"
+msgstr "%s: No s'ha pogut escriure un fitxer d'índex nou"
-#: sequencer.c:335
+#: sequencer.c:339
msgid "Could not resolve HEAD commit\n"
msgstr "No s'ha pogut resoldre la comissió HEAD\n"
-#: sequencer.c:355
+#: sequencer.c:359
msgid "Unable to update cache tree\n"
-msgstr "Incapaç d'actualitzar l'arbre cau\n"
+msgstr "No s'ha pogut actualitzar l'arbre cau\n"
-#: sequencer.c:402
+#: sequencer.c:406
#, c-format
msgid "Could not parse commit %s\n"
msgstr "No s'ha pogut analitzar la comissió %s\n"
-#: sequencer.c:407
+#: sequencer.c:411
#, c-format
msgid "Could not parse parent commit %s\n"
-msgstr "No s'ha pogut analitzar la comissió pare %s\n"
+msgstr "No s'ha pogut analitzar la comissió mare %s\n"
-#: sequencer.c:473
+#: sequencer.c:477
msgid "Your index file is unmerged."
msgstr "El vostre fitxer d'índex està sense fusionar."
-#: sequencer.c:492
+#: sequencer.c:496
#, c-format
msgid "Commit %s is a merge but no -m option was given."
-msgstr "La comissió %s és una fusió però cap opció -m s'ha donat."
+msgstr "La comissió %s és una fusió però no s'ha donat cap opció -m."
-#: sequencer.c:500
+#: sequencer.c:504
#, c-format
msgid "Commit %s does not have parent %d"
-msgstr "La comissió %s no té pare %d"
+msgstr "La comissió %s no té mare %d"
-#: sequencer.c:504
+#: sequencer.c:508
#, c-format
msgid "Mainline was specified but commit %s is not a merge."
msgstr ""
@@ -1246,154 +1250,154 @@ msgstr ""
#. TRANSLATORS: The first %s will be "revert" or
#. "cherry-pick", the second %s a SHA1
-#: sequencer.c:517
+#: sequencer.c:521
#, c-format
msgid "%s: cannot parse parent commit %s"
-msgstr "%s: no es pot analitzar la comissió pare %s"
+msgstr "%s: no es pot analitzar la comissió mare %s"
-#: sequencer.c:521
+#: sequencer.c:525
#, c-format
msgid "Cannot get commit message for %s"
msgstr "No es pot obtenir el missatge de comissió de %s"
-#: sequencer.c:607
+#: sequencer.c:611
#, c-format
msgid "could not revert %s... %s"
msgstr "no s'ha pogut revertir %s...%s"
-#: sequencer.c:608
+#: sequencer.c:612
#, c-format
msgid "could not apply %s... %s"
msgstr "no s'ha pogut aplicar %s...%s"
-#: sequencer.c:644
+#: sequencer.c:648
msgid "empty commit set passed"
msgstr "conjunt de comissions buit passat"
-#: sequencer.c:652
+#: sequencer.c:656
#, c-format
msgid "git %s: failed to read the index"
msgstr "git %s: s'ha fallat en llegir l'índex"
-#: sequencer.c:656
+#: sequencer.c:660
#, c-format
msgid "git %s: failed to refresh the index"
msgstr "git %s: s'ha fallat en actualitzar l'índex"
-#: sequencer.c:716
+#: sequencer.c:720
#, c-format
msgid "Cannot %s during a %s"
msgstr "No es pot %s durant un %s"
-#: sequencer.c:738
+#: sequencer.c:742
#, c-format
msgid "Could not parse line %d."
msgstr "No s'ha pogut analitzar la línia %d."
-#: sequencer.c:743
+#: sequencer.c:747
msgid "No commits parsed."
msgstr "Cap comissió analitzada."
-#: sequencer.c:756
+#: sequencer.c:760
#, c-format
msgid "Could not open %s"
msgstr "No s'ha pogut obrir %s"
-#: sequencer.c:760
+#: sequencer.c:764
#, c-format
msgid "Could not read %s."
msgstr "No s'ha pogut llegir %s."
-#: sequencer.c:767
+#: sequencer.c:771
#, c-format
msgid "Unusable instruction sheet: %s"
msgstr "Full d'instruccions inusable: %s"
-#: sequencer.c:797
+#: sequencer.c:801
#, c-format
msgid "Invalid key: %s"
-msgstr "Clau invàlid: %s"
+msgstr "Clau no vàlida: %s"
-#: sequencer.c:800
+#: sequencer.c:804
#, c-format
msgid "Invalid value for %s: %s"
-msgstr "Valor invàlid per a %s: %s"
+msgstr "Valor no vàlid per a %s: %s"
-#: sequencer.c:812
+#: sequencer.c:816
#, c-format
msgid "Malformed options sheet: %s"
-msgstr "Full d'opcions malformat: %s"
+msgstr "Full d'opcions mal format: %s"
-#: sequencer.c:833
+#: sequencer.c:837
msgid "a cherry-pick or revert is already in progress"
msgstr "un recull de cireres o una reversió ja està en curs"
-#: sequencer.c:834
+#: sequencer.c:838
msgid "try \"git cherry-pick (--continue | --quit | --abort)\""
msgstr "intenteu \"git cherry-pick (--continue | --quit | --abort)\""
-#: sequencer.c:838
+#: sequencer.c:842
#, c-format
msgid "Could not create sequencer directory %s"
msgstr "No s'ha pogut crear el directori de seqüenciador %s"
-#: sequencer.c:854 sequencer.c:939
+#: sequencer.c:858 sequencer.c:943
#, c-format
msgid "Error wrapping up %s."
-msgstr "Error en terminar %s."
+msgstr "Error en finalitzar %s."
-#: sequencer.c:873 sequencer.c:1009
+#: sequencer.c:877 sequencer.c:1013
msgid "no cherry-pick or revert in progress"
-msgstr "ni recull de cireres ni una reversió està en curs"
+msgstr "ni hi ha cap recull de cireres ni cap reversió en curs"
-#: sequencer.c:875
+#: sequencer.c:879
msgid "cannot resolve HEAD"
msgstr "no es pot resoldre HEAD"
-#: sequencer.c:877
+#: sequencer.c:881
msgid "cannot abort from a branch yet to be born"
-msgstr "no es pot avortar des d'una rama que encara ha de nàixer"
+msgstr "no es pot avortar des d'una branca que encara ha de nàixer"
-#: sequencer.c:899 builtin/apply.c:4128
+#: sequencer.c:903 builtin/apply.c:4128
#, c-format
msgid "cannot open %s: %s"
msgstr "no es pot obrir %s: %s"
-#: sequencer.c:902
+#: sequencer.c:906
#, c-format
msgid "cannot read %s: %s"
msgstr "no es pot llegir %s: %s"
-#: sequencer.c:903
+#: sequencer.c:907
msgid "unexpected end of file"
-msgstr "fin de fitxer inesperat"
+msgstr "final de fitxer inesperat"
-#: sequencer.c:909
+#: sequencer.c:913
#, c-format
msgid "stored pre-cherry-pick HEAD file '%s' is corrupt"
msgstr ""
-"el fitxer HEAD emmagatzemat abans del recull de cirers '%s' és corrupte"
+"el fitxer HEAD emmagatzemat abans del recull de cireres '%s' és corrupte"
-#: sequencer.c:932
+#: sequencer.c:936
#, c-format
msgid "Could not format %s."
msgstr "No s'ha pogut formatar %s."
-#: sequencer.c:1077
+#: sequencer.c:1081
#, c-format
msgid "%s: can't cherry-pick a %s"
-msgstr "%s: no es pot recollir com cirera un %s"
+msgstr "%s: no es pot recollir com a cirera un %s"
-#: sequencer.c:1080
+#: sequencer.c:1084
#, c-format
msgid "%s: bad revision"
msgstr "%s: revisió dolenta"
-#: sequencer.c:1114
+#: sequencer.c:1118
msgid "Can't revert as initial commit"
msgstr "No es pot revertir com a comissió inicial"
-#: sequencer.c:1115
+#: sequencer.c:1119
msgid "Can't cherry-pick into empty head"
msgstr "No es pot recollir cireres en un cap buit"
@@ -1409,36 +1413,37 @@ msgid ""
"examine these refs and maybe delete them. Turn this message off by\n"
"running \"git config advice.objectNameWarning false\""
msgstr ""
-"Git normalment mai crea una referència que termini amb 40 caràcters\n"
+"Git normalment mai crea una referència que acabi amb 40 caràcters\n"
"hexadecimals perquè s'ignorarà quan només especifiqueu 40 caràcters\n"
"hexadecimals. Aquestes referències es poden crear per error. Per\n"
"exemple,\n"
"\n"
" git checkout -b $br $(git rev-parse ...)\n"
"\n"
-"on \"$br\" és de alguna manera buit i una referència de 40 caràcters\n"
+"on \"$br\" és d'alguna manera buit i una referència de 40 caràcters\n"
"hexadecimals. Si us plau, examineu aquests referències i potser\n"
-"suprimiu-les. Desactiva aquest missatge per executar\n"
+"suprimiu-les. Desactiveu aquest missatge executant\n"
"\"git config advice.objectNameWarning false\""
#: sha1_name.c:1068
msgid "HEAD does not point to a branch"
-msgstr "HEAD no assenyala cap rama"
+msgstr "HEAD no assenyala cap branca"
#: sha1_name.c:1071
#, c-format
msgid "No such branch: '%s'"
-msgstr "No hi ha tal rama: '%s'"
+msgstr "No hi ha tal branca: '%s'"
#: sha1_name.c:1073
#, c-format
msgid "No upstream configured for branch '%s'"
-msgstr "Cap font configurada per a la rama '%s'"
+msgstr "Cap font configurada per a la branca '%s'"
#: sha1_name.c:1077
#, c-format
msgid "Upstream branch '%s' not stored as a remote-tracking branch"
-msgstr "La rama font '%s' no s'emmagatzema com a rama que segueixi al remot"
+msgstr ""
+"La branca font '%s' no s'emmagatzema com a branca que segueixi al remot"
#: submodule.c:64 submodule.c:98
msgid "Cannot change unmerged .gitmodules, resolve merge conflicts first"
@@ -1459,13 +1464,13 @@ msgstr "No s'ha pogut actualitzar l'entrada de .gitmodules %s"
#: submodule.c:109
#, c-format
msgid "Could not remove .gitmodules entry for %s"
-msgstr "No s'ha pogut treure l'entrada de .gitmodules per a %s"
+msgstr "No s'ha pogut eliminar l'entrada de .gitmodules per a %s"
#: submodule.c:120
msgid "staging updated .gitmodules failed"
msgstr "L'allistament del .gitmodules actualitzat ha fallat"
-#: submodule.c:1111 builtin/init-db.c:363
+#: submodule.c:1111 builtin/init-db.c:371
#, c-format
msgid "Could not create git link %s"
msgstr "No s'ha pogut crear l'enllaç de git %s"
@@ -1475,28 +1480,28 @@ msgstr "No s'ha pogut crear l'enllaç de git %s"
msgid "Could not set core.worktree in %s"
msgstr "No s'ha pogut establir core.worktree en %s"
-#: trailer.c:499 trailer.c:503 trailer.c:507 trailer.c:561 trailer.c:565
-#: trailer.c:569
+#: trailer.c:500 trailer.c:504 trailer.c:508 trailer.c:562 trailer.c:566
+#: trailer.c:570
#, c-format
msgid "unknown value '%s' for key '%s'"
msgstr "valor desconegut '%s' per a la clau '%s'"
-#: trailer.c:551 trailer.c:556 builtin/remote.c:288
+#: trailer.c:552 trailer.c:557 builtin/remote.c:290
#, c-format
msgid "more than one %s"
msgstr "més d'un %s"
-#: trailer.c:589
+#: trailer.c:590
#, c-format
msgid "empty trailer token in trailer '%.*s'"
msgstr "fitxa de remolc buida en el remolc '%.*s'"
-#: trailer.c:709
+#: trailer.c:710
#, c-format
msgid "could not read input file '%s'"
msgstr "no s'ha pogut llegir el fitxer d'entrada '%s'"
-#: trailer.c:712
+#: trailer.c:713
msgid "could not read from stdin"
msgstr "No s'ha pogut llegir des d'stdin"
@@ -1506,12 +1511,12 @@ msgstr "Agafant fitxers"
#: urlmatch.c:120
msgid "invalid URL scheme name or missing '://' suffix"
-msgstr "l'esquema d'URL és invàlida o li manca el sufix '://'"
+msgstr "l'esquema d'URL no és vàlida o li manca el sufix '://'"
#: urlmatch.c:144 urlmatch.c:297 urlmatch.c:356
#, c-format
msgid "invalid %XX escape sequence"
-msgstr "seqüència d'escapament %XX invàlida"
+msgstr "seqüència d'escapament %XX no vàlida"
#: urlmatch.c:172
msgid "missing host and scheme is not 'file:'"
@@ -1523,30 +1528,30 @@ msgstr "un URL 'file:' no pot tenir número de port"
#: urlmatch.c:199
msgid "invalid characters in host name"
-msgstr "hi ha caràcters invàlids en el nom de host"
+msgstr "hi ha caràcters no vàlids en el nom de host"
#: urlmatch.c:244 urlmatch.c:255
msgid "invalid port number"
-msgstr "número de port invàlid"
+msgstr "número de port no vàlid"
#: urlmatch.c:322
msgid "invalid '..' path segment"
-msgstr "segment de ruta '..' invàlid"
+msgstr "segment de camí '..' no vàlid"
#: wrapper.c:509
#, c-format
msgid "unable to access '%s': %s"
-msgstr "incapaç d'accedir a '%s': %s"
+msgstr "no s'ha pogut accedir a '%s': %s"
#: wrapper.c:530
#, c-format
msgid "unable to access '%s'"
-msgstr "incapaç d'accedir a '%s'"
+msgstr "no s'ha pogut accedir a '%s'"
#: wrapper.c:541
#, c-format
msgid "unable to look up current user in the passwd file: %s"
-msgstr "incapaç de trobar l'usuari actual en el fitxer passwd: %s"
+msgstr "no s'ha pogut trobar l'usuari actual en el fitxer passwd: %s"
#: wrapper.c:542
msgid "no such user"
@@ -1554,11 +1559,11 @@ msgstr "no hi ha tal usuari"
#: wrapper.c:550
msgid "unable to get current working directory"
-msgstr "incapaç d'obtenir el directori de treball actual"
+msgstr "no s'ha pogut obtenir el directori de treball actual"
#: wt-status.c:150
msgid "Unmerged paths:"
-msgstr "Rutes sense fusionar:"
+msgstr "Camins sense fusionar:"
#: wt-status.c:177 wt-status.c:204
#, c-format
@@ -1626,11 +1631,11 @@ msgstr "afegit per nosaltres:"
#: wt-status.c:256
msgid "deleted by them:"
-msgstr "suprimit pels:"
+msgstr "suprimit per ells:"
#: wt-status.c:258
msgid "added by them:"
-msgstr "afegit pels:"
+msgstr "afegit per ells:"
#: wt-status.c:260
msgid "deleted by us:"
@@ -1647,7 +1652,7 @@ msgstr "modificat per ambdós:"
#: wt-status.c:266
#, c-format
msgid "bug: unhandled unmerged status %x"
-msgstr "bug: estat no fusionat no manejat %x"
+msgstr "bug: estat no fusionat no gestionat %x"
#: wt-status.c:274
msgid "new file:"
@@ -1696,245 +1701,245 @@ msgstr "contingut no seguit, "
#: wt-status.c:391
#, c-format
msgid "bug: unhandled diff status %c"
-msgstr "bug: estat de diferència no manejat %c"
+msgstr "bug: estat de diferència no gestionat %c"
-#: wt-status.c:761
+#: wt-status.c:758
msgid "Submodules changed but not updated:"
msgstr "Submòduls canviats però no actualitzats:"
-#: wt-status.c:763
+#: wt-status.c:760
msgid "Submodule changes to be committed:"
msgstr "Canvis de submòdul a cometre:"
-#: wt-status.c:842
+#: wt-status.c:839
msgid ""
"Do not touch the line above.\n"
"Everything below will be removed."
msgstr ""
-"No toqueu la línia amunt.\n"
-"Tot a baix es traurà."
+"No toqueu la línia de sobre.\n"
+"Tot el que hi ha a sota s'eliminarà."
-#: wt-status.c:933
+#: wt-status.c:930
msgid "You have unmerged paths."
-msgstr "Teniu rutes sense fusionar."
+msgstr "Teniu camins sense fusionar."
-#: wt-status.c:936
+#: wt-status.c:933
msgid " (fix conflicts and run \"git commit\")"
msgstr " (arregleu els conflictes i executeu \"git commit\")"
-#: wt-status.c:939
+#: wt-status.c:936
msgid "All conflicts fixed but you are still merging."
msgstr "Tots els conflictes estan arreglats però encara esteu fusionant."
-#: wt-status.c:942
+#: wt-status.c:939
msgid " (use \"git commit\" to conclude merge)"
msgstr " (useu \"git commit\" per a concloure la fusió)"
-#: wt-status.c:952
+#: wt-status.c:949
msgid "You are in the middle of an am session."
-msgstr "Esteu en el medi d'una sessió am."
+msgstr "Esteu enmig d'una sessió am."
-#: wt-status.c:955
+#: wt-status.c:952
msgid "The current patch is empty."
msgstr "El pedaç actual està buit."
-#: wt-status.c:959
+#: wt-status.c:956
msgid " (fix conflicts and then run \"git am --continue\")"
msgstr " (arregleu els conflictes i després executeu \"git am --continue\")"
-#: wt-status.c:961
+#: wt-status.c:958
msgid " (use \"git am --skip\" to skip this patch)"
-msgstr " (useu \"git am --skip\" per a saltar aquest pedaç)"
+msgstr " (useu \"git am --skip\" per a ometre aquest pedaç)"
-#: wt-status.c:963
+#: wt-status.c:960
msgid " (use \"git am --abort\" to restore the original branch)"
-msgstr " (useu \"git am --abort\" per a restaurar la rama original)"
+msgstr " (useu \"git am --abort\" per a restaurar la branca original)"
-#: wt-status.c:1023 wt-status.c:1040
+#: wt-status.c:1020 wt-status.c:1037
#, c-format
msgid "You are currently rebasing branch '%s' on '%s'."
-msgstr "Actualment esteu rebasant la rama '%s' en '%s'."
+msgstr "Actualment esteu rebasant la branca '%s' en '%s'."
-#: wt-status.c:1028 wt-status.c:1045
+#: wt-status.c:1025 wt-status.c:1042
msgid "You are currently rebasing."
msgstr "Actualment esteu rebasant."
-#: wt-status.c:1031
+#: wt-status.c:1028
msgid " (fix conflicts and then run \"git rebase --continue\")"
msgstr ""
" (arregleu els conflictes i després executeu \"git rebase --continue\")"
-#: wt-status.c:1033
+#: wt-status.c:1030
msgid " (use \"git rebase --skip\" to skip this patch)"
msgstr " (useu \"git rebase --skip\" per a saltar aquest pedaç)"
-#: wt-status.c:1035
+#: wt-status.c:1032
msgid " (use \"git rebase --abort\" to check out the original branch)"
-msgstr " (useu \"git rebase --abort\" per a agafar la rama original)"
+msgstr " (useu \"git rebase --abort\" per a agafar la branca original)"
-#: wt-status.c:1048
+#: wt-status.c:1045
msgid " (all conflicts fixed: run \"git rebase --continue\")"
msgstr " (tots els conflictes arreglats: executeu \"git rebase --continue\")"
-#: wt-status.c:1052
+#: wt-status.c:1049
#, c-format
msgid ""
"You are currently splitting a commit while rebasing branch '%s' on '%s'."
msgstr ""
-"Actualment esteu dividint una comissió mentre rebasant la rama '%s' en '%s'."
+"Actualment esteu dividint una comissió mentre rebaseu la branca '%s' en '%s'."
-#: wt-status.c:1057
+#: wt-status.c:1054
msgid "You are currently splitting a commit during a rebase."
msgstr "Actualment esteu dividint una comissió durant una rebase."
-#: wt-status.c:1060
+#: wt-status.c:1057
msgid " (Once your working directory is clean, run \"git rebase --continue\")"
msgstr ""
" (Una vegada que el vostre directori de treball sigui net, executeu \"git "
"rebase --continue\")"
-#: wt-status.c:1064
+#: wt-status.c:1061
#, c-format
msgid "You are currently editing a commit while rebasing branch '%s' on '%s'."
msgstr ""
-"Actualment esteu editant una comissió mentre rebasant la rama '%s' en '%s'."
+"Actualment esteu editant una comissió mentre rebaseu la branca '%s' en '%s'."
-#: wt-status.c:1069
+#: wt-status.c:1066
msgid "You are currently editing a commit during a rebase."
msgstr "Actualment esteu editant una comissió durant una rebase."
-#: wt-status.c:1072
+#: wt-status.c:1069
msgid " (use \"git commit --amend\" to amend the current commit)"
msgstr " (useu \"git commit --amend\" per a esmenar la comissió actual)"
-#: wt-status.c:1074
+#: wt-status.c:1071
msgid ""
" (use \"git rebase --continue\" once you are satisfied with your changes)"
msgstr ""
" (useu \"git rebase --continue\" una vegada que esteu satisfet amb els "
"vostres canvis)"
-#: wt-status.c:1084
+#: wt-status.c:1081
#, c-format
msgid "You are currently cherry-picking commit %s."
-msgstr "Actualment esteu recollint com cirera la comissió %s."
+msgstr "Actualment esteu recollint com a cirera la comissió %s."
-#: wt-status.c:1089
+#: wt-status.c:1086
msgid " (fix conflicts and run \"git cherry-pick --continue\")"
msgstr " (arregleu els conflictes i executeu \"git cherry-pick --continue\")"
-#: wt-status.c:1092
+#: wt-status.c:1089
msgid " (all conflicts fixed: run \"git cherry-pick --continue\")"
msgstr ""
" (tots els conflictes arreglats: executeu \"git cherry-pick --continue\")"
-#: wt-status.c:1094
+#: wt-status.c:1091
msgid " (use \"git cherry-pick --abort\" to cancel the cherry-pick operation)"
msgstr ""
" (useu \"git cherry-pick --abort\" per a cancel·lar l'operació de recull de "
"cireres)"
-#: wt-status.c:1103
+#: wt-status.c:1100
#, c-format
msgid "You are currently reverting commit %s."
msgstr "Actualment esteu revertint la comissió %s."
-#: wt-status.c:1108
+#: wt-status.c:1105
msgid " (fix conflicts and run \"git revert --continue\")"
msgstr " (arregleu els conflictes i executeu \"git revert --continue\")"
-#: wt-status.c:1111
+#: wt-status.c:1108
msgid " (all conflicts fixed: run \"git revert --continue\")"
msgstr ""
" (tots els conflictes estan arreglats: executeu \"git revert --continue\")"
-#: wt-status.c:1113
+#: wt-status.c:1110
msgid " (use \"git revert --abort\" to cancel the revert operation)"
msgstr ""
" (useu \"git revert --abort\" per a cancel·lar l'operació de reversió)"
-#: wt-status.c:1124
+#: wt-status.c:1121
#, c-format
msgid "You are currently bisecting, started from branch '%s'."
-msgstr "Actualment esteu bisecant, heu començat des de la rama '%s'."
+msgstr "Actualment esteu bisecant, heu començat des de la branca '%s'."
-#: wt-status.c:1128
+#: wt-status.c:1125
msgid "You are currently bisecting."
msgstr "Actualment esteu bisecant."
-#: wt-status.c:1131
+#: wt-status.c:1128
msgid " (use \"git bisect reset\" to get back to the original branch)"
-msgstr " (useu \"git bisect reset\" per a tornar a la rama original)"
+msgstr " (useu \"git bisect reset\" per a tornar a la branca original)"
-#: wt-status.c:1306
+#: wt-status.c:1303
msgid "On branch "
-msgstr "En la rama "
+msgstr "En la branca "
-#: wt-status.c:1313
+#: wt-status.c:1310
msgid "rebase in progress; onto "
msgstr "rebase en progrés; en "
-#: wt-status.c:1320
+#: wt-status.c:1317
msgid "HEAD detached at "
-msgstr "HEAD separat a"
+msgstr "HEAD separat a "
-#: wt-status.c:1322
+#: wt-status.c:1319
msgid "HEAD detached from "
-msgstr "HEAD separat de"
+msgstr "HEAD separat de "
-#: wt-status.c:1325
+#: wt-status.c:1322
msgid "Not currently on any branch."
-msgstr "Actualment no en cap rama."
+msgstr "Actualment no en cap branca."
-#: wt-status.c:1342
+#: wt-status.c:1339
msgid "Initial commit"
msgstr "Comissió inicial"
-#: wt-status.c:1356
+#: wt-status.c:1353
msgid "Untracked files"
msgstr "Fitxers no seguits"
-#: wt-status.c:1358
+#: wt-status.c:1355
msgid "Ignored files"
msgstr "Fitxers ignorats"
-#: wt-status.c:1362
+#: wt-status.c:1359
#, c-format
msgid ""
"It took %.2f seconds to enumerate untracked files. 'status -uno'\n"
"may speed it up, but you have to be careful not to forget to add\n"
"new files yourself (see 'git help status')."
msgstr ""
-"Ha trigat %.2f segons en enumerar fitxers no seguits.\n"
-"'status -uno' pot accelerar-ho, però heu de tenir cuidat de no\n"
-"oblidar afegir fitxers nous per vós mateix (veu\n"
+"S'ha trigat %.2f segons a enumerar fitxers no seguits.\n"
+"'status -uno' pot accelerar-ho, però heu d'anar amb compte de no\n"
+"oblidar-vos d'afegir fitxers nous per vós mateix (vegeu\n"
"'git help status')."
-#: wt-status.c:1368
+#: wt-status.c:1365
#, c-format
msgid "Untracked files not listed%s"
msgstr "Els fitxers no seguits no estan llistats%s"
-#: wt-status.c:1370
+#: wt-status.c:1367
msgid " (use -u option to show untracked files)"
msgstr " (useu l'opció -u per a mostrar els fitxers no seguits)"
-#: wt-status.c:1376
+#: wt-status.c:1373
msgid "No changes"
msgstr "Sense canvis"
-#: wt-status.c:1381
+#: wt-status.c:1378
#, c-format
msgid "no changes added to commit (use \"git add\" and/or \"git commit -a\")\n"
msgstr ""
"no hi ha canvis afegits a cometre (useu \"git add\" o \"git commit -a\")\n"
-#: wt-status.c:1384
+#: wt-status.c:1381
#, c-format
msgid "no changes added to commit\n"
msgstr "no hi ha canvis afegits a cometre\n"
-#: wt-status.c:1387
+#: wt-status.c:1384
#, c-format
msgid ""
"nothing added to commit but untracked files present (use \"git add\" to "
@@ -1943,58 +1948,58 @@ msgstr ""
"no hi ha res afegit a cometre però fitxers no seguits estan presents (useu "
"\"git add\" per a seguir-los)\n"
-#: wt-status.c:1390
+#: wt-status.c:1387
#, c-format
msgid "nothing added to commit but untracked files present\n"
msgstr "no hi ha res afegit a cometre però fitxers no seguits estan presents\n"
-#: wt-status.c:1393
+#: wt-status.c:1390
#, c-format
msgid "nothing to commit (create/copy files and use \"git add\" to track)\n"
msgstr ""
"no hi ha res a cometre (creeu/copieu fitxers i useu \"git add\" per a seguir-"
"los)\n"
-#: wt-status.c:1396 wt-status.c:1401
+#: wt-status.c:1393 wt-status.c:1398
#, c-format
msgid "nothing to commit\n"
msgstr "no hi ha res a cometre\n"
-#: wt-status.c:1399
+#: wt-status.c:1396
#, c-format
msgid "nothing to commit (use -u to show untracked files)\n"
msgstr ""
"no hi ha res a cometre (useu -u per a mostrar els fitxers no seguits)\n"
-#: wt-status.c:1403
+#: wt-status.c:1400
#, c-format
msgid "nothing to commit, working directory clean\n"
msgstr "no hi ha res a cometre, directori de treball net\n"
-#: wt-status.c:1512
+#: wt-status.c:1509
msgid "HEAD (no branch)"
-msgstr "HEAD (sense rama)"
+msgstr "HEAD (sense branca)"
-#: wt-status.c:1518
+#: wt-status.c:1515
msgid "Initial commit on "
msgstr "Comissió inicial en "
-#: wt-status.c:1550
+#: wt-status.c:1547
msgid "gone"
-msgstr "no és"
+msgstr "no hi és"
-#: wt-status.c:1552 wt-status.c:1560
+#: wt-status.c:1549 wt-status.c:1557
msgid "behind "
msgstr "darrere "
-#: compat/precompose_utf8.c:55 builtin/clone.c:357
+#: compat/precompose_utf8.c:55 builtin/clone.c:360
#, c-format
msgid "failed to unlink '%s'"
msgstr "s'ha fallat en desenllaçar '%s'"
#: builtin/add.c:22
msgid "git add [options] [--] <pathspec>..."
-msgstr "git add [opcions] [--] <especificació-de-ruta>..."
+msgstr "git add [opcions] [--] <especificació-de-camí>..."
#: builtin/add.c:65
#, c-format
@@ -2008,7 +2013,7 @@ msgstr "s'ha fallat en actualitzar els fitxers"
#: builtin/add.c:80
#, c-format
msgid "remove '%s'\n"
-msgstr "treu '%s'\n"
+msgstr "elimina '%s'\n"
#: builtin/add.c:134
msgid "Unstaged changes after refreshing the index:"
@@ -2043,31 +2048,32 @@ msgstr "No s'ha pogut aplicar '%s'"
#: builtin/add.c:231
msgid "The following paths are ignored by one of your .gitignore files:\n"
-msgstr "Les rutes següents s'ignoren per un dels vostres fitxers .gitignore:\n"
+msgstr ""
+"Els camins següents s'ignoren per un dels vostres fitxers .gitignore:\n"
#: builtin/add.c:248 builtin/clean.c:875 builtin/fetch.c:108 builtin/mv.c:110
-#: builtin/prune-packed.c:55 builtin/push.c:499 builtin/remote.c:1375
+#: builtin/prune-packed.c:55 builtin/push.c:499 builtin/remote.c:1372
#: builtin/rm.c:269
msgid "dry run"
msgstr "marxa en sec"
#: builtin/add.c:249 builtin/apply.c:4415 builtin/check-ignore.c:19
-#: builtin/commit.c:1362 builtin/count-objects.c:63 builtin/fsck.c:608
+#: builtin/commit.c:1326 builtin/count-objects.c:63 builtin/fsck.c:608
#: builtin/log.c:1617 builtin/mv.c:109 builtin/read-tree.c:114
msgid "be verbose"
-msgstr "sigues verbós"
+msgstr "sigues detallat"
#: builtin/add.c:251
msgid "interactive picking"
msgstr "recull interactiu"
-#: builtin/add.c:252 builtin/checkout.c:1108 builtin/reset.c:286
+#: builtin/add.c:252 builtin/checkout.c:1126 builtin/reset.c:286
msgid "select hunks interactively"
msgstr "selecciona els trossos interactivament"
#: builtin/add.c:253
msgid "edit current diff and apply"
-msgstr "edita la diferència actual i aplica'l"
+msgstr "edita la diferència actual i aplica-la"
#: builtin/add.c:254
msgid "allow adding otherwise ignored files"
@@ -2079,7 +2085,7 @@ msgstr "actualitza els fitxers seguits"
#: builtin/add.c:256
msgid "record only the fact that the path will be added later"
-msgstr "registra només el fet que la ruta s'afegirà més tard"
+msgstr "registra només el fet que el camí s'afegirà més tard"
#: builtin/add.c:257
msgid "add changes from all tracked and untracked files"
@@ -2087,7 +2093,8 @@ msgstr "afegeix els canvis de tots els fitxers seguits i no seguits"
#: builtin/add.c:260
msgid "ignore paths removed in the working tree (same as --no-all)"
-msgstr "ignora les rutes tretes en l'arbre de treball (el mateix que --no-all)"
+msgstr ""
+"ignora els camins eliminats en l'arbre de treball (el mateix que --no-all)"
#: builtin/add.c:262
msgid "don't add, only refresh the index"
@@ -2095,22 +2102,18 @@ msgstr "no afegeixis, només actualitza l'índex"
#: builtin/add.c:263
msgid "just skip files which cannot be added because of errors"
-msgstr "només salta els fitxers que no es poden afegir a causa d'errors"
+msgstr "només omet els fitxers que no es poden afegir a causa d'errors"
#: builtin/add.c:264
msgid "check if - even missing - files are ignored in dry run"
msgstr ""
-"comproveu si els fitxers - encara els mancants - s'ignoren en marxa en sec"
+"comproveu si els fitxers - fins i tot els absents - s'ignoren en marxa en sec"
#: builtin/add.c:286
#, c-format
msgid "Use -f if you really want to add them.\n"
msgstr "Useu -f si realment els voleu afegir.\n"
-#: builtin/add.c:287
-msgid "no files added"
-msgstr "cap fitxer afegit"
-
#: builtin/add.c:293
msgid "adding files failed"
msgstr "l'afegiment de fitxers ha fallat"
@@ -2140,7 +2143,7 @@ msgstr "fitxer d'índex malmès"
#: builtin/add.c:446 builtin/apply.c:4510 builtin/mv.c:279 builtin/rm.c:431
msgid "Unable to write new index file"
-msgstr "Incapaç d'escriure un fitxer d'índex nou"
+msgstr "no s'ha pogut escriure un fitxer d'índex nou"
#: builtin/apply.c:58
msgid "git apply [options] [<patch>...]"
@@ -2169,7 +2172,7 @@ msgstr "regexec ha retornat %d per l'entrada: %s"
#: builtin/apply.c:916
#, c-format
msgid "unable to find filename in patch at line %d"
-msgstr "incapaç de trobar el nom de fitxer en el pedaç a la línia %d"
+msgstr "no s'ha pogut trobar el nom de fitxer en el pedaç a la línia %d"
#: builtin/apply.c:948
#, c-format
@@ -2213,11 +2216,11 @@ msgid_plural ""
"git diff header lacks filename information when removing %d leading pathname "
"components (line %d)"
msgstr[0] ""
-"a la capçalera de git diff li manca informació de nom de fitxer en treure %d "
-"component de nom de ruta inicial (línia %d)"
+"a la capçalera de git diff li manca informació de nom de fitxer en eliminar "
+"%d component de nom de camí inicial (línia %d)"
msgstr[1] ""
-"a la capçalera de git diff li manca informació de nom de fitxer en treure %d "
-"components de nom de ruta inicial (línia %d)"
+"a la capçalera de git diff li manca informació de nom de fitxer en eliminar "
+"%d components de nom de camí inicial (línia %d)"
#: builtin/apply.c:1657
msgid "new file depends on old contents"
@@ -2245,7 +2248,7 @@ msgstr "el fitxer suprimit %s encara té continguts"
#: builtin/apply.c:1726
#, c-format
msgid "** warning: file %s becomes empty but is not deleted"
-msgstr "** avís: el fitxer %s es buida però no es suprimeix"
+msgstr "** avís: el fitxer %s queda buit però no es suprimeix"
#: builtin/apply.c:1872
#, c-format
@@ -2265,12 +2268,12 @@ msgstr "pedaç amb només escombraries a la línia %d"
#: builtin/apply.c:2142
#, c-format
msgid "unable to read symlink %s"
-msgstr "incapaç de llegir l'enllaç simbòlic %s"
+msgstr "no s'ha pogut llegir l'enllaç simbòlic %s"
#: builtin/apply.c:2146
#, c-format
msgid "unable to open or read %s"
-msgstr "incapaç d'obrir o llegir %s"
+msgstr "no s'ha pogut obrir o llegir %s"
#: builtin/apply.c:2754
#, c-format
@@ -2295,13 +2298,13 @@ msgid ""
"while searching for:\n"
"%.*s"
msgstr ""
-"mentre cercant:\n"
+"tot cercant:\n"
"%.*s"
#: builtin/apply.c:2909
#, c-format
msgid "missing binary patch data for '%s'"
-msgstr "manquen els dades de pedaç binari de '%s'"
+msgstr "manquen les dades de pedaç binari de '%s'"
#: builtin/apply.c:3010
#, c-format
@@ -2332,7 +2335,7 @@ msgstr "la lectura de %s ha fallat"
#: builtin/apply.c:3240 builtin/apply.c:3462
#, c-format
msgid "path %s has been renamed/deleted"
-msgstr "la ruta %s s'ha canviat de nom / s'ha suprimit"
+msgstr "el camí %s s'ha canviat de nom / s'ha suprimit"
#: builtin/apply.c:3321 builtin/apply.c:3476
#, c-format
@@ -2351,7 +2354,7 @@ msgstr "%s: no coincideix amb l'índex"
#: builtin/apply.c:3432
msgid "removal patch leaves file contents"
-msgstr "el pedaç de treta deixa els continguts dels fitxers"
+msgstr "el pedaç de supressió deixa els continguts dels fitxers"
#: builtin/apply.c:3501
#, c-format
@@ -2361,7 +2364,7 @@ msgstr "%s: tipus erroni"
#: builtin/apply.c:3503
#, c-format
msgid "%s has type %o, expected %o"
-msgstr "%s és del tipus %o, %o esperat"
+msgstr "%s és del tipus %o, s'esperava %o"
#: builtin/apply.c:3604
#, c-format
@@ -2393,15 +2396,15 @@ msgstr "%s: el pedaç no aplica"
msgid "Checking patch %s..."
msgstr "Comprovant el pedaç %s..."
-#: builtin/apply.c:3746 builtin/checkout.c:213 builtin/reset.c:135
+#: builtin/apply.c:3746 builtin/checkout.c:231 builtin/reset.c:135
#, c-format
msgid "make_cache_entry failed for path '%s'"
-msgstr "make_cache_entry ha fallat per a la ruta '%s'"
+msgstr "make_cache_entry ha fallat per al camí '%s'"
#: builtin/apply.c:3889
#, c-format
msgid "unable to remove %s from index"
-msgstr "incapaç de treure %s de l'índex"
+msgstr "no s'ha pogut eliminar %s de l'índex"
#: builtin/apply.c:3918
#, c-format
@@ -2411,18 +2414,19 @@ msgstr "pedaç corrupte per al submòdul %s"
#: builtin/apply.c:3922
#, c-format
msgid "unable to stat newly created file '%s'"
-msgstr "incapaç de fer stat al fitxer novament creat '%s'"
+msgstr "no s'ha pogut fer stat al fitxer novament creat '%s'"
#: builtin/apply.c:3927
#, c-format
msgid "unable to create backing store for newly created file %s"
msgstr ""
-"incapaç de crear un magatzem de recolzament per al fitxer novament creat %s"
+"no s'ha pogut crear un magatzem de recolzament per al fitxer novament creat "
+"%s"
#: builtin/apply.c:3930 builtin/apply.c:4038
#, c-format
msgid "unable to add cache entry for %s"
-msgstr "incapaç d'afegir una entrada de cau per a %s"
+msgstr "no s'ha pogut afegir una entrada de cau per a %s"
#: builtin/apply.c:3963
#, c-format
@@ -2432,7 +2436,7 @@ msgstr "tancant el fitxer '%s'"
#: builtin/apply.c:4012
#, c-format
msgid "unable to write file '%s' mode %o"
-msgstr "incapaç d'escriure el fitxer '%s' mode %o"
+msgstr "no s'ha pogut escriure el fitxer '%s' mode %o"
#: builtin/apply.c:4099
#, c-format
@@ -2467,24 +2471,24 @@ msgstr "S'ha rebutjat el tros #%d."
#: builtin/apply.c:4234
msgid "unrecognized input"
-msgstr "entrada no reconegut"
+msgstr "entrada no reconeguda"
#: builtin/apply.c:4245
msgid "unable to read index file"
-msgstr "incapaç de llegir el fitxer d'índex"
+msgstr "no es pot llegir el fitxer d'índex"
-#: builtin/apply.c:4362 builtin/apply.c:4365 builtin/clone.c:91
+#: builtin/apply.c:4362 builtin/apply.c:4365 builtin/clone.c:92
#: builtin/fetch.c:93
msgid "path"
-msgstr "ruta"
+msgstr "camí"
#: builtin/apply.c:4363
msgid "don't apply changes matching the given path"
-msgstr "no apliquis els canvis que coincideixin amb la ruta donada"
+msgstr "no apliquis els canvis que coincideixin amb el camí donat"
#: builtin/apply.c:4366
msgid "apply changes matching the given path"
-msgstr "aplica els canvis que coincideixin amb la ruta donada"
+msgstr "aplica els canvis que coincideixin amb el camí donat"
#: builtin/apply.c:4368
msgid "num"
@@ -2493,7 +2497,7 @@ msgstr "número"
#: builtin/apply.c:4369
msgid "remove <num> leading slashes from traditional diff paths"
msgstr ""
-"treu <nombre> barres obliqües inicials de les rutes de diferència "
+"elimina <nombre> barres obliqües inicials dels camins de diferència "
"tradicionals"
#: builtin/apply.c:4372
@@ -2539,11 +2543,11 @@ msgstr "construeix un índex temporal basat en la informació d'índex incrustad
#: builtin/apply.c:4394 builtin/checkout-index.c:198 builtin/ls-files.c:455
msgid "paths are separated with NUL character"
-msgstr "rutes es separen amb el caràcter NUL"
+msgstr "els camins es separen amb el caràcter NUL"
#: builtin/apply.c:4397
msgid "ensure at least <n> lines of context match"
-msgstr "assegura que almenys <n> línies de context coincideixin"
+msgstr "assegura't que almenys <n> línies de context coincideixin"
#: builtin/apply.c:4398
msgid "action"
@@ -2556,7 +2560,7 @@ msgstr ""
#: builtin/apply.c:4402 builtin/apply.c:4405
msgid "ignore changes in whitespace when finding context"
-msgstr "ignora els canvis d'espai en blanc al cercar context"
+msgstr "ignora els canvis d'espai en blanc en cercar context"
#: builtin/apply.c:4408
msgid "apply the patch in reverse"
@@ -2683,7 +2687,8 @@ msgstr "Mostra les entrades de culpa mentre les trobem, incrementalment"
#: builtin/blame.c:2502
msgid "Show blank SHA-1 for boundary commits (Default: off)"
msgstr ""
-"Mostra un SHA-1 blanc peles comissions de frontera (Per defecte: desactivat)"
+"Mostra un SHA-1 en blanc per les comissions de frontera (Per defecte: "
+"desactivat)"
#: builtin/blame.c:2503
msgid "Do not treat root commits as boundaries (Default: off)"
@@ -2743,7 +2748,7 @@ msgstr "Ignora les diferencies d'espai en blanc"
#: builtin/blame.c:2516
msgid "Spend extra cycles to find better match"
-msgstr "Gasta cicles extres per a trobar una coincidència millora"
+msgstr "Gasta cicles extres per a trobar una coincidència millor"
#: builtin/blame.c:2517
msgid "Use revisions from <file> instead of calling git-rev-list"
@@ -2781,7 +2786,7 @@ msgstr "Processa només el rang de línies n,m, comptant des de 1"
#. fewer display columns.
#: builtin/blame.c:2602
msgid "4 years, 11 months ago"
-msgstr "fa 4 anys, 11 mesos"
+msgstr "fa 4 anys i 11 mesos"
#: builtin/branch.c:24
msgid "git branch [options] [-r | -a] [--merged | --no-merged]"
@@ -2789,15 +2794,15 @@ msgstr "git branch [opcions] [-r | -a] [--merged | --no-merged]"
#: builtin/branch.c:25
msgid "git branch [options] [-l] [-f] <branchname> [<start-point>]"
-msgstr "git branch [opcions] [-l] [-f] <nom-de-rama> [<punt-inicial>]"
+msgstr "git branch [opcions] [-l] [-f] <nom-de-branca> [<punt-inicial>]"
#: builtin/branch.c:26
msgid "git branch [options] [-r] (-d | -D) <branchname>..."
-msgstr "git branch [opcions] [-r] (-d | -D) <nom-de-rama>..."
+msgstr "git branch [opcions] [-r] (-d | -D) <nom-de-branca>..."
#: builtin/branch.c:27
msgid "git branch [options] (-m | -M) [<oldbranch>] <newbranch>"
-msgstr "git branch [opcions] (-m | -M) [<rama-antiga>] <rama-nova>"
+msgstr "git branch [opcions] (-m | -M) [<branca-antiga>] <branca-nova>"
#: builtin/branch.c:152
#, c-format
@@ -2805,7 +2810,7 @@ msgid ""
"deleting branch '%s' that has been merged to\n"
" '%s', but not yet merged to HEAD."
msgstr ""
-"suprimint la rama '%s' que s'ha fusionat a\n"
+"suprimint la branca '%s' que s'ha fusionat a\n"
" '%s', però encara no s'ha fusionat\n"
" a HEAD."
@@ -2815,9 +2820,9 @@ msgid ""
"not deleting branch '%s' that is not yet merged to\n"
" '%s', even though it is merged to HEAD."
msgstr ""
-"no suprimint la rama '%s' que encara no s'ha\n"
-" fusionat a '%s', encara que està fusionat\n"
-" a HEAD."
+"no suprimint la branca '%s' que encara no s'ha\n"
+" fusionat a '%s', encara que està\n"
+" fusionada a HEAD."
#: builtin/branch.c:170
#, c-format
@@ -2830,7 +2835,7 @@ msgid ""
"The branch '%s' is not fully merged.\n"
"If you are sure you want to delete it, run 'git branch -D %s'."
msgstr ""
-"La rama '%s' no està totalment fusionada.\n"
+"La branca '%s' no està totalment fusionada.\n"
"Si esteu segur que la voleu suprimir, executeu 'git branch -D %s'."
#: builtin/branch.c:187
@@ -2848,47 +2853,47 @@ msgstr "No s'ha pogut trobar l'objecte de comissió de HEAD"
#: builtin/branch.c:229
#, c-format
msgid "Cannot delete the branch '%s' which you are currently on."
-msgstr "No es pot suprimir la rama '%s' en que esteu actualment."
+msgstr "No es pot suprimir la branca '%s', en la qual sou actualment."
#: builtin/branch.c:245
#, c-format
msgid "remote branch '%s' not found."
-msgstr "no s'ha trobat la rama remota '%s'."
+msgstr "no s'ha trobat la branca remota '%s'."
#: builtin/branch.c:246
#, c-format
msgid "branch '%s' not found."
-msgstr "no s'ha trobat la rama '%s'."
+msgstr "no s'ha trobat la branca '%s'."
#: builtin/branch.c:260
#, c-format
msgid "Error deleting remote branch '%s'"
-msgstr "Error en suprimir la rama remota '%s'"
+msgstr "Error en suprimir la branca remota '%s'"
#: builtin/branch.c:261
#, c-format
msgid "Error deleting branch '%s'"
-msgstr "Error en suprimir la rama '%s'"
+msgstr "Error en suprimir la branca '%s'"
#: builtin/branch.c:268
#, c-format
msgid "Deleted remote branch %s (was %s).\n"
-msgstr "S'ha suprimit la rama remota %s (ha estat %s).\n"
+msgstr "S'ha suprimit la branca remota %s (ha estat %s).\n"
#: builtin/branch.c:269
#, c-format
msgid "Deleted branch %s (was %s).\n"
-msgstr "S'ha suprimit la rama %s (ha estat %s).\n"
+msgstr "S'ha suprimit la branca %s (ha estat %s).\n"
#: builtin/branch.c:370
#, c-format
msgid "branch '%s' does not point at a commit"
-msgstr "la rama '%s' no assenyala una comissió"
+msgstr "la branca '%s' no assenyala cap comissió"
#: builtin/branch.c:459
#, c-format
msgid "[%s: gone]"
-msgstr "[%s: no és]"
+msgstr "[%s: no hi és]"
#: builtin/branch.c:464
#, c-format
@@ -2927,17 +2932,17 @@ msgstr "[davant %d, darrere %d]"
#: builtin/branch.c:496
msgid " **** invalid ref ****"
-msgstr " **** referència invàlida ****"
+msgstr " **** referència no vàlida ****"
#: builtin/branch.c:587
#, c-format
msgid "(no branch, rebasing %s)"
-msgstr "(cap rama, rebasant %s)"
+msgstr "(cap branca, rebasant %s)"
#: builtin/branch.c:590
#, c-format
msgid "(no branch, bisect started on %s)"
-msgstr "(cap rama, bisecció començada en %s)"
+msgstr "(cap branca, bisecció començada en %s)"
#: builtin/branch.c:593
#, c-format
@@ -2946,7 +2951,7 @@ msgstr "(separat de %s)"
#: builtin/branch.c:596
msgid "(no branch)"
-msgstr "(cap rama)"
+msgstr "(cap branca)"
#: builtin/branch.c:643
#, c-format
@@ -2959,43 +2964,42 @@ msgstr "no s'han pogut llegir algunes referències"
#: builtin/branch.c:704
msgid "cannot rename the current branch while not on any."
-msgstr ""
-"no es pot canviar el nom de la rama actual mentre no estant en ninguna."
+msgstr "no es pot canviar el nom de la branca actual mentre no s'és a cap."
#: builtin/branch.c:714
#, c-format
msgid "Invalid branch name: '%s'"
-msgstr "Nom de rama invàlid: '%s'"
+msgstr "Nom de branca no vàlid: '%s'"
#: builtin/branch.c:729
msgid "Branch rename failed"
-msgstr "El canvi de nom de rama ha fallat"
+msgstr "El canvi de nom de branca ha fallat"
#: builtin/branch.c:733
#, c-format
msgid "Renamed a misnamed branch '%s' away"
-msgstr "S'ha canviat el nom de la rama malanomenada '%s'"
+msgstr "S'ha canviat el nom de la branca malanomenada '%s'"
#: builtin/branch.c:737
#, c-format
msgid "Branch renamed to %s, but HEAD is not updated!"
-msgstr "S'ha canviat el nom de la rama a %s, però HEAD no està actualitzat!"
+msgstr "S'ha canviat el nom de la branca a %s, però HEAD no està actualitzat!"
#: builtin/branch.c:744
msgid "Branch is renamed, but update of config-file failed"
msgstr ""
-"La ramà està canviada de nom, però l'actualització del fitxer de "
+"La branca està canviada de nom, però l'actualització del fitxer de "
"configuració ha fallat"
#: builtin/branch.c:759
#, c-format
msgid "malformed object name %s"
-msgstr "nom d'objecte %s malformat"
+msgstr "nom d'objecte %s mal format"
#: builtin/branch.c:783
#, c-format
msgid "could not write branch description template: %s"
-msgstr "no s'ha pogut escriure la plantilla de descripció de rama: %s"
+msgstr "no s'ha pogut escriure la plantilla de descripció de branca: %s"
#: builtin/branch.c:813
msgid "Generic options"
@@ -3003,7 +3007,7 @@ msgstr "Opcions genèriques"
#: builtin/branch.c:815
msgid "show hash and subject, give twice for upstream branch"
-msgstr "mostra el hash i el tema, doneu dos vegades per la rama font"
+msgstr "mostra el hash i el tema, doneu dues vegades per la branca font"
#: builtin/branch.c:816
msgid "suppress informational messages"
@@ -3011,7 +3015,7 @@ msgstr "omet els missatges informatius"
#: builtin/branch.c:817
msgid "set up tracking mode (see git-pull(1))"
-msgstr "configura el mode de seguiment (veu git-pull(1))"
+msgstr "configura el mode de seguiment (vegeu git-pull(1))"
#: builtin/branch.c:819
msgid "change upstream info"
@@ -3023,18 +3027,18 @@ msgstr "usa sortida colorada"
#: builtin/branch.c:824
msgid "act on remote-tracking branches"
-msgstr "actua en rames amb seguiment remot"
+msgstr "actua en branques amb seguiment remot"
#: builtin/branch.c:827 builtin/branch.c:833 builtin/branch.c:854
-#: builtin/branch.c:860 builtin/commit.c:1622 builtin/commit.c:1623
-#: builtin/commit.c:1624 builtin/commit.c:1625 builtin/tag.c:616
+#: builtin/branch.c:860 builtin/commit.c:1586 builtin/commit.c:1587
+#: builtin/commit.c:1588 builtin/commit.c:1589 builtin/tag.c:616
#: builtin/tag.c:622
msgid "commit"
msgstr "comissió"
#: builtin/branch.c:828 builtin/branch.c:834
msgid "print only branches that contain the commit"
-msgstr "imprimeix només les rames que continguin la comissió"
+msgstr "imprimeix només les branques que continguin la comissió"
#: builtin/branch.c:840
msgid "Specific git-branch actions:"
@@ -3042,142 +3046,144 @@ msgstr "Accions de git-branch específiques:"
#: builtin/branch.c:841
msgid "list both remote-tracking and local branches"
-msgstr "llista ambdós les rames amb seguiment remot i les locals"
+msgstr "llista les branques amb seguiment remot i les locals"
#: builtin/branch.c:843
msgid "delete fully merged branch"
-msgstr "suprimeix la rama si és completament fusionada"
+msgstr "suprimeix la branca si és completament fusionada"
#: builtin/branch.c:844
msgid "delete branch (even if not merged)"
-msgstr "suprimeix la rama (encara que no estigui fusionada)"
+msgstr "suprimeix la branca (encara que no estigui fusionada)"
#: builtin/branch.c:845
msgid "move/rename a branch and its reflog"
-msgstr "mou/canvia de nom una rama i el seu registre de referència"
+msgstr "mou/canvia de nom una branca i el seu registre de referència"
#: builtin/branch.c:846
msgid "move/rename a branch, even if target exists"
-msgstr "mou/canvia de nom una rama, encara que el destí existeixi"
+msgstr "mou/canvia de nom una branca, encara que el destí existeixi"
#: builtin/branch.c:847
msgid "list branch names"
-msgstr "llista els noms de rama"
+msgstr "llista els noms de branca"
#: builtin/branch.c:848
msgid "create the branch's reflog"
-msgstr "crea el registre de referència de la rama"
+msgstr "crea el registre de referència de la branca"
#: builtin/branch.c:850
msgid "edit the description for the branch"
-msgstr "edita la descripció de la rama"
+msgstr "edita la descripció de la branca"
#: builtin/branch.c:851
-msgid "force creation (when already exists)"
-msgstr "força creació (quan ja existeix)"
+msgid "force creation, move/rename, deletion"
+msgstr "força creació, moviment/canvi de nom, supressió"
#: builtin/branch.c:854
msgid "print only not merged branches"
-msgstr "imprimeix només les rames sense fusionar"
+msgstr "imprimeix només les branques sense fusionar"
#: builtin/branch.c:860
msgid "print only merged branches"
-msgstr "imprimeix només les rames fusionades"
+msgstr "imprimeix només les branques fusionades"
#: builtin/branch.c:864
msgid "list branches in columns"
-msgstr "llista les rames en columnes"
+msgstr "llista les branques en columnes"
#: builtin/branch.c:877
msgid "Failed to resolve HEAD as a valid ref."
msgstr "S'ha fallat en resoldre HEAD com a referència vàlida."
-#: builtin/branch.c:881 builtin/clone.c:634
+#: builtin/branch.c:881 builtin/clone.c:637
msgid "HEAD not found below refs/heads!"
-msgstr "HEAD no trobat baix refs/heads!"
+msgstr "HEAD no trobat sota refs/heads!"
#: builtin/branch.c:903
msgid "--column and --verbose are incompatible"
msgstr "--column i --verbose són incompatibles"
-#: builtin/branch.c:909 builtin/branch.c:948
+#: builtin/branch.c:914 builtin/branch.c:953
msgid "branch name required"
-msgstr "cal el nom de rama"
+msgstr "cal el nom de branca"
-#: builtin/branch.c:924
+#: builtin/branch.c:929
msgid "Cannot give description to detached HEAD"
msgstr "No es pot donar descripció a un HEAD separat"
-#: builtin/branch.c:929
+#: builtin/branch.c:934
msgid "cannot edit description of more than one branch"
-msgstr "no es pot editar la descripció de més d'una rama"
+msgstr "no es pot editar la descripció de més d'una branca"
-#: builtin/branch.c:936
+#: builtin/branch.c:941
#, c-format
msgid "No commit on branch '%s' yet."
-msgstr "Encara no hi ha comissió en la rama '%s'."
+msgstr "Encara no hi ha comissió en la branca '%s'."
-#: builtin/branch.c:939
+#: builtin/branch.c:944
#, c-format
msgid "No branch named '%s'."
-msgstr "No hi ha rama amb nom '%s'."
+msgstr "No hi ha branca amb nom '%s'."
-#: builtin/branch.c:954
+#: builtin/branch.c:959
msgid "too many branches for a rename operation"
-msgstr "hi ha massa rames per a una operació de canvi de nom"
+msgstr "hi ha massa branques per a una operació de canvi de nom"
-#: builtin/branch.c:959
+#: builtin/branch.c:964
msgid "too many branches to set new upstream"
-msgstr "hi ha massa rames per a establir una nova font"
+msgstr "hi ha massa branques per a establir una nova font"
-#: builtin/branch.c:963
+#: builtin/branch.c:968
#, c-format
msgid ""
"could not set upstream of HEAD to %s when it does not point to any branch."
msgstr ""
-"no s'ha pogut establir la font de HEAD com a %s quan no assenyala cap rama."
+"no s'ha pogut establir la font de HEAD com a %s quan no assenyala cap branca."
-#: builtin/branch.c:966 builtin/branch.c:988 builtin/branch.c:1009
+#: builtin/branch.c:971 builtin/branch.c:993 builtin/branch.c:1014
#, c-format
msgid "no such branch '%s'"
-msgstr "no hi ha tal rama '%s'"
+msgstr "no hi ha tal branca '%s'"
-#: builtin/branch.c:970
+#: builtin/branch.c:975
#, c-format
msgid "branch '%s' does not exist"
-msgstr "la rama '%s' no existeix"
+msgstr "la branca '%s' no existeix"
-#: builtin/branch.c:982
+#: builtin/branch.c:987
msgid "too many branches to unset upstream"
-msgstr "hi ha massa rames per a desestablir la font"
+msgstr "hi ha massa branques per a desestablir la font"
-#: builtin/branch.c:986
+#: builtin/branch.c:991
msgid "could not unset upstream of HEAD when it does not point to any branch."
-msgstr "no s'ha pogut desestablir la font de HEAD quan no assenyala cap rama."
+msgstr ""
+"no s'ha pogut desestablir la font de HEAD perquè no assenyala cap branca."
-#: builtin/branch.c:992
+#: builtin/branch.c:997
#, c-format
msgid "Branch '%s' has no upstream information"
-msgstr "La rama '%s' no té informació de font"
+msgstr "La branca '%s' no té informació de font"
-#: builtin/branch.c:1006
+#: builtin/branch.c:1011
msgid "it does not make sense to create 'HEAD' manually"
msgstr "no té sentit crear 'HEAD' manualment"
-#: builtin/branch.c:1012
+#: builtin/branch.c:1017
msgid "-a and -r options to 'git branch' do not make sense with a branch name"
-msgstr "les opcions -a i -r a 'git branch' no tenen sentit amb un nom de rama"
+msgstr ""
+"les opcions -a i -r a 'git branch' no tenen sentit amb un nom de branca"
-#: builtin/branch.c:1015
+#: builtin/branch.c:1020
#, c-format
msgid ""
"The --set-upstream flag is deprecated and will be removed. Consider using --"
"track or --set-upstream-to\n"
msgstr ""
-"La bandera --set-upstream està desaprovada i es traurà. Considereu usar --"
+"La bandera --set-upstream està desaprovada i s'eliminarà. Considereu usar --"
"track o --set-upstream-to\n"
-#: builtin/branch.c:1032
+#: builtin/branch.c:1037
#, c-format
msgid ""
"\n"
@@ -3188,12 +3194,12 @@ msgstr ""
"Si volíeu fer '%s' seguir '%s', feu això:\n"
"\n"
-#: builtin/branch.c:1033
+#: builtin/branch.c:1038
#, c-format
msgid " git branch -d %s\n"
msgstr " git branch -d %s\n"
-#: builtin/branch.c:1034
+#: builtin/branch.c:1039
#, c-format
msgid " git branch --set-upstream-to %s\n"
msgstr " git branch --set-upstream-to %s\n"
@@ -3205,61 +3211,61 @@ msgstr "%s està bé\n"
#: builtin/bundle.c:56
msgid "Need a repository to create a bundle."
-msgstr "Cal un dipòsit per a fer un embolic."
+msgstr "Cal un dipòsit per a fer un farcell."
#: builtin/bundle.c:60
msgid "Need a repository to unbundle."
-msgstr "Cal un dipòsit per a desembolicar."
+msgstr "Cal un dipòsit per a desfer un farcell."
-#: builtin/cat-file.c:332
+#: builtin/cat-file.c:328
msgid "git cat-file (-t|-s|-e|-p|<type>|--textconv) <object>"
msgstr "git cat-file (-t|-s|-e|-p|<tipus>|--textconv) <objecte>"
-#: builtin/cat-file.c:333
+#: builtin/cat-file.c:329
msgid "git cat-file (--batch|--batch-check) < <list_of_objects>"
msgstr "git cat-file (--batch|--batch-check) < <llista_de_objectes>"
-#: builtin/cat-file.c:370
+#: builtin/cat-file.c:366
msgid "<type> can be one of: blob, tree, commit, tag"
msgstr "<tipus> pot ser un de: blob, tree, commit, tag"
-#: builtin/cat-file.c:371
+#: builtin/cat-file.c:367
msgid "show object type"
msgstr "mostra el tipus de l'objecte"
-#: builtin/cat-file.c:372
+#: builtin/cat-file.c:368
msgid "show object size"
msgstr "mostra la mida de l'objecte"
-#: builtin/cat-file.c:374
+#: builtin/cat-file.c:370
msgid "exit with zero when there's no error"
msgstr "surt amb zero quan no hi ha error"
-#: builtin/cat-file.c:375
+#: builtin/cat-file.c:371
msgid "pretty-print object's content"
-msgstr "imprimeix bellament el contingut de l'objecte "
+msgstr "imprimeix bellament el contingut de l'objecte"
-#: builtin/cat-file.c:377
+#: builtin/cat-file.c:373
msgid "for blob objects, run textconv on object's content"
msgstr "en els objectes de blob, executa textconv en el contingut de l'objecte"
-#: builtin/cat-file.c:379
+#: builtin/cat-file.c:375
msgid "show info and content of objects fed from the standard input"
msgstr ""
"mostra la informació i contingut dels objectes rebuts de l'entrada estàndard"
-#: builtin/cat-file.c:382
+#: builtin/cat-file.c:378
msgid "show info about objects fed from the standard input"
msgstr "mostra informació sobre els objectes rebuts de l'entrada estàndard"
#: builtin/check-attr.c:11
msgid "git check-attr [-a | --all | attr...] [--] pathname..."
-msgstr "git check-attr [-a | --all | atribut...] [--] nom-de-ruta..."
+msgstr "git check-attr [-a | --all | atribut...] [--] nom-de-camí..."
#: builtin/check-attr.c:12
msgid "git check-attr --stdin [-z] [-a | --all | attr...] < <list-of-paths>"
msgstr ""
-"git check-attr --stdin [-z] [-a | --all | atribut...] < <llista-de-rutes>"
+"git check-attr --stdin [-z] [-a | --all | atribut...] < <llista-de-camins>"
#: builtin/check-attr.c:19
msgid "report all attributes set on file"
@@ -3275,23 +3281,23 @@ msgstr "llegeix els noms de fitxer d'stdin"
#: builtin/check-attr.c:23 builtin/check-ignore.c:24
msgid "terminate input and output records by a NUL character"
-msgstr "termina els registres d'entrada i de salida per un caràcter NUL"
+msgstr "acaba els registres d'entrada i de sortida amb un caràcter NUL"
-#: builtin/check-ignore.c:18 builtin/checkout.c:1089 builtin/gc.c:274
+#: builtin/check-ignore.c:18 builtin/checkout.c:1107 builtin/gc.c:274
msgid "suppress progress reporting"
msgstr "omet el reportatge de progrés"
#: builtin/check-ignore.c:26
msgid "show non-matching input paths"
-msgstr "mostra les rutes d'entrada que no coincideixin"
+msgstr "mostra els camins d'entrada que no coincideixin"
#: builtin/check-ignore.c:28
msgid "ignore index when checking"
-msgstr "ignora l'índex al comprovar"
+msgstr "ignora l'índex en comprovar"
#: builtin/check-ignore.c:154
msgid "cannot specify pathnames with --stdin"
-msgstr "no es pot especificar noms de ruta amb --stdin"
+msgstr "no es pot especificar noms de camí amb --stdin"
#: builtin/check-ignore.c:157
msgid "-z only makes sense with --stdin"
@@ -3299,11 +3305,11 @@ msgstr "-z només té sentit amb --stdin"
#: builtin/check-ignore.c:159
msgid "no path specified"
-msgstr "cap ruta especificada"
+msgstr "cap camí especificat"
#: builtin/check-ignore.c:163
msgid "--quiet is only valid with a single pathname"
-msgstr "--quiet només és vàlid amb un nom de ruta solter"
+msgstr "--quiet només és vàlid amb un sol nom de camí"
#: builtin/check-ignore.c:165
msgid "cannot have both --quiet and --verbose"
@@ -3324,7 +3330,7 @@ msgstr "també llegeix els contactes des d'stdin"
#: builtin/check-mailmap.c:24
#, c-format
msgid "unable to parse contact: %s"
-msgstr "incapaç d'analitzar el contacte: %s"
+msgstr "no s'ha pogut analitzar el contacte: %s"
#: builtin/check-mailmap.c:47
msgid "no contacts specified"
@@ -3356,7 +3362,7 @@ msgstr "actualitza la informació d'estadístiques en el fitxer d'índex"
#: builtin/checkout-index.c:201
msgid "read list of paths from the standard input"
-msgstr "llegeix la llista de rutes des de l'entrada estàndard"
+msgstr "llegeix la llista de camins des de l'entrada estàndard"
#: builtin/checkout-index.c:203
msgid "write the content to temporary files"
@@ -3368,7 +3374,7 @@ msgstr "cadena"
#: builtin/checkout-index.c:205
msgid "when creating files, prepend <string>"
-msgstr "al crear fitxers, anteposa <cadena>"
+msgstr "en crear fitxers, anteposa <cadena>"
#: builtin/checkout-index.c:208
msgid "copy out the files from named stage"
@@ -3376,111 +3382,112 @@ msgstr "copia els fitxers des de l'etapa anomenada"
#: builtin/checkout.c:25
msgid "git checkout [options] <branch>"
-msgstr "git checkout [opcions] <rama>"
+msgstr "git checkout [opcions] <branca>"
#: builtin/checkout.c:26
msgid "git checkout [options] [<branch>] -- <file>..."
-msgstr "git checkout [opcions] [<rama>] -- <fitxer>..."
+msgstr "git checkout [opcions] [<branca>] -- <fitxer>..."
-#: builtin/checkout.c:114 builtin/checkout.c:147
+#: builtin/checkout.c:132 builtin/checkout.c:165
#, c-format
msgid "path '%s' does not have our version"
-msgstr "la ruta '%s' no té la versió nostra"
+msgstr "el camí '%s' no té la versió nostra"
-#: builtin/checkout.c:116 builtin/checkout.c:149
+#: builtin/checkout.c:134 builtin/checkout.c:167
#, c-format
msgid "path '%s' does not have their version"
-msgstr "la ruta '%s' no té la versió seva"
+msgstr "el camí '%s' no té la versió seva"
-#: builtin/checkout.c:132
+#: builtin/checkout.c:150
#, c-format
msgid "path '%s' does not have all necessary versions"
-msgstr "la ruta '%s' no té totes les versions necessàries"
+msgstr "el camí '%s' no té totes les versions necessàries"
-#: builtin/checkout.c:176
+#: builtin/checkout.c:194
#, c-format
msgid "path '%s' does not have necessary versions"
-msgstr "la ruta '%s' no té les versions necessàries"
+msgstr "el camí '%s' no té les versions necessàries"
-#: builtin/checkout.c:193
+#: builtin/checkout.c:211
#, c-format
msgid "path '%s': cannot merge"
-msgstr "ruta '%s': no es pot fusionar"
+msgstr "camí '%s': no es pot fusionar"
-#: builtin/checkout.c:210
+#: builtin/checkout.c:228
#, c-format
msgid "Unable to add merge result for '%s'"
-msgstr "Incapaç d'afegir el resultat de fusió per a '%s'"
+msgstr "no s'ha pogut afegir el resultat de fusió per a '%s'"
-#: builtin/checkout.c:231 builtin/checkout.c:234 builtin/checkout.c:237
-#: builtin/checkout.c:240
+#: builtin/checkout.c:249 builtin/checkout.c:252 builtin/checkout.c:255
+#: builtin/checkout.c:258
#, c-format
msgid "'%s' cannot be used with updating paths"
-msgstr "'%s' no es pot usar amb actualització de rutes"
+msgstr "'%s' no es pot usar amb actualització de camins"
-#: builtin/checkout.c:243 builtin/checkout.c:246
+#: builtin/checkout.c:261 builtin/checkout.c:264
#, c-format
msgid "'%s' cannot be used with %s"
msgstr "'%s' no es pot usar amb %s"
-#: builtin/checkout.c:249
+#: builtin/checkout.c:267
#, c-format
msgid "Cannot update paths and switch to branch '%s' at the same time."
-msgstr "No es pot actualitzar les rutes i canviar a la rama '%s' a la vegada."
+msgstr ""
+"No es pot actualitzar els camins i canviar a la branca '%s' a la vegada."
-#: builtin/checkout.c:260 builtin/checkout.c:449
+#: builtin/checkout.c:278 builtin/checkout.c:467
msgid "corrupt index file"
msgstr "fitxer d'índex corrupte"
-#: builtin/checkout.c:320 builtin/checkout.c:327
+#: builtin/checkout.c:338 builtin/checkout.c:345
#, c-format
msgid "path '%s' is unmerged"
-msgstr "la ruta '%s' està sense fusionar"
+msgstr "el camí '%s' està sense fusionar"
-#: builtin/checkout.c:471
+#: builtin/checkout.c:489
msgid "you need to resolve your current index first"
msgstr "heu de resoldre el vostre índex actual primer"
-#: builtin/checkout.c:597
+#: builtin/checkout.c:615
#, c-format
msgid "Can not do reflog for '%s'\n"
msgstr "No es pot fer reflog per a '%s'\n"
-#: builtin/checkout.c:635
+#: builtin/checkout.c:653
msgid "HEAD is now at"
-msgstr "HEAD ara està a"
+msgstr "HEAD ara és a"
-#: builtin/checkout.c:642
+#: builtin/checkout.c:660
#, c-format
msgid "Reset branch '%s'\n"
-msgstr "Restableix la rama '%s'\n"
+msgstr "Restableix la branca '%s'\n"
-#: builtin/checkout.c:645
+#: builtin/checkout.c:663
#, c-format
msgid "Already on '%s'\n"
msgstr "Ja en '%s'\n"
-#: builtin/checkout.c:649
+#: builtin/checkout.c:667
#, c-format
msgid "Switched to and reset branch '%s'\n"
-msgstr "S'ha agafat i restablert la rama '%s'\n"
+msgstr "S'ha agafat i restablert la branca '%s'\n"
-#: builtin/checkout.c:651 builtin/checkout.c:1032
+#: builtin/checkout.c:669 builtin/checkout.c:1050
#, c-format
msgid "Switched to a new branch '%s'\n"
-msgstr "S'ha agafat la rama nova '%s'\n"
+msgstr "S'ha agafat la branca nova '%s'\n"
-#: builtin/checkout.c:653
+#: builtin/checkout.c:671
#, c-format
msgid "Switched to branch '%s'\n"
-msgstr "S'ha agafat la rama '%s'\n"
+msgstr "S'ha agafat la branca '%s'\n"
-#: builtin/checkout.c:705
+#: builtin/checkout.c:723
#, c-format
msgid " ... and %d more.\n"
msgstr " ... i %d més.\n"
-#: builtin/checkout.c:711
+#: builtin/checkout.c:729
#, c-format
msgid ""
"Warning: you are leaving %d commit behind, not connected to\n"
@@ -3493,17 +3500,17 @@ msgid_plural ""
"\n"
"%s\n"
msgstr[0] ""
-"Avís: esteu deixant %d comissió darrere, no connectada a\n"
-"qualsevulla de les vostres rames:\n"
+"Avís: esteu deixant enrere %d comissió, no connectada a\n"
+"cap de les vostres branques:\n"
"\n"
"%s\n"
msgstr[1] ""
-"Avís: esteu deixant %d comissions darrere, no connectada a\n"
-"qualsevulla de les vostres rames:\n"
+"Avís: esteu deixant enrere %d comissions, no connectades a\n"
+"cap de les vostres branques:\n"
"\n"
"%s\n"
-#: builtin/checkout.c:729
+#: builtin/checkout.c:747
#, c-format
msgid ""
"If you want to keep them by creating a new branch, this may be a good time\n"
@@ -3512,181 +3519,181 @@ msgid ""
" git branch new_branch_name %s\n"
"\n"
msgstr ""
-"Si els voleu retenir per a crear una rama nova, ara pot ser una hora bona\n"
-"per a fer això amb:\n"
+"Si els voleu retenir per a crear una branca nova, ara pot ser un bon moment\n"
+"per a fer-ho amb:\n"
"\n"
-" git branch new_branch_name %s\n"
+" git branch nom_de_branca_nova %s\n"
"\n"
-#: builtin/checkout.c:759
+#: builtin/checkout.c:777
msgid "internal error in revision walk"
msgstr "error intern en el passeig per revisions"
-#: builtin/checkout.c:763
+#: builtin/checkout.c:781
msgid "Previous HEAD position was"
-msgstr "La posició de HEAD anterior ha estat"
+msgstr "La posició de HEAD anterior era"
-#: builtin/checkout.c:790 builtin/checkout.c:1027
+#: builtin/checkout.c:808 builtin/checkout.c:1045
msgid "You are on a branch yet to be born"
-msgstr "Esteu en una rama que encara ha de nàixer"
+msgstr "Sou en una branca que encara ha de nàixer"
-#: builtin/checkout.c:934
+#: builtin/checkout.c:952
#, c-format
msgid "only one reference expected, %d given."
msgstr "només una referència esperada, %d donades."
-#: builtin/checkout.c:973
+#: builtin/checkout.c:991
#, c-format
msgid "invalid reference: %s"
-msgstr "referència invàlida: %s"
+msgstr "referència no vàlida: %s"
-#: builtin/checkout.c:1002
+#: builtin/checkout.c:1020
#, c-format
msgid "reference is not a tree: %s"
-msgstr "la referéncia no és un arbre: %s"
+msgstr "la referència no és un arbre: %s"
-#: builtin/checkout.c:1041
+#: builtin/checkout.c:1059
msgid "paths cannot be used with switching branches"
-msgstr "les rutes no es poden usar amb canvi de rama"
+msgstr "els camins no es poden usar amb canvi de branca"
-#: builtin/checkout.c:1044 builtin/checkout.c:1048
+#: builtin/checkout.c:1062 builtin/checkout.c:1066
#, c-format
msgid "'%s' cannot be used with switching branches"
-msgstr "'%s' no es pot usar amb canvi de rama"
+msgstr "'%s' no es pot usar amb canvi de branca"
-#: builtin/checkout.c:1052 builtin/checkout.c:1055 builtin/checkout.c:1060
-#: builtin/checkout.c:1063
+#: builtin/checkout.c:1070 builtin/checkout.c:1073 builtin/checkout.c:1078
+#: builtin/checkout.c:1081
#, c-format
msgid "'%s' cannot be used with '%s'"
msgstr "'%s' no es pot usar amb '%s'"
-#: builtin/checkout.c:1068
+#: builtin/checkout.c:1086
#, c-format
msgid "Cannot switch branch to a non-commit '%s'"
-msgstr "No es pot canviar la rama a un no comissió '%s'"
+msgstr "No es pot canviar la branca a una no comissió '%s'"
-#: builtin/checkout.c:1090 builtin/checkout.c:1092 builtin/clone.c:89
+#: builtin/checkout.c:1108 builtin/checkout.c:1110 builtin/clone.c:90
#: builtin/remote.c:159 builtin/remote.c:161
msgid "branch"
-msgstr "rama"
+msgstr "branca"
-#: builtin/checkout.c:1091
+#: builtin/checkout.c:1109
msgid "create and checkout a new branch"
-msgstr "crea i agafa una rama nova"
+msgstr "crea i agafa una branca nova"
-#: builtin/checkout.c:1093
+#: builtin/checkout.c:1111
msgid "create/reset and checkout a branch"
-msgstr "crea/restableix i agafa una rama"
+msgstr "crea/restableix i agafa una branca"
-#: builtin/checkout.c:1094
+#: builtin/checkout.c:1112
msgid "create reflog for new branch"
-msgstr "crea un registre de referència per a la rama nova"
+msgstr "crea un registre de referència per a la branca nova"
-#: builtin/checkout.c:1095
+#: builtin/checkout.c:1113
msgid "detach the HEAD at named commit"
msgstr "separa el HEAD a la comissió anomenada"
-#: builtin/checkout.c:1096
+#: builtin/checkout.c:1114
msgid "set upstream info for new branch"
-msgstr "estableix la informació de font de la rama nova"
+msgstr "estableix la informació de font de la branca nova"
-#: builtin/checkout.c:1098
+#: builtin/checkout.c:1116
msgid "new-branch"
-msgstr "rama-nova"
+msgstr "branca-nova"
-#: builtin/checkout.c:1098
+#: builtin/checkout.c:1116
msgid "new unparented branch"
-msgstr "rama nova sense pares"
+msgstr "branca nova sense mare"
-#: builtin/checkout.c:1099
+#: builtin/checkout.c:1117
msgid "checkout our version for unmerged files"
msgstr "agafa la versió nostra dels fitxers sense fusionar"
-#: builtin/checkout.c:1101
+#: builtin/checkout.c:1119
msgid "checkout their version for unmerged files"
msgstr "agafa la versió seva dels fitxers sense fusionar"
-#: builtin/checkout.c:1103
+#: builtin/checkout.c:1121
msgid "force checkout (throw away local modifications)"
msgstr "agafa a la força (descarta qualsevulles modificacions locals)"
-#: builtin/checkout.c:1104
+#: builtin/checkout.c:1122
msgid "perform a 3-way merge with the new branch"
-msgstr "realitza una fusió de 3 vies amb la rama nova"
+msgstr "realitza una fusió de 3 vies amb la branca nova"
-#: builtin/checkout.c:1105 builtin/merge.c:226
+#: builtin/checkout.c:1123 builtin/merge.c:227
msgid "update ignored files (default)"
msgstr "actualitza els fitxers ignorats (per defecte)"
-#: builtin/checkout.c:1106 builtin/log.c:1239 parse-options.h:245
+#: builtin/checkout.c:1124 builtin/log.c:1239 parse-options.h:245
msgid "style"
msgstr "estil"
-#: builtin/checkout.c:1107
+#: builtin/checkout.c:1125
msgid "conflict style (merge or diff3)"
msgstr "estil de conflicte (fusió o diff3)"
-#: builtin/checkout.c:1110
+#: builtin/checkout.c:1128
msgid "do not limit pathspecs to sparse entries only"
-msgstr "no limitis les especificacions de ruta a entrades escasses només"
+msgstr "no limitis les especificacions de camí només a entrades escasses"
-#: builtin/checkout.c:1112
+#: builtin/checkout.c:1130
msgid "second guess 'git checkout no-such-branch'"
-msgstr "dubta 'git checkout cap-rama-així'"
+msgstr "dubta 'git checkout cap-branca-així'"
-#: builtin/checkout.c:1135
+#: builtin/checkout.c:1153
msgid "-b, -B and --orphan are mutually exclusive"
msgstr "-b, -B i --orphan són mutualment exclusius"
-#: builtin/checkout.c:1152
+#: builtin/checkout.c:1170
msgid "--track needs a branch name"
-msgstr "--track necessita un nom de rama"
+msgstr "--track necessita un nom de branca"
-#: builtin/checkout.c:1157
+#: builtin/checkout.c:1175
msgid "Missing branch name; try -b"
-msgstr "Manca el nom de rama; proveu -b"
+msgstr "Manca el nom de branca; proveu -b"
-#: builtin/checkout.c:1194
+#: builtin/checkout.c:1212
msgid "invalid path specification"
-msgstr "especificació de ruta invàlida"
+msgstr "especificació de camí no vàlida"
-#: builtin/checkout.c:1201
+#: builtin/checkout.c:1219
#, c-format
msgid ""
"Cannot update paths and switch to branch '%s' at the same time.\n"
"Did you intend to checkout '%s' which can not be resolved as commit?"
msgstr ""
-"No es pot actualitzar rames i canviar a la rama '%s' a la vegada.\n"
-"Volíeu agafar '%s' la qual no es pot resoldre com a comissió?"
+"No es poden actualitzar els camins i canviar a la branca '%s' a la vegada.\n"
+"Volíeu agafar '%s', la qual no es pot resoldre com a comissió?"
-#: builtin/checkout.c:1206
+#: builtin/checkout.c:1224
#, c-format
msgid "git checkout: --detach does not take a path argument '%s'"
-msgstr "git checkout: --detach no accepta un paràmetre de ruta '%s'"
+msgstr "git checkout: --detach no accepta un paràmetre de camí '%s'"
-#: builtin/checkout.c:1210
+#: builtin/checkout.c:1228
msgid ""
"git checkout: --ours/--theirs, --force and --merge are incompatible when\n"
"checking out of the index."
msgstr ""
-"git checkout: --ours/--theirs, --force i --merge són incompatibles al\n"
+"git checkout: --ours/--theirs, --force i --merge són incompatibles en\n"
"agafar de l'índex."
#: builtin/clean.c:26
msgid ""
"git clean [-d] [-f] [-i] [-n] [-q] [-e <pattern>] [-x | -X] [--] <paths>..."
msgstr ""
-"git clean [-d] [-f] [-i] [-n] [-q] [-e <patró>] [-x | -X] [--] <rutes>..."
+"git clean [-d] [-f] [-i] [-n] [-q] [-e <patró>] [-x | -X] [--] <camins>..."
#: builtin/clean.c:30
#, c-format
msgid "Removing %s\n"
-msgstr "Traient %s\n"
+msgstr "Eliminant %s\n"
#: builtin/clean.c:31
#, c-format
msgid "Would remove %s\n"
-msgstr "Trauria %s\n"
+msgstr "Eliminaria %s\n"
#: builtin/clean.c:32
#, c-format
@@ -3701,7 +3708,7 @@ msgstr "Saltaria el dipòsit %s\n"
#: builtin/clean.c:34
#, c-format
msgid "failed to remove %s"
-msgstr "s'ha fallat en treure %s"
+msgstr "s'ha fallat en eliminar %s"
#: builtin/clean.c:295
msgid ""
@@ -3713,7 +3720,7 @@ msgstr ""
"Ajuda d'avís:\n"
"1 - selecciona un ítem numerat\n"
"foo - selecciona un ítem basat en un prefix únic\n"
-" - (buit) selecciona res"
+" - (buit) no seleccionis res"
#: builtin/clean.c:299
msgid ""
@@ -3727,13 +3734,13 @@ msgid ""
" - (empty) finish selecting"
msgstr ""
"Ajuda d'avís:\n"
-"1 - selecciona un ítem solter\n"
+"1 - selecciona un sol ítem\n"
"3-5 - selecciona un rang d'ítems\n"
"2-3,6-9 - selecciona múltiples rangs\n"
"foo - selecciona un ítem basat en un prefix únic\n"
"-... - desselecciona els ítems seleccionats\n"
"* - tria tots els ítems\n"
-" - (buit) termina la selecció"
+" - (buit) finalitza la selecció"
#: builtin/clean.c:517
#, c-format
@@ -3757,7 +3764,7 @@ msgstr "Selecciona els ítems a suprimir"
#: builtin/clean.c:757
#, c-format
msgid "remove %s? "
-msgstr "treure %s?"
+msgstr "eliminar %s? "
#: builtin/clean.c:782
msgid "Bye."
@@ -3792,8 +3799,8 @@ msgstr "Què ara"
#: builtin/clean.c:826
msgid "Would remove the following item:"
msgid_plural "Would remove the following items:"
-msgstr[0] "Trauria l'ítem següent:"
-msgstr[1] "Trauria els ítems següents:"
+msgstr[0] "Eliminaria l'ítem següent:"
+msgstr[1] "Eliminaria els ítems següents:"
#: builtin/clean.c:843
msgid "No more files to clean, exiting."
@@ -3801,7 +3808,7 @@ msgstr "No hi ha més fitxers a netejar; sortint."
#: builtin/clean.c:874
msgid "do not print names of files removed"
-msgstr "no imprimeixis els noms dels fitxers trets"
+msgstr "no imprimeixis els noms dels fitxers eliminats"
#: builtin/clean.c:876
msgid "force"
@@ -3813,7 +3820,7 @@ msgstr "neteja interactiva"
#: builtin/clean.c:879
msgid "remove whole directories"
-msgstr "treu directoris enters"
+msgstr "elimina directoris sencers"
#: builtin/clean.c:880 builtin/describe.c:407 builtin/grep.c:714
#: builtin/ls-files.c:486 builtin/name-rev.c:311 builtin/show-ref.c:185
@@ -3826,11 +3833,11 @@ msgstr "afegiu <patró> per a ignorar les regles"
#: builtin/clean.c:882
msgid "remove ignored files, too"
-msgstr "treu els fitxers ignorats, també"
+msgstr "elimina els fitxers ignorats, també"
#: builtin/clean.c:884
msgid "remove only ignored files"
-msgstr "treu només els fitxers ignorats"
+msgstr "elimina només els fitxers ignorats"
#: builtin/clean.c:902
msgid "-x and -X cannot be used together"
@@ -3856,146 +3863,150 @@ msgstr ""
msgid "git clone [options] [--] <repo> [<dir>]"
msgstr "git clone [opcions] [--] <dipòsit> [<directori>]"
-#: builtin/clone.c:65 builtin/fetch.c:112 builtin/merge.c:223
+#: builtin/clone.c:66 builtin/fetch.c:112 builtin/merge.c:224
#: builtin/push.c:514
msgid "force progress reporting"
msgstr "força l'informe de progrés"
-#: builtin/clone.c:67
+#: builtin/clone.c:68
msgid "don't create a checkout"
-msgstr "no fes una agafada"
+msgstr "no facis cap agafada"
-#: builtin/clone.c:68 builtin/clone.c:70 builtin/init-db.c:488
+#: builtin/clone.c:69 builtin/clone.c:71 builtin/init-db.c:496
msgid "create a bare repository"
msgstr "crea un dipòsit nu"
-#: builtin/clone.c:72
+#: builtin/clone.c:73
msgid "create a mirror repository (implies bare)"
msgstr "crea un dipòsit reflectit (implica bare)"
-#: builtin/clone.c:74
+#: builtin/clone.c:75
msgid "to clone from a local repository"
msgstr "per a clonar des d'un dipòsit local"
-#: builtin/clone.c:76
+#: builtin/clone.c:77
msgid "don't use local hardlinks, always copy"
msgstr "no usis enllaços durs locals, sempre copia"
-#: builtin/clone.c:78
+#: builtin/clone.c:79
msgid "setup as shared repository"
msgstr "configura com a dipòsit compartit"
-#: builtin/clone.c:80 builtin/clone.c:82
+#: builtin/clone.c:81 builtin/clone.c:83
msgid "initialize submodules in the clone"
msgstr "initialitza els submòduls en el clon"
-#: builtin/clone.c:83 builtin/init-db.c:485
+#: builtin/clone.c:84 builtin/init-db.c:493
msgid "template-directory"
msgstr "directori-de-plantilla"
-#: builtin/clone.c:84 builtin/init-db.c:486
+#: builtin/clone.c:85 builtin/init-db.c:494
msgid "directory from which templates will be used"
msgstr "directori del qual les plantilles s'usaran"
-#: builtin/clone.c:86
+#: builtin/clone.c:87
msgid "reference repository"
msgstr "dipòsit de referència"
-#: builtin/clone.c:87 builtin/column.c:26 builtin/merge-file.c:44
+#: builtin/clone.c:88 builtin/column.c:26 builtin/merge-file.c:44
msgid "name"
msgstr "nom"
-#: builtin/clone.c:88
+#: builtin/clone.c:89
msgid "use <name> instead of 'origin' to track upstream"
msgstr "usa <nom> en lloc de 'origin' per a seguir la font"
-#: builtin/clone.c:90
+#: builtin/clone.c:91
msgid "checkout <branch> instead of the remote's HEAD"
-msgstr "agafa <rama> en lloc del HEAD del remot"
+msgstr "agafa <branca> en lloc del HEAD del remot"
-#: builtin/clone.c:92
+#: builtin/clone.c:93
msgid "path to git-upload-pack on the remote"
-msgstr "ruta a git-upload-pack en el remot"
+msgstr "camí a git-upload-pack en el remot"
-#: builtin/clone.c:93 builtin/fetch.c:113 builtin/grep.c:659
+#: builtin/clone.c:94 builtin/fetch.c:113 builtin/grep.c:659
msgid "depth"
msgstr "profunditat"
-#: builtin/clone.c:94
+#: builtin/clone.c:95
msgid "create a shallow clone of that depth"
msgstr "crea un clon superficial de tal profunditat"
-#: builtin/clone.c:96
+#: builtin/clone.c:97
msgid "clone only one branch, HEAD or --branch"
-msgstr "clona només una rama, HEAD o --branch"
+msgstr "clona només una branca, HEAD o --branch"
+
+#: builtin/clone.c:99
+msgid "use --reference only while cloning"
+msgstr "usa --reference només en clonar"
-#: builtin/clone.c:97 builtin/init-db.c:494
+#: builtin/clone.c:100 builtin/init-db.c:502
msgid "gitdir"
msgstr "directori de git"
-#: builtin/clone.c:98 builtin/init-db.c:495
+#: builtin/clone.c:101 builtin/init-db.c:503
msgid "separate git dir from working tree"
msgstr "separa el directori de git de l'arbre de treball"
-#: builtin/clone.c:99
+#: builtin/clone.c:102
msgid "key=value"
msgstr "calu=valor"
-#: builtin/clone.c:100
+#: builtin/clone.c:103
msgid "set config inside the new repository"
msgstr "estableix la configuració dins del dipòsit nou"
-#: builtin/clone.c:253
+#: builtin/clone.c:256
#, c-format
msgid "reference repository '%s' is not a local repository."
msgstr "el dipòsit de referència '%s' no és un dipòsit local."
-#: builtin/clone.c:257
+#: builtin/clone.c:260
#, c-format
msgid "reference repository '%s' is shallow"
msgstr "el dipòsit de referència '%s' és superficial"
-#: builtin/clone.c:260
+#: builtin/clone.c:263
#, c-format
msgid "reference repository '%s' is grafted"
msgstr "el dipòsit de referència '%s' és empeltat"
-#: builtin/clone.c:322
+#: builtin/clone.c:325
#, c-format
msgid "failed to create directory '%s'"
msgstr "s'ha fallat en crear el directori '%s'"
-#: builtin/clone.c:324 builtin/diff.c:84
+#: builtin/clone.c:327 builtin/diff.c:84
#, c-format
msgid "failed to stat '%s'"
msgstr "s'ha fallat en fer stat a '%s'"
-#: builtin/clone.c:326
+#: builtin/clone.c:329
#, c-format
msgid "%s exists and is not a directory"
msgstr "%s existeix i no és un directori"
-#: builtin/clone.c:340
+#: builtin/clone.c:343
#, c-format
msgid "failed to stat %s\n"
msgstr "s'ha fallat en fer stat a '%s'\n"
-#: builtin/clone.c:362
+#: builtin/clone.c:365
#, c-format
msgid "failed to create link '%s'"
msgstr "s'ha fallat en crear l'enllaç '%s'"
-#: builtin/clone.c:366
+#: builtin/clone.c:369
#, c-format
msgid "failed to copy file to '%s'"
msgstr "s'ha fallat en copiar el fitxer a '%s'"
-#: builtin/clone.c:389 builtin/clone.c:563
+#: builtin/clone.c:392 builtin/clone.c:566
#, c-format
msgid "done.\n"
msgstr "fet.\n"
-#: builtin/clone.c:401
+#: builtin/clone.c:404
msgid ""
"Clone succeeded, but checkout failed.\n"
"You can inspect what was checked out with 'git status'\n"
@@ -4005,110 +4016,122 @@ msgstr ""
"Podeu inspeccionar què s'ha agafat amb 'git status' i\n"
"tornar a intentar l'agafada amb 'git checkout -f HEAD'\n"
-#: builtin/clone.c:478
+#: builtin/clone.c:481
#, c-format
msgid "Could not find remote branch %s to clone."
-msgstr "No s'ha pogut trobar la rama remota %s per a clonar."
+msgstr "No s'ha pogut trobar la branca remota %s per a clonar."
-#: builtin/clone.c:558
+#: builtin/clone.c:561
#, c-format
msgid "Checking connectivity... "
msgstr "Provant connectivitat... "
-#: builtin/clone.c:561
+#: builtin/clone.c:564
msgid "remote did not send all necessary objects"
msgstr "el remot no ha enviat tots els objectes necessaris"
-#: builtin/clone.c:625
+#: builtin/clone.c:628
msgid "remote HEAD refers to nonexistent ref, unable to checkout.\n"
msgstr ""
-"el HEAD remot es refereix a una referència que no existeix; incapaç "
-"d'agafar.\n"
+"el HEAD remot es refereix a una referència que no existeix; no s'ha pogut "
+"agafar.\n"
-#: builtin/clone.c:656
+#: builtin/clone.c:659
msgid "unable to checkout working tree"
-msgstr "incapaç d'agafar l'arbre de treball"
+msgstr "no s'ha pogut agafar l'arbre de treball"
-#: builtin/clone.c:765
+#: builtin/clone.c:746
+msgid "cannot repack to clean up"
+msgstr "no es pot reempaquetar per a netejar"
+
+#: builtin/clone.c:748
+msgid "cannot unlink temporary alternates file"
+msgstr "no es pot desenllaçar el fitxer d'alternatives temporal"
+
+#: builtin/clone.c:778
msgid "Too many arguments."
msgstr "Hi ha massa paràmetres."
-#: builtin/clone.c:769
+#: builtin/clone.c:782
msgid "You must specify a repository to clone."
msgstr "Heu d'especificar un dipòsit per a clonar."
-#: builtin/clone.c:780
+#: builtin/clone.c:793
#, c-format
msgid "--bare and --origin %s options are incompatible."
msgstr "les opcions --bare i --origin %s són incompatibles."
-#: builtin/clone.c:783
+#: builtin/clone.c:796
msgid "--bare and --separate-git-dir are incompatible."
msgstr "--bare i --separate-git-dir són incompatibles."
-#: builtin/clone.c:796
+#: builtin/clone.c:809
#, c-format
msgid "repository '%s' does not exist"
msgstr "el dipòsit '%s' no existeix"
-#: builtin/clone.c:802 builtin/fetch.c:1155
+#: builtin/clone.c:815 builtin/fetch.c:1155
#, c-format
msgid "depth %s is not a positive number"
msgstr "la profunditat %s no és nombre positiu"
-#: builtin/clone.c:812
+#: builtin/clone.c:825
#, c-format
msgid "destination path '%s' already exists and is not an empty directory."
-msgstr "la ruta destí '%s' ja existeix i no és un directori buit."
+msgstr "el camí destí '%s' ja existeix i no és un directori buit."
-#: builtin/clone.c:822
+#: builtin/clone.c:835
#, c-format
msgid "working tree '%s' already exists."
msgstr "l'arbre de treball '%s' ja existeix."
-#: builtin/clone.c:835 builtin/clone.c:847
+#: builtin/clone.c:848 builtin/clone.c:860
#, c-format
msgid "could not create leading directories of '%s'"
msgstr "no s'ha pogut crear els directoris inicials de '%s'"
-#: builtin/clone.c:838
+#: builtin/clone.c:851
#, c-format
msgid "could not create work tree dir '%s'."
msgstr "no s'ha pogut crear el directori d'arbre de treball '%s'."
-#: builtin/clone.c:857
+#: builtin/clone.c:870
#, c-format
msgid "Cloning into bare repository '%s'...\n"
msgstr "Clonant al dipòsit nu '%s'...\n"
-#: builtin/clone.c:859
+#: builtin/clone.c:872
#, c-format
msgid "Cloning into '%s'...\n"
msgstr "Clonant a '%s'...\n"
-#: builtin/clone.c:895
+#: builtin/clone.c:897
+msgid "--dissociate given, but there is no --reference"
+msgstr "s'ha donat --dissociate, però no hi ha --reference"
+
+#: builtin/clone.c:912
msgid "--depth is ignored in local clones; use file:// instead."
-msgstr "--depth s'ignora en els clons locals; useu file:// en lloc."
+msgstr "--depth s'ignora en els clons locals; useu file:// en lloc d'això."
-#: builtin/clone.c:898
+#: builtin/clone.c:915
msgid "source repository is shallow, ignoring --local"
msgstr "el dipòsit font és superficial, ignorant --local"
-#: builtin/clone.c:903
+#: builtin/clone.c:920
msgid "--local is ignored"
msgstr "--local s'ignora"
-#: builtin/clone.c:907
+#: builtin/clone.c:924
#, c-format
msgid "Don't know how to clone %s"
msgstr "No es sap com clonar %s"
-#: builtin/clone.c:958 builtin/clone.c:966
+#: builtin/clone.c:975 builtin/clone.c:983
#, c-format
msgid "Remote branch %s not found in upstream %s"
-msgstr "La rama remota %s no es troba en la font %s"
+msgstr "La branca remota %s no es troba en la font %s"
-#: builtin/clone.c:969
+#: builtin/clone.c:986
msgid "You appear to have cloned an empty repository."
msgstr "Sembla que heu clonat un dipòsit buit."
@@ -4118,7 +4141,7 @@ msgstr "git column [opcions]"
#: builtin/column.c:26
msgid "lookup config vars"
-msgstr "cerca els variables de configuració"
+msgstr "cerca les variables de configuració"
#: builtin/column.c:27 builtin/column.c:28
msgid "layout to use"
@@ -4146,11 +4169,11 @@ msgstr "--command ha de ser el primer paràmetre"
#: builtin/commit.c:37
msgid "git commit [options] [--] <pathspec>..."
-msgstr "git commit [opcions] [--] <especificació-de-ruta>..."
+msgstr "git commit [opcions] [--] <especificació-de-camí>..."
#: builtin/commit.c:42
msgid "git status [options] [--] <pathspec>..."
-msgstr "git status [opcions] [--] <especificació-de-ruta>..."
+msgstr "git status [opcions] [--] <especificació-de-camí>..."
#: builtin/commit.c:47
msgid ""
@@ -4169,7 +4192,7 @@ msgstr ""
"S'han configurat el vostre nom i adreça de correu electrònic\n"
"automàticament basats en el vostre nom d'usuari i nom de host. Si us\n"
"plau, comproveu que siguin correctes. Podeu suprimir aquest missatge\n"
-"per establir-los explícitament. Executeu l'ordre següent i seguiu les\n"
+"establint-los explícitament. Executeu l'ordre següent i seguiu les\n"
"instruccions en el vostre editor per editar el vostre fitxer de\n"
"configuració:\n"
"\n"
@@ -4195,7 +4218,7 @@ msgstr ""
"S'han configurat el vostre nom i adreça de correu electrònic\n"
"automàticament basats en el vostre nom d'usuari i nom de host. Si us\n"
"plau, comproveu que siguin correctes. Podeu suprimir aquest missatge\n"
-"per establir-los explícitament:\n"
+"establint-los explícitament:\n"
"\n"
" git config --global user.name \"El Vostre Nom\"\n"
" git config --global user.email tu@example.com\n"
@@ -4211,9 +4234,9 @@ msgid ""
"it empty. You can repeat your command with --allow-empty, or you can\n"
"remove the commit entirely with \"git reset HEAD^\".\n"
msgstr ""
-"Heu demanat esmenar la comissió més recent, però fer això la feria\n"
-"buida. Podeu repetir el vostre ordre amb --allow-empty, o podeu\n"
-"treure la comissió per complet amb \"git reset HEAD^\".\n"
+"Heu demanat esmenar la comissió més recent, però fer això la\n"
+"deixaria buida. Podeu repetir la vostra ordre amb --allow-empty, o\n"
+"podeu eliminar la comissió per complet amb \"git reset HEAD^\".\n"
#: builtin/commit.c:77
msgid ""
@@ -4243,12 +4266,12 @@ msgid ""
"Then \"git cherry-pick --continue\" will resume cherry-picking\n"
"the remaining commits.\n"
msgstr ""
-"Si voleu saltar aquesta comissió, useu:\n"
+"Si voleu ometre aquesta comissió, useu:\n"
"\n"
" git reset\n"
"\n"
"Llavors \"git cherry-pick --continue\" reprendrà recollint\n"
-"com cireres les comissions restants.\n"
+"com a cireres les comissions restants.\n"
#: builtin/commit.c:302
msgid "failed to unpack HEAD tree object"
@@ -4256,7 +4279,7 @@ msgstr "s'ha fallat en desempaquetar l'objecte d'arbre HEAD"
#: builtin/commit.c:342
msgid "unable to create temporary index"
-msgstr "incapaç de crear un índex temporal"
+msgstr "no s'ha pogut crear un índex temporal"
#: builtin/commit.c:348
msgid "interactive add failed"
@@ -4264,11 +4287,11 @@ msgstr "l'afegiment interactiu ha fallat"
#: builtin/commit.c:359
msgid "unable to write index file"
-msgstr "incapaç d'escriure el fitxer d'índex"
+msgstr "no s'ha pogut escriure el fitxer d'índex"
#: builtin/commit.c:361
msgid "unable to update temporary index"
-msgstr "incapaç de actualitzar l'índex temporal"
+msgstr "no s'ha pogut actualitzar l'índex temporal"
#: builtin/commit.c:363
msgid "Failed to update main cache tree"
@@ -4276,7 +4299,7 @@ msgstr "S'ha fallat en actualitzar l'arbre principal de memòria cau"
#: builtin/commit.c:387 builtin/commit.c:412 builtin/commit.c:461
msgid "unable to write new_index file"
-msgstr "incapaç d'escriure el fitxer new_index"
+msgstr "no s'ha pogut escriure el fitxer new_index"
#: builtin/commit.c:443
msgid "cannot do a partial commit during a merge."
@@ -4292,77 +4315,72 @@ msgstr "no es pot llegir l'índex"
#: builtin/commit.c:473
msgid "unable to write temporary index file"
-msgstr "incapaç d'escriure un fitxer d'índex temporal"
+msgstr "no s'ha pogut escriure un fitxer d'índex temporal"
-#: builtin/commit.c:592
+#: builtin/commit.c:584
#, c-format
msgid "commit '%s' lacks author header"
msgstr "a la comissió '%s' li manca la capçalera d'autor"
-#: builtin/commit.c:594
+#: builtin/commit.c:586
#, c-format
msgid "commit '%s' has malformed author line"
-msgstr "la comissió '%s' té una línia d'autor malformada"
+msgstr "la comissió '%s' té una línia d'autor mal formada"
-#: builtin/commit.c:613
+#: builtin/commit.c:605
msgid "malformed --author parameter"
-msgstr "paràmetre --author malformat"
+msgstr "paràmetre --author mal format"
-#: builtin/commit.c:621
+#: builtin/commit.c:613
#, c-format
msgid "invalid date format: %s"
-msgstr "format de data invàlid: %s"
+msgstr "format de data no vàlid: %s"
-#: builtin/commit.c:642
-#, c-format
-msgid "Malformed ident string: '%s'"
-msgstr "Cadena d'identificació malformada: '%s'"
-
-#: builtin/commit.c:675
+#: builtin/commit.c:657
msgid ""
"unable to select a comment character that is not used\n"
"in the current commit message"
msgstr ""
-"incapaç de seleccionar un caràcter de comentari que\n"
+"no es pot seleccionar un caràcter de comentari que\n"
"no sigui usat en el missatge de comissió actual"
-#: builtin/commit.c:712 builtin/commit.c:745 builtin/commit.c:1120
+#: builtin/commit.c:694 builtin/commit.c:727 builtin/commit.c:1084
#, c-format
msgid "could not lookup commit %s"
msgstr "no s'ha pogut trobar la comissió %s"
-#: builtin/commit.c:724 builtin/shortlog.c:273
+#: builtin/commit.c:706 builtin/shortlog.c:273
#, c-format
msgid "(reading log message from standard input)\n"
msgstr "(llegint el missatge de registre de l'entrada estàndard)\n"
-#: builtin/commit.c:726
+#: builtin/commit.c:708
msgid "could not read log from standard input"
msgstr "no s'ha pogut llegir de l'entrada estàndard"
-#: builtin/commit.c:730
+#: builtin/commit.c:712
#, c-format
msgid "could not read log file '%s'"
msgstr "no s'ha pogut llegir el fitxer de registre '%s'"
-#: builtin/commit.c:752
+#: builtin/commit.c:734
msgid "could not read MERGE_MSG"
msgstr "no s'ha pogut llegir MERGE_MSG"
-#: builtin/commit.c:756
+#: builtin/commit.c:738
msgid "could not read SQUASH_MSG"
msgstr "no s'ha pogur llegir SQUASH_MSG"
-#: builtin/commit.c:760
+#: builtin/commit.c:742
#, c-format
msgid "could not read '%s'"
msgstr "no s'ha pogut llegir '%s'"
-#: builtin/commit.c:831
+#: builtin/commit.c:789
msgid "could not write commit template"
msgstr "no s'ha pogut escriure la plantilla de comissió"
-#: builtin/commit.c:849
+#: builtin/commit.c:807
#, c-format
msgid ""
"\n"
@@ -4373,11 +4391,11 @@ msgid ""
msgstr ""
"\n"
"Sembla que podeu estar cometent una fusió.\n"
-"Si això no és correcte, si us plau, treu el fitxer\n"
+"Si això no és correcte, si us plau, elimineu el fitxer\n"
"\t%s\n"
-"i intenteu de nou.\n"
+"i intenteu-ho de nou.\n"
-#: builtin/commit.c:854
+#: builtin/commit.c:812
#, c-format
msgid ""
"\n"
@@ -4388,11 +4406,11 @@ msgid ""
msgstr ""
"\n"
"Sembla que podeu estar cometent un recull de cireres.\n"
-"Si això no és correcte, si us plau treu el fitxer\n"
+"Si això no és correcte, si us plau elimineu el fitxer\n"
"\t%s\n"
-"i intenteu de nou.\n"
+"i intenteu-ho de nou.\n"
-#: builtin/commit.c:867
+#: builtin/commit.c:825
#, c-format
msgid ""
"Please enter the commit message for your changes. Lines starting\n"
@@ -4402,7 +4420,7 @@ msgstr ""
"S'ignoraran les línies començant amb '%c', i un missatge de\n"
"comissió buit avorta la comissió.\n"
-#: builtin/commit.c:874
+#: builtin/commit.c:832
#, c-format
msgid ""
"Please enter the commit message for your changes. Lines starting\n"
@@ -4410,149 +4428,149 @@ msgid ""
"An empty message aborts the commit.\n"
msgstr ""
"Si us plau, introduïu el missatge de comissió dels vostres canvis.\n"
-"Es retindran les línies començants amb '%c'; podeu treure'ls per vós\n"
+"Es retindran les línies començants amb '%c'; podeu eliminar-les per vós\n"
"mateix si voleu. Un missatge buit avorta la comissió.\n"
-#: builtin/commit.c:888
+#: builtin/commit.c:852
#, c-format
msgid "%sAuthor: %.*s <%.*s>"
msgstr "%sAutor: %.*s <%.*s>"
-#: builtin/commit.c:896
+#: builtin/commit.c:860
#, c-format
msgid "%sDate: %s"
msgstr "%sData: %s"
-#: builtin/commit.c:903
+#: builtin/commit.c:867
#, c-format
msgid "%sCommitter: %.*s <%.*s>"
msgstr "%sComitent: %.*s <%.*s>"
-#: builtin/commit.c:921
+#: builtin/commit.c:885
msgid "Cannot read index"
msgstr "No es pot llegir l'índex"
-#: builtin/commit.c:978
+#: builtin/commit.c:942
msgid "Error building trees"
msgstr "Error en construir arbres"
-#: builtin/commit.c:993 builtin/tag.c:495
+#: builtin/commit.c:957 builtin/tag.c:495
#, c-format
msgid "Please supply the message using either -m or -F option.\n"
msgstr "Si us plau, proveïu el missatge per usar o l'opció -m o l'opció -F.\n"
-#: builtin/commit.c:1095
+#: builtin/commit.c:1059
#, c-format
msgid "No existing author found with '%s'"
msgstr "Cap autor existent trobat amb '%s'"
-#: builtin/commit.c:1110 builtin/commit.c:1350
+#: builtin/commit.c:1074 builtin/commit.c:1314
#, c-format
msgid "Invalid untracked files mode '%s'"
-msgstr "Mode de fitxers no seguits invàlid '%s'"
+msgstr "Mode de fitxers no seguits no vàlid '%s'"
-#: builtin/commit.c:1147
+#: builtin/commit.c:1111
msgid "--long and -z are incompatible"
msgstr "--long i -z són incompatibles"
-#: builtin/commit.c:1177
+#: builtin/commit.c:1141
msgid "Using both --reset-author and --author does not make sense"
msgstr "Usar ambdós --reset-author i --author no té sentit"
-#: builtin/commit.c:1186
+#: builtin/commit.c:1150
msgid "You have nothing to amend."
msgstr "No teniu res a esmenar."
-#: builtin/commit.c:1189
+#: builtin/commit.c:1153
msgid "You are in the middle of a merge -- cannot amend."
-msgstr "Esteu en el medi d'una fusió -- no es pot esmenar."
+msgstr "Esteu enmig d'una fusió -- no es pot esmenar."
-#: builtin/commit.c:1191
+#: builtin/commit.c:1155
msgid "You are in the middle of a cherry-pick -- cannot amend."
-msgstr "Esteu en el medi d'un recull de cireres -- no es pot esmenar."
+msgstr "Esteu enmig d'un recull de cireres -- no es pot esmenar."
-#: builtin/commit.c:1194
+#: builtin/commit.c:1158
msgid "Options --squash and --fixup cannot be used together"
-msgstr "Les opcions --squash i --fixup no es poden usar junts"
+msgstr "Les opcions --squash i --fixup no es poden usar juntes"
-#: builtin/commit.c:1204
+#: builtin/commit.c:1168
msgid "Only one of -c/-C/-F/--fixup can be used."
msgstr "Només un de -c/-C/-F/--fixup es pot usar."
-#: builtin/commit.c:1206
+#: builtin/commit.c:1170
msgid "Option -m cannot be combined with -c/-C/-F/--fixup."
msgstr "L'opció -m no es pot combinar amb -c/-C/-F/--fixup."
-#: builtin/commit.c:1214
+#: builtin/commit.c:1178
msgid "--reset-author can be used only with -C, -c or --amend."
msgstr "--reset-author només es pot usar amb -C, -c o --amend."
-#: builtin/commit.c:1231
+#: builtin/commit.c:1195
msgid "Only one of --include/--only/--all/--interactive/--patch can be used."
msgstr "Només un de --include/--only/--all/--interactive/--patch es pot usar."
-#: builtin/commit.c:1233
+#: builtin/commit.c:1197
msgid "No paths with --include/--only does not make sense."
-msgstr "--include/--only no té sentit sense ruta."
+msgstr "--include/--only no té sentit sense camí."
-#: builtin/commit.c:1235
+#: builtin/commit.c:1199
msgid "Clever... amending the last one with dirty index."
-msgstr "Intel·ligent...esmenant el últim amb índex brut."
+msgstr "Intel·ligent... esmenant l'últim amb índex brut."
-#: builtin/commit.c:1237
+#: builtin/commit.c:1201
msgid "Explicit paths specified without -i or -o; assuming --only paths..."
msgstr ""
-"S'han especificat rutes explícites sense -i o -o; presumint rutes --only..."
+"S'han especificat camins explícits sense -i o -o; presumint camins --only..."
-#: builtin/commit.c:1249 builtin/tag.c:728
+#: builtin/commit.c:1213 builtin/tag.c:728
#, c-format
msgid "Invalid cleanup mode %s"
-msgstr "Mode de neteja invàlid %s"
+msgstr "Mode de neteja no vàlid %s"
-#: builtin/commit.c:1254
+#: builtin/commit.c:1218
msgid "Paths with -a does not make sense."
-msgstr "-a no té sentit amb rutes."
+msgstr "-a no té sentit amb camins."
-#: builtin/commit.c:1364 builtin/commit.c:1644
+#: builtin/commit.c:1328 builtin/commit.c:1608
msgid "show status concisely"
msgstr "mostra l'estat concisament"
-#: builtin/commit.c:1366 builtin/commit.c:1646
+#: builtin/commit.c:1330 builtin/commit.c:1610
msgid "show branch information"
-msgstr "mostra la informació de rama"
+msgstr "mostra la informació de branca"
-#: builtin/commit.c:1368 builtin/commit.c:1648 builtin/push.c:500
+#: builtin/commit.c:1332 builtin/commit.c:1612 builtin/push.c:500
msgid "machine-readable output"
msgstr "sortida llegible per màquina"
-#: builtin/commit.c:1371 builtin/commit.c:1650
+#: builtin/commit.c:1335 builtin/commit.c:1614
msgid "show status in long format (default)"
msgstr "mostra l'estat en format llarg (per defecte)"
-#: builtin/commit.c:1374 builtin/commit.c:1653
+#: builtin/commit.c:1338 builtin/commit.c:1617
msgid "terminate entries with NUL"
-msgstr "termina les entrades amb NUL"
+msgstr "acaba les entrades amb NUL"
-#: builtin/commit.c:1376 builtin/commit.c:1656 builtin/fast-export.c:980
+#: builtin/commit.c:1340 builtin/commit.c:1620 builtin/fast-export.c:980
#: builtin/fast-export.c:983 builtin/tag.c:603
msgid "mode"
msgstr "mode"
-#: builtin/commit.c:1377 builtin/commit.c:1656
+#: builtin/commit.c:1341 builtin/commit.c:1620
msgid "show untracked files, optional modes: all, normal, no. (Default: all)"
msgstr ""
"mostra els fitxers no seguits, modes opcional: all, normal, no. (Per "
"defecte: all)"
-#: builtin/commit.c:1380
+#: builtin/commit.c:1344
msgid "show ignored files"
msgstr "mostra els fitxers ignorats"
-#: builtin/commit.c:1381 parse-options.h:153
+#: builtin/commit.c:1345 parse-options.h:153
msgid "when"
msgstr "quan"
-#: builtin/commit.c:1382
+#: builtin/commit.c:1346
msgid ""
"ignore changes to submodules, optional when: all, dirty, untracked. "
"(Default: all)"
@@ -4560,210 +4578,210 @@ msgstr ""
"ignora els canvis als submòduls, opcional quan: all, dirty, untracked. (Per "
"defecte: all)"
-#: builtin/commit.c:1384
+#: builtin/commit.c:1348
msgid "list untracked files in columns"
msgstr "mostra els fitxers no seguits en columnes"
-#: builtin/commit.c:1471
+#: builtin/commit.c:1435
msgid "couldn't look up newly created commit"
-msgstr "no s'ha pogut trobar la comissió novament creat"
+msgstr "no s'ha pogut trobar la comissió novament creada"
-#: builtin/commit.c:1473
+#: builtin/commit.c:1437
msgid "could not parse newly created commit"
-msgstr "no s'ha pogut analitzar la comissió novament creat"
+msgstr "no s'ha pogut analitzar la comissió novament creada"
-#: builtin/commit.c:1518
+#: builtin/commit.c:1482
msgid "detached HEAD"
msgstr "HEAD separat"
-#: builtin/commit.c:1521
+#: builtin/commit.c:1485
msgid " (root-commit)"
msgstr " (comissió d'arrel)"
-#: builtin/commit.c:1614
+#: builtin/commit.c:1578
msgid "suppress summary after successful commit"
-msgstr "omet el resum després d'una comissió reexita"
+msgstr "omet el resum després d'una comissió reeixida"
-#: builtin/commit.c:1615
+#: builtin/commit.c:1579
msgid "show diff in commit message template"
msgstr "mostra la diferència en la plantilla de missatge de comissió"
-#: builtin/commit.c:1617
+#: builtin/commit.c:1581
msgid "Commit message options"
msgstr "Opcions de missatge de comissió"
-#: builtin/commit.c:1618 builtin/tag.c:601
+#: builtin/commit.c:1582 builtin/tag.c:601
msgid "read message from file"
msgstr "llegiu el missatge des d'un fitxer"
-#: builtin/commit.c:1619
+#: builtin/commit.c:1583
msgid "author"
msgstr "autor"
-#: builtin/commit.c:1619
+#: builtin/commit.c:1583
msgid "override author for commit"
msgstr "autor corregit de la comissió"
-#: builtin/commit.c:1620 builtin/gc.c:275
+#: builtin/commit.c:1584 builtin/gc.c:275
msgid "date"
msgstr "data"
-#: builtin/commit.c:1620
+#: builtin/commit.c:1584
msgid "override date for commit"
msgstr "data corregida de la comissió"
-#: builtin/commit.c:1621 builtin/merge.c:217 builtin/notes.c:408
-#: builtin/notes.c:565 builtin/tag.c:599
+#: builtin/commit.c:1585 builtin/merge.c:218 builtin/notes.c:391
+#: builtin/notes.c:554 builtin/tag.c:599
msgid "message"
msgstr "missatge"
-#: builtin/commit.c:1621
+#: builtin/commit.c:1585
msgid "commit message"
msgstr "missatge de comissió"
-#: builtin/commit.c:1622
+#: builtin/commit.c:1586
msgid "reuse and edit message from specified commit"
msgstr "reusa i edita el missatge de la comissió especificada"
-#: builtin/commit.c:1623
+#: builtin/commit.c:1587
msgid "reuse message from specified commit"
msgstr "reusa el missatge de la comissió especificada"
-#: builtin/commit.c:1624
+#: builtin/commit.c:1588
msgid "use autosquash formatted message to fixup specified commit"
msgstr ""
"usa el missatge formatat d'aixafada automàtica per a arreglar la comissió "
"especificada"
-#: builtin/commit.c:1625
+#: builtin/commit.c:1589
msgid "use autosquash formatted message to squash specified commit"
msgstr ""
"usa el missatge formatat d'aixafada automàtica per a aixafar la comissió "
"especificada"
-#: builtin/commit.c:1626
+#: builtin/commit.c:1590
msgid "the commit is authored by me now (used with -C/-c/--amend)"
msgstr "l'autor de la comissió ja sóc jo (usat amb -C/-c/--amend)"
-#: builtin/commit.c:1627 builtin/log.c:1191 builtin/revert.c:86
+#: builtin/commit.c:1591 builtin/log.c:1191 builtin/revert.c:86
msgid "add Signed-off-by:"
msgstr "afegeix Signed-off-by:"
-#: builtin/commit.c:1628
+#: builtin/commit.c:1592
msgid "use specified template file"
msgstr "usa el fitxer de plantilla especificat"
-#: builtin/commit.c:1629
+#: builtin/commit.c:1593
msgid "force edit of commit"
msgstr "força l'edició de la comissió"
-#: builtin/commit.c:1630
+#: builtin/commit.c:1594
msgid "default"
msgstr "per defecte"
-#: builtin/commit.c:1630 builtin/tag.c:604
+#: builtin/commit.c:1594 builtin/tag.c:604
msgid "how to strip spaces and #comments from message"
msgstr "com despullar els espais i #comentaris del missatge"
-#: builtin/commit.c:1631
+#: builtin/commit.c:1595
msgid "include status in commit message template"
msgstr "inclou l'estat en la plantilla de missatge de comissió"
-#: builtin/commit.c:1632 builtin/merge.c:224 builtin/revert.c:92
+#: builtin/commit.c:1596 builtin/merge.c:225 builtin/revert.c:92
#: builtin/tag.c:605
msgid "key-id"
msgstr "ID de clau"
-#: builtin/commit.c:1633 builtin/merge.c:225 builtin/revert.c:93
+#: builtin/commit.c:1597 builtin/merge.c:226 builtin/revert.c:93
msgid "GPG sign commit"
msgstr "firma la comissió amb GPG"
-#: builtin/commit.c:1636
+#: builtin/commit.c:1600
msgid "Commit contents options"
msgstr "Opcions dels continguts de les comissions"
-#: builtin/commit.c:1637
+#: builtin/commit.c:1601
msgid "commit all changed files"
msgstr "comet tots els fitxers canviats"
-#: builtin/commit.c:1638
+#: builtin/commit.c:1602
msgid "add specified files to index for commit"
msgstr "afegeix els fitxers especificats a l'índex per a cometre"
-#: builtin/commit.c:1639
+#: builtin/commit.c:1603
msgid "interactively add files"
msgstr "afegeix els fitxers interactivament"
-#: builtin/commit.c:1640
+#: builtin/commit.c:1604
msgid "interactively add changes"
msgstr "afegeix els canvis interactivament"
-#: builtin/commit.c:1641
+#: builtin/commit.c:1605
msgid "commit only specified files"
msgstr "comet només els fitxers especificats"
-#: builtin/commit.c:1642
+#: builtin/commit.c:1606
msgid "bypass pre-commit hook"
msgstr "evita el ganxo de precomissió"
-#: builtin/commit.c:1643
+#: builtin/commit.c:1607
msgid "show what would be committed"
msgstr "mostra què es cometria"
-#: builtin/commit.c:1654
+#: builtin/commit.c:1618
msgid "amend previous commit"
msgstr "esmena la comissió anterior"
-#: builtin/commit.c:1655
+#: builtin/commit.c:1619
msgid "bypass post-rewrite hook"
msgstr "evita el ganxo de postreescriure"
-#: builtin/commit.c:1660
+#: builtin/commit.c:1624
msgid "ok to record an empty change"
msgstr "està bé registrar un canvi buit"
-#: builtin/commit.c:1662
+#: builtin/commit.c:1626
msgid "ok to record a change with an empty message"
msgstr "està bé registrar un canvi amb missatge buit"
-#: builtin/commit.c:1691
+#: builtin/commit.c:1655
msgid "could not parse HEAD commit"
msgstr "no s'ha pogut analitzar la comissió HEAD"
-#: builtin/commit.c:1730 builtin/merge.c:518
+#: builtin/commit.c:1694 builtin/merge.c:519
#, c-format
msgid "could not open '%s' for reading"
msgstr "no s'ha pogut obrir '%s' per a lectura"
-#: builtin/commit.c:1737
+#: builtin/commit.c:1701
#, c-format
msgid "Corrupt MERGE_HEAD file (%s)"
msgstr "Fitxer MERGE_HEAD corrupte (%s)"
-#: builtin/commit.c:1744
+#: builtin/commit.c:1708
msgid "could not read MERGE_MODE"
msgstr "no s'ha pogut llegir MERGE_MODE"
-#: builtin/commit.c:1763
+#: builtin/commit.c:1727
#, c-format
msgid "could not read commit message: %s"
msgstr "no s'ha pogut llegir el missatge de comissió: %s"
-#: builtin/commit.c:1774
+#: builtin/commit.c:1738
#, c-format
msgid "Aborting commit; you did not edit the message.\n"
msgstr "Avortant la comissió; no heu editat el missatge.\n"
-#: builtin/commit.c:1779
+#: builtin/commit.c:1743
#, c-format
msgid "Aborting commit due to empty commit message.\n"
msgstr "Avortant la comissió a causa d'un missatge de comissió buit.\n"
-#: builtin/commit.c:1794 builtin/merge.c:850 builtin/merge.c:875
+#: builtin/commit.c:1758 builtin/merge.c:851 builtin/merge.c:876
msgid "failed to write commit object"
msgstr "s'ha fallat en escriure l'objecte de comissió"
-#: builtin/commit.c:1827
+#: builtin/commit.c:1791
msgid ""
"Repository has been updated, but unable to write\n"
"new_index file. Check that disk is not full and quota is\n"
@@ -4771,7 +4789,7 @@ msgid ""
msgstr ""
"S'ha actualitzat el dipòsit, però no es pot escriure el\n"
"fitxer new_index. Comproveu que el disc no estigui ple i\n"
-"que la quota no estigui excedit, i després\n"
+"que la quota no estigui excedida, i després\n"
"\"git reset HEAD\" per a recuperar."
#: builtin/config.c:8
@@ -4824,24 +4842,24 @@ msgstr "obtén valors de regexp: regex-de-noms [regex-de-valors]"
#: builtin/config.c:63
msgid "get value specific for the URL: section[.var] URL"
-msgstr "obtén el valor especific al URL: secció[.variable] URL"
+msgstr "obtén el valor especific per a l'URL: secció[.variable] URL"
#: builtin/config.c:64
msgid "replace all matching variables: name value [value_regex]"
msgstr ""
-"reemplaça tots els variables que coincideixen: nom valor [regex_de_valors]"
+"reemplaça totes les variables que coincideixen: nom valor [regex_de_valors]"
#: builtin/config.c:65
msgid "add a new variable: name value"
-msgstr "afegeix un variable nou: nom valor"
+msgstr "afegeix una variable nova: nom valor"
#: builtin/config.c:66
msgid "remove a variable: name [value-regex]"
-msgstr "treu un variable: nom [regex-de-valors]"
+msgstr "elimina una variable: nom [regex-de-valors]"
#: builtin/config.c:67
msgid "remove all matches: name [value-regex]"
-msgstr "treu totes les coincidències: nom [regex-de-valors]"
+msgstr "elimina totes les coincidències: nom [regex-de-valors]"
#: builtin/config.c:68
msgid "rename section: old-name new-name"
@@ -4849,7 +4867,7 @@ msgstr "canvia el nom de secció: nom-antic nom-nou"
#: builtin/config.c:69
msgid "remove a section: name"
-msgstr "treu una secció: nom"
+msgstr "elimina una secció: nom"
#: builtin/config.c:70
msgid "list all"
@@ -4859,17 +4877,13 @@ msgstr "llista tots"
msgid "open an editor"
msgstr "obre un editor"
-#: builtin/config.c:72 builtin/config.c:73
-msgid "slot"
-msgstr "ranura"
-
#: builtin/config.c:72
-msgid "find the color configured: [default]"
-msgstr "troba el color configurat: [per defecte]"
+msgid "find the color configured: slot [default]"
+msgstr "troba el color configurat: ranura [per defecte]"
#: builtin/config.c:73
-msgid "find the color setting: [stdout-is-tty]"
-msgstr "troba l'ajust de color: [stdout-és-tty]"
+msgid "find the color setting: slot [stdout-is-tty]"
+msgstr "troba l'ajust de color: ranura [stdout-és-tty]"
#: builtin/config.c:74
msgid "Type"
@@ -4889,7 +4903,7 @@ msgstr "el valor és --bool o --int"
#: builtin/config.c:78
msgid "value is a path (file or directory name)"
-msgstr "el valor és una ruta (nom de fitxer o directori)"
+msgstr "el valor és un camí (nom de fitxer o directori)"
#: builtin/config.c:79
msgid "Other"
@@ -4897,17 +4911,17 @@ msgstr "Altre"
#: builtin/config.c:80
msgid "terminate values with NUL byte"
-msgstr "termina els valors amb un octet NUL"
+msgstr "acaba els valors amb un octet NUL"
#: builtin/config.c:81
msgid "respect include directives on lookup"
-msgstr "respecta les directives d'inclusió al cercar"
+msgstr "respecta les directives d'inclusió en cercar"
-#: builtin/config.c:315
+#: builtin/config.c:316
msgid "unable to parse default color value"
-msgstr "incapaç d'analitzar el valor de color per defecte"
+msgstr "no s'ha pogut analitzar el valor de color per defecte"
-#: builtin/config.c:455
+#: builtin/config.c:457
#, c-format
msgid ""
"# This is Git's per-user configuration file.\n"
@@ -4916,13 +4930,13 @@ msgid ""
"#\tuser = %s\n"
"#\temail = %s\n"
msgstr ""
-"# Això és el fitxer de configuració del Git del usuari.\n"
+"# Això és el fitxer de configuració del Git de l'usuari.\n"
"[core]\n"
-"# Si us plau, adapteu i descomenteu les línies següentes:\n"
+"# Si us plau, adapteu i descomenteu les línies següents:\n"
"#\tuser = %s\n"
"#\temail = %s\n"
-#: builtin/config.c:590
+#: builtin/config.c:589
#, c-format
msgid "cannot create configuration file %s"
msgstr "no es pot crear el fitxer de configuració '%s'"
@@ -4981,7 +4995,7 @@ msgstr "cercant per a descriure %s\n"
#: builtin/describe.c:319
#, c-format
msgid "finished search at %s\n"
-msgstr "s'ha terminat la cerca a %s\n"
+msgstr "s'ha finalitzat la cerca a %s\n"
#: builtin/describe.c:346
#, c-format
@@ -5029,7 +5043,7 @@ msgstr "usa qualsevulla referència"
#: builtin/describe.c:399
msgid "use any tag, even unannotated"
-msgstr "usa qualsevulla etiqueta, encara les sense anotar"
+msgstr "usa qualsevulla etiqueta, fins i tot aquelles sense anotar"
#: builtin/describe.c:400
msgid "always use long format"
@@ -5037,7 +5051,7 @@ msgstr "sempre usa el format llarg"
#: builtin/describe.c:401
msgid "only follow first parent"
-msgstr "només segueix el primer pare"
+msgstr "només segueix la primera mare"
#: builtin/describe.c:404
msgid "only output exact matches"
@@ -5083,7 +5097,7 @@ msgstr "'%s': no és ni fitxer regular ni enllaç simbòlic"
#: builtin/diff.c:237
#, c-format
msgid "invalid option: %s"
-msgstr "opció invàlida: %s"
+msgstr "opció no vàlida: %s"
#: builtin/diff.c:358
msgid "Not a git repository"
@@ -5092,7 +5106,7 @@ msgstr "No és un dipòsit de git"
#: builtin/diff.c:401
#, c-format
msgid "invalid object '%s' given."
-msgstr "s'ha donat un objecte invàlid '%s'."
+msgstr "s'ha donat un objecte no vàlid '%s'."
#: builtin/diff.c:410
#, c-format
@@ -5102,7 +5116,7 @@ msgstr "s'ha donat més de dos blobs: '%s"
#: builtin/diff.c:417
#, c-format
msgid "unhandled object '%s' given."
-msgstr "s'ha donat l'objecte no manejat '%s'."
+msgstr "s'ha donat l'objecte no gestionat '%s'."
#: builtin/fast-export.c:24
msgid "git fast-export [rev-list-opts]"
@@ -5114,16 +5128,15 @@ msgstr "mostra el progrés després de <n> objectes"
#: builtin/fast-export.c:981
msgid "select handling of signed tags"
-msgstr "selecciona el manejament de les etiquetes firmades"
+msgstr "selecciona la gestió de les etiquetes firmades"
#: builtin/fast-export.c:984
msgid "select handling of tags that tag filtered objects"
-msgstr ""
-"selecciona el manejament de les etiquetes que etiquetin objectes filtrats"
+msgstr "selecciona la gestió de les etiquetes que etiquetin objectes filtrats"
#: builtin/fast-export.c:987
msgid "Dump marks to this file"
-msgstr "Bolcar les marques a aquest fitxer"
+msgstr "Bolca les marques a aquest fitxer"
#: builtin/fast-export.c:989
msgid "Import marks from this file"
@@ -5131,7 +5144,7 @@ msgstr "Importa les marques d'aquest fitxer"
#: builtin/fast-export.c:991
msgid "Fake a tagger when tags lack one"
-msgstr "Fingeix un etiquetador quan un lis manca a les etiquetes"
+msgstr "Fingeix un etiquetador quan els en manca un a les etiquetes"
#: builtin/fast-export.c:993
msgid "Output full tree for each commit"
@@ -5139,7 +5152,7 @@ msgstr "Imprimeix l'arbre complet de cada comissió"
#: builtin/fast-export.c:995
msgid "Use the done feature to terminate the stream"
-msgstr "Usa la característica done per a terminar el corrent"
+msgstr "Usa la característica done per a acabar el corrent"
#: builtin/fast-export.c:996
msgid "Skip output of blob data"
@@ -5183,11 +5196,11 @@ msgstr "annexa a .git/FETCH_HEAD en lloc de sobreescriure"
#: builtin/fetch.c:94
msgid "path to upload pack on remote end"
-msgstr "ruta a que pujar el paquet en el costat remot"
+msgstr "camí al qual pujar el paquet en el costat remot"
#: builtin/fetch.c:95
msgid "force overwrite of local branch"
-msgstr "força la sobreescriptura de la rama local"
+msgstr "força la sobreescriptura de la branca local"
#: builtin/fetch.c:97
msgid "fetch from multiple remotes"
@@ -5195,15 +5208,15 @@ msgstr "obtén de múltiples remots"
#: builtin/fetch.c:99
msgid "fetch all tags and associated objects"
-msgstr "obtén tots les etiquetes i objectes associats"
+msgstr "obtén totes les etiquetes i tots els objectes associats"
#: builtin/fetch.c:101
msgid "do not fetch all tags (--no-tags)"
-msgstr "no obtingues les etiquetes (--no-tags)"
+msgstr "no obtinguis les etiquetes (--no-tags)"
#: builtin/fetch.c:103
msgid "prune remote-tracking branches no longer on remote"
-msgstr "poda les rames amb seguiment remot que ja no estiguin en el remot"
+msgstr "poda les branques amb seguiment remot que ja no estiguin en el remot"
#: builtin/fetch.c:104
msgid "on-demand"
@@ -5235,7 +5248,7 @@ msgstr "directori"
#: builtin/fetch.c:119
msgid "prepend this to submodule path output"
-msgstr "anteposa això a la sortida de ruta del submòdul"
+msgstr "anteposa això a la sortida de camí del submòdul"
#: builtin/fetch.c:122
msgid "default mode for recursion"
@@ -5269,7 +5282,7 @@ msgstr "[al dia]"
#: builtin/fetch.c:473
#, c-format
msgid "! %-*s %-*s -> %s (can't fetch in current branch)"
-msgstr "! %-*s %-*s -> %s (no es pot obtenir en la rama actual)"
+msgstr "! %-*s %-*s -> %s (no es pot obtenir en la branca actual)"
#: builtin/fetch.c:474 builtin/fetch.c:560
msgid "[rejected]"
@@ -5281,7 +5294,7 @@ msgstr "[actualització d'etiqueta]"
#: builtin/fetch.c:487 builtin/fetch.c:522 builtin/fetch.c:540
msgid " (unable to update local ref)"
-msgstr " (incapaç d'actualitzar la referència local)"
+msgstr " (no s'ha pogut actualitzar la referència local)"
#: builtin/fetch.c:505
msgid "[new tag]"
@@ -5289,7 +5302,7 @@ msgstr "[etiqueta nova]"
#: builtin/fetch.c:508
msgid "[new branch]"
-msgstr "[rama nova]"
+msgstr "[branca nova]"
#: builtin/fetch.c:511
msgid "[new ref]"
@@ -5297,7 +5310,7 @@ msgstr "[referència nova]"
#: builtin/fetch.c:556
msgid "unable to update local ref"
-msgstr "incapaç d'actualitzar la referència local"
+msgstr "no s'ha pogut actualitzar la referència local"
#: builtin/fetch.c:556
msgid "forced update"
@@ -5310,7 +5323,7 @@ msgstr "(sense avanç ràpid)"
#: builtin/fetch.c:595 builtin/fetch.c:828
#, c-format
msgid "cannot open %s: %s\n"
-msgstr "no és pot obrir %s: %s\n"
+msgstr "no es pot obrir %s: %s\n"
#: builtin/fetch.c:604
#, c-format
@@ -5321,7 +5334,7 @@ msgstr "%s no ha enviat tots els objectes necessaris\n"
#, c-format
msgid "reject %s because shallow roots are not allowed to be updated"
msgstr ""
-"rebutja %s perquè no es permet que els arrels superficials s'actualitzin"
+"rebutja %s perquè no es permet que les arrels superficials s'actualitzin"
#: builtin/fetch.c:710 builtin/fetch.c:793
#, c-format
@@ -5335,8 +5348,8 @@ msgid ""
" 'git remote prune %s' to remove any old, conflicting branches"
msgstr ""
"algunes referències locals no s'han pogut actualitzar;\n"
-" intenteu executar 'git remote prune %s' per a treure\n"
-" qualsevulla rama antiga o conflictiva"
+" intenteu executar 'git remote prune %s' per a eliminar\n"
+" qualsevulla branca antiga o conflictiva"
#: builtin/fetch.c:773
#, c-format
@@ -5352,14 +5365,14 @@ msgstr " (%s s'ha tornat penjant)"
msgid "[deleted]"
msgstr "[suprimit]"
-#: builtin/fetch.c:799 builtin/remote.c:1063
+#: builtin/fetch.c:799 builtin/remote.c:1060
msgid "(none)"
msgstr "(cap)"
#: builtin/fetch.c:818
#, c-format
msgid "Refusing to fetch into current branch %s of non-bare repository"
-msgstr "Refusant obtenir en la rama actual %s d'un dipòsit no nu"
+msgstr "Refusant obtenir en la branca actual %s d'un dipòsit no nu"
#: builtin/fetch.c:837
#, c-format
@@ -5428,75 +5441,75 @@ msgid "git fmt-merge-msg [-m <message>] [--log[=<n>]|--no-log] [--file <file>]"
msgstr ""
"git fmt-merge-msg [-m <missatge>] [--log[=<n>]|--no-log] [--file <fitxer>]"
-#: builtin/fmt-merge-msg.c:663 builtin/fmt-merge-msg.c:666 builtin/grep.c:698
-#: builtin/merge.c:197 builtin/repack.c:179 builtin/repack.c:183
-#: builtin/show-branch.c:654 builtin/show-ref.c:178 builtin/tag.c:590
+#: builtin/fmt-merge-msg.c:662 builtin/fmt-merge-msg.c:665 builtin/grep.c:698
+#: builtin/merge.c:198 builtin/repack.c:178 builtin/repack.c:182
+#: builtin/show-branch.c:657 builtin/show-ref.c:178 builtin/tag.c:590
#: parse-options.h:132 parse-options.h:239
msgid "n"
msgstr "n"
-#: builtin/fmt-merge-msg.c:664
+#: builtin/fmt-merge-msg.c:663
msgid "populate log with at most <n> entries from shortlog"
-msgstr "emplena el registre amb al màxim <n> entrades del registre curt"
+msgstr "emplena el registre amb <n> entrades del registre curt com a màxim"
-#: builtin/fmt-merge-msg.c:667
+#: builtin/fmt-merge-msg.c:666
msgid "alias for --log (deprecated)"
msgstr "àlies per --log (desaprovat)"
-#: builtin/fmt-merge-msg.c:670
+#: builtin/fmt-merge-msg.c:669
msgid "text"
msgstr "text"
-#: builtin/fmt-merge-msg.c:671
+#: builtin/fmt-merge-msg.c:670
msgid "use <text> as start of message"
msgstr "usa <text> com a inici de missatge"
-#: builtin/fmt-merge-msg.c:672
+#: builtin/fmt-merge-msg.c:671
msgid "file to read from"
msgstr "fitxer del qual llegir"
#: builtin/for-each-ref.c:676
msgid "unable to parse format"
-msgstr "incapaç d'analitzar el format"
+msgstr "no s'ha pogut analitzar el format"
-#: builtin/for-each-ref.c:1057
+#: builtin/for-each-ref.c:1064
msgid "git for-each-ref [options] [<pattern>]"
msgstr "git for-each-ref [opcions] [<patró>]"
-#: builtin/for-each-ref.c:1072
+#: builtin/for-each-ref.c:1079
msgid "quote placeholders suitably for shells"
msgstr ""
"posa els marcadors de posició entre cometes adequades per als terminals"
-#: builtin/for-each-ref.c:1074
+#: builtin/for-each-ref.c:1081
msgid "quote placeholders suitably for perl"
msgstr "posa els marcadors de posició entre cometes adequades per a perl"
-#: builtin/for-each-ref.c:1076
+#: builtin/for-each-ref.c:1083
msgid "quote placeholders suitably for python"
msgstr "posa els marcadors de posició entre cometes adequades per a python"
-#: builtin/for-each-ref.c:1078
-msgid "quote placeholders suitably for tcl"
-msgstr "posa els marcadors de posició entre cometes adequades per a tcl"
+#: builtin/for-each-ref.c:1085
+msgid "quote placeholders suitably for Tcl"
+msgstr "posa els marcadors de posició entre cometes adequades per a Tcl"
-#: builtin/for-each-ref.c:1081
+#: builtin/for-each-ref.c:1088
msgid "show only <n> matched refs"
msgstr "mostra només <n> referències coincidents"
-#: builtin/for-each-ref.c:1082 builtin/replace.c:438
+#: builtin/for-each-ref.c:1089 builtin/replace.c:438
msgid "format"
msgstr "format"
-#: builtin/for-each-ref.c:1082
+#: builtin/for-each-ref.c:1089
msgid "format to use for the output"
msgstr "format a usar en la sortida"
-#: builtin/for-each-ref.c:1083
+#: builtin/for-each-ref.c:1090
msgid "key"
msgstr "clau"
-#: builtin/for-each-ref.c:1084
+#: builtin/for-each-ref.c:1091
msgid "field name to sort on"
msgstr "nom de camp en el qual ordenar"
@@ -5563,12 +5576,12 @@ msgstr "git gc [opcions]"
#: builtin/gc.c:79
#, c-format
msgid "Invalid gc.pruneexpire: '%s'"
-msgstr "gc.pruneexpire invàlid: %s"
+msgstr "gc.pruneexpire no vàlid: %s"
#: builtin/gc.c:107
#, c-format
msgid "insanely long object directory %.*s"
-msgstr "directori d'objectes increïblement llarga %.*s"
+msgstr "directori d'objectes increïblement llarg %.*s"
#: builtin/gc.c:276
msgid "prune unreferenced objects"
@@ -5576,7 +5589,7 @@ msgstr "poda objectes sense referència"
#: builtin/gc.c:278
msgid "be more thorough (increased runtime)"
-msgstr "siguis més exhaustiu (temps d'execució augmentat)"
+msgstr "sigues més exhaustiu (el temps d'execució augmenta)"
#: builtin/gc.c:279
msgid "enable auto-gc mode"
@@ -5600,7 +5613,7 @@ msgstr "Empaquetant automàticament el dipòsit per rendiment òptim.\n"
#: builtin/gc.c:324
#, c-format
msgid "See \"git help gc\" for manual housekeeping.\n"
-msgstr "Veu \"git help gc\" per neteja manual.\n"
+msgstr "Vegeu \"git help gc\" per neteja manual.\n"
#: builtin/gc.c:342
#, c-format
@@ -5613,12 +5626,12 @@ msgstr ""
msgid ""
"There are too many unreachable loose objects; run 'git prune' to remove them."
msgstr ""
-"Hi ha massa objectes solts inabastables; executeu 'git prune' per a "
-"treure'ls."
+"Hi ha massa objectes solts inabastables; executeu 'git prune' per a eliminar-"
+"los."
#: builtin/grep.c:23
msgid "git grep [options] [-e] <pattern> [<rev>...] [[--] <path>...]"
-msgstr "git grep [opcions] [-e] <patró> [<revisió>...] [[--] <ruta>...]"
+msgstr "git grep [opcions] [-e] <patró> [<revisió>...] [[--] <camí>...]"
#: builtin/grep.c:218
#, c-format
@@ -5628,7 +5641,7 @@ msgstr "grep: s'ha fallat en crear fil: %s"
#: builtin/grep.c:441 builtin/grep.c:476
#, c-format
msgid "unable to read tree (%s)"
-msgstr "incapaç de llegir l'arbre (%s)"
+msgstr "no s'ha pogut llegir l'arbre (%s)"
#: builtin/grep.c:491
#, c-format
@@ -5638,7 +5651,7 @@ msgstr "no es pot fer grep des d'un objecte de tipus %s"
#: builtin/grep.c:547
#, c-format
msgid "switch `%c' expects a numerical value"
-msgstr "l'ópcio `%c' espera un valor numèric"
+msgstr "l'opció `%c' espera un valor numèric"
#: builtin/grep.c:564
#, c-format
@@ -5655,7 +5668,7 @@ msgstr "cerca en continguts no gestionats per git"
#: builtin/grep.c:642
msgid "search in both tracked and untracked files"
-msgstr "cerca en ambdós els fitxers seguits i no seguits"
+msgstr "cerca tant en fitxers seguits com en no seguits"
#: builtin/grep.c:644
msgid "search also in ignored files"
@@ -5727,7 +5740,7 @@ msgstr "mostra només els noms de fitxer en lloc de les línies coincidents"
#: builtin/grep.c:684
msgid "synonym for --files-with-matches"
-msgstr "sinònim per --files-with-matches"
+msgstr "sinònim de --files-with-matches"
#: builtin/grep.c:687
msgid "show only the names of files without match"
@@ -5747,7 +5760,7 @@ msgstr "ressalta les coincidències"
#: builtin/grep.c:694
msgid "print empty line between matches from different files"
-msgstr "imprimeix una línia buida entre coincidències de fitxers distintes"
+msgstr "imprimeix una línia buida entre coincidències de fitxers distints"
#: builtin/grep.c:696
msgid "show filename only once above matches from same file"
@@ -5777,7 +5790,7 @@ msgstr "mostra una línia amb el nom de funció abans de les coincidències"
#: builtin/grep.c:710
msgid "show the surrounding function"
-msgstr "mostra la funció alrededor"
+msgstr "mostra la funció circumdant"
#: builtin/grep.c:713
msgid "read patterns from file"
@@ -5855,7 +5868,7 @@ msgstr ""
#: builtin/hash-object.c:83
msgid "git hash-object --stdin-paths < <list-of-paths>"
-msgstr "git hash-object --stdin-paths < <llista-de-rutes>"
+msgstr "git hash-object --stdin-paths < <llista-de-camins>"
#: builtin/hash-object.c:94 builtin/tag.c:610
msgid "type"
@@ -5881,16 +5894,16 @@ msgstr "emmagatzema el fitxer tal com és sense filtres"
msgid ""
"just hash any random garbage to create corrupt objects for debugging Git"
msgstr ""
-"només sumar qualsevulla brossa aleatòria per a crear objectes corruptes per "
-"a depurar al Git"
+"només suma qualsevulla brossa aleatòria per a crear objectes corruptes per a "
+"depurar al Git"
#: builtin/hash-object.c:101
msgid "process file as it were from this path"
-msgstr "processa el fitxer com si fos d'aquesta ruta"
+msgstr "processa el fitxer com si fos d'aquest camí"
#: builtin/help.c:41
msgid "print all available commands"
-msgstr "imprimeix tots els ordres disponibles"
+msgstr "imprimeix totes les ordres disponibles"
#: builtin/help.c:42
msgid "print list of useful guides"
@@ -5923,7 +5936,7 @@ msgstr "S'ha fallat en iniciar emacsclient."
#: builtin/help.c:104
msgid "Failed to parse emacsclient version."
-msgstr "S'ha fallat en analitzar la versió d'emacsclint."
+msgstr "S'ha fallat en analitzar la versió d'emacsclient."
#: builtin/help.c:112
#, c-format
@@ -5941,8 +5954,8 @@ msgid ""
"'%s': path for unsupported man viewer.\n"
"Please consider using 'man.<tool>.cmd' instead."
msgstr ""
-"'%s': ruta a un visualitzador de manuals no suportat.\n"
-"Si us plau, considereu usar 'man.<eine>.cmd' en lloc."
+"'%s': camí a un visualitzador de manuals no compatible.\n"
+"Si us plau, considereu usar 'man.<eina>.cmd' en lloc d'això."
#: builtin/help.c:227
#, c-format
@@ -5950,72 +5963,72 @@ msgid ""
"'%s': cmd for supported man viewer.\n"
"Please consider using 'man.<tool>.path' instead."
msgstr ""
-"'%s': ordre per un visualitzador de manuals suportat.\n"
-"Si us plau, considereu usar 'man.<eine>.path' en lloc."
+"'%s': ordre per a un visualitzador de manuals compatible.\n"
+"Si us plau, considereu usar 'man.<eina>.path' en lloc d'això."
-#: builtin/help.c:352
+#: builtin/help.c:354
#, c-format
msgid "'%s': unknown man viewer."
msgstr "'%s': visualitzador de manuals desconegut"
-#: builtin/help.c:369
+#: builtin/help.c:371
msgid "no man viewer handled the request"
-msgstr "cap visualitzador de manuals ha manejat la sol·licitud"
+msgstr "cap visualitzador de manuals ha gestionat la sol·licitud"
-#: builtin/help.c:377
+#: builtin/help.c:379
msgid "no info viewer handled the request"
-msgstr "cap visualitzador d'informació ha manejat la sol·licitud"
+msgstr "cap visualitzador d'informació ha gestionat la sol·licitud"
-#: builtin/help.c:423
+#: builtin/help.c:428
msgid "Defining attributes per path"
-msgstr "La definició d'atributs per ruta"
+msgstr "La definició d'atributs per camí"
-#: builtin/help.c:424
+#: builtin/help.c:429
msgid "Everyday Git With 20 Commands Or So"
msgstr "Git quotidià amb més o menys 20 ordres"
-#: builtin/help.c:425
+#: builtin/help.c:430
msgid "A Git glossary"
msgstr "Un glossari de Git"
-#: builtin/help.c:426
+#: builtin/help.c:431
msgid "Specifies intentionally untracked files to ignore"
msgstr "Especifica els fitxers intencionalment no seguits a ignorar"
-#: builtin/help.c:427
+#: builtin/help.c:432
msgid "Defining submodule properties"
msgstr "La definició de les propietats de submòduls"
-#: builtin/help.c:428
+#: builtin/help.c:433
msgid "Specifying revisions and ranges for Git"
msgstr "L'especificació de revisions i rangs per al Git"
-#: builtin/help.c:429
+#: builtin/help.c:434
msgid "A tutorial introduction to Git (for version 1.5.1 or newer)"
msgstr "Una introducció tutorial al Git (per a la versió 1.5.1 o més nou)"
-#: builtin/help.c:430
+#: builtin/help.c:435
msgid "An overview of recommended workflows with Git"
msgstr "Una visió de conjunt de fluxos de treball recomanats amb Git"
-#: builtin/help.c:442
+#: builtin/help.c:447
msgid "The common Git guides are:\n"
msgstr "Les guies de Git comunes són:\n"
-#: builtin/help.c:463 builtin/help.c:480
+#: builtin/help.c:468 builtin/help.c:485
#, c-format
msgid "usage: %s%s"
msgstr "ús: %s%s"
-#: builtin/help.c:496
+#: builtin/help.c:501
#, c-format
msgid "`git %s' is aliased to `%s'"
-msgstr "`git %s' és àlies a `%s'"
+msgstr "`git %s' és un àlies de `%s'"
#: builtin/index-pack.c:150
#, c-format
msgid "unable to open %s"
-msgstr "incapaç d'obrir %s"
+msgstr "no s'ha pogut obrir %s"
#: builtin/index-pack.c:200
#, c-format
@@ -6041,7 +6054,7 @@ msgstr[1] "no es pot omplir %d octets"
#: builtin/index-pack.c:275
msgid "early EOF"
-msgstr "EOF aviat"
+msgstr "EOF prematur"
#: builtin/index-pack.c:276
msgid "read error on input"
@@ -6049,7 +6062,7 @@ msgstr "error de lectura d'entrada"
#: builtin/index-pack.c:288
msgid "used more bytes than were available"
-msgstr "s'han usat més octets que estaven disponibles"
+msgstr "s'han usat més octets dels que hi havia disponibles"
#: builtin/index-pack.c:295
msgid "pack too large for current definition of off_t"
@@ -6072,12 +6085,12 @@ msgstr "hi ha una discordança de firma de paquet"
#: builtin/index-pack.c:332
#, c-format
msgid "pack version %<PRIu32> unsupported"
-msgstr "la versió de paquet %<PRIu32> no es suporta"
+msgstr "la versió de paquet %<PRIu32> no és compatible"
#: builtin/index-pack.c:350
#, c-format
msgid "pack has bad object at offset %lu: %s"
-msgstr "el paquet té un objecte dolent a desplaçament %lu: %s"
+msgstr "el paquet té un objecte dolent a la posició %lu: %s"
#: builtin/index-pack.c:471
#, c-format
@@ -6105,12 +6118,12 @@ msgstr "no es pot fer pread en el fitxer de paquet"
#, c-format
msgid "premature end of pack file, %lu byte missing"
msgid_plural "premature end of pack file, %lu bytes missing"
-msgstr[0] "fin prematur de fitxer de paquet, manca %lu octet"
-msgstr[1] "fin prematur de fitxer de paquet, manquen %lu octets"
+msgstr[0] "final prematur de fitxer de paquet, manca %lu octet"
+msgstr[1] "final prematur de fitxer de paquet, manquen %lu octets"
#: builtin/index-pack.c:595
msgid "serious inflate inconsistency"
-msgstr "hi ha una inconsistència seria d'inflació"
+msgstr "hi ha una inconsistència seriosa d'inflació"
#: builtin/index-pack.c:686 builtin/index-pack.c:692 builtin/index-pack.c:715
#: builtin/index-pack.c:749 builtin/index-pack.c:758
@@ -6122,7 +6135,7 @@ msgstr "S'HA TROBAT UNA COL·LISIÓ SHA1 AMB %s !"
#: builtin/pack-objects.c:256
#, c-format
msgid "unable to read %s"
-msgstr "incapaç de llegir %s"
+msgstr "no s'ha pogut llegir %s"
#: builtin/index-pack.c:755
#, c-format
@@ -6132,12 +6145,12 @@ msgstr "no es pot llegir l'objecte existent %s"
#: builtin/index-pack.c:769
#, c-format
msgid "invalid blob object %s"
-msgstr "objecte de blob invàlid %s"
+msgstr "objecte de blob no vàlid %s"
#: builtin/index-pack.c:783
#, c-format
msgid "invalid %s"
-msgstr "%s invàlid"
+msgstr "%s no vàlid"
#: builtin/index-pack.c:787
msgid "Error in object"
@@ -6170,7 +6183,7 @@ msgstr "no es pot fer fstat en el fitxer de paquet"
#: builtin/index-pack.c:1089
msgid "pack has junk at the end"
-msgstr "el paquet té brossa al seu fin"
+msgstr "el paquet té brossa al seu final"
#: builtin/index-pack.c:1100
msgid "confusion beyond insanity in parse_pack_objects()"
@@ -6183,7 +6196,7 @@ msgstr "Resolent les deltes"
#: builtin/index-pack.c:1133
#, c-format
msgid "unable to create thread: %s"
-msgstr "incapaç de crear fil: %s"
+msgstr "no s'ha pogut crear fil: %s"
#: builtin/index-pack.c:1175
msgid "confusion beyond insanity"
@@ -6192,7 +6205,7 @@ msgstr "confusió més enllà de la insanitat"
#: builtin/index-pack.c:1181
#, c-format
msgid "completed with %d local objects"
-msgstr "s'ha terminat amb %d objectes locals"
+msgstr "s'ha completat amb %d objectes locals"
#: builtin/index-pack.c:1191
#, c-format
@@ -6209,7 +6222,7 @@ msgstr[1] "El paquet té %d deltes no resoltes"
#: builtin/index-pack.c:1220
#, c-format
msgid "unable to deflate appended object (%d)"
-msgstr "incapaç de desinflar l'objecte annexat (%d)"
+msgstr "no s'ha pogut desinflar l'objecte annexat (%d)"
#: builtin/index-pack.c:1299
#, c-format
@@ -6246,7 +6259,7 @@ msgstr "pack.indexversion=%<PRIu32> dolent"
#: builtin/index-pack.c:1407
#, c-format
msgid "invalid number of threads specified (%d)"
-msgstr "s'ha especificat un nombre de fils invàlid (%d)"
+msgstr "s'ha especificat un nombre de fils no vàlid (%d)"
#: builtin/index-pack.c:1411 builtin/index-pack.c:1590
#, c-format
@@ -6294,7 +6307,7 @@ msgstr "--fix-thin no es pot usar sense --stdin"
#: builtin/index-pack.c:1639 builtin/index-pack.c:1648
#, c-format
msgid "packfile name '%s' does not end with '.pack'"
-msgstr "el nom de fitxer de paquet '%s' no termina amb '.pack'"
+msgstr "el nom de fitxer de paquet '%s' no acaba amb '.pack'"
#: builtin/index-pack.c:1656
msgid "--verify with no packfile name given"
@@ -6303,12 +6316,12 @@ msgstr "s'ha donat --verify sense nom de fitxer de paquet"
#: builtin/init-db.c:35
#, c-format
msgid "Could not make %s writable by group"
-msgstr "No s'ha pogut fer %s escrivible pel grup"
+msgstr "No s'ha pogut fer %s gravable per al grup"
#: builtin/init-db.c:62
#, c-format
msgid "insanely long template name %s"
-msgstr "nom de plantilla insanament llarg %s"
+msgstr "nom de plantilla increïblement llarg %s"
#: builtin/init-db.c:67
#, c-format
@@ -6333,7 +6346,7 @@ msgstr "no es pot fer readlink en '%s'"
#: builtin/init-db.c:99
#, c-format
msgid "insanely long symlink %s"
-msgstr "enllaç simbòlic insanament llarg %s"
+msgstr "enllaç simbòlic increïblement llarg %s"
#: builtin/init-db.c:102
#, c-format
@@ -6350,62 +6363,62 @@ msgstr "no es pot copiar '%s' a '%s'"
msgid "ignoring template %s"
msgstr "ignorant la plantilla %s"
-#: builtin/init-db.c:133
+#: builtin/init-db.c:136
#, c-format
msgid "insanely long template path %s"
-msgstr "ruta de plantilla insanament llarg %s"
+msgstr "camí de plantilla increïblement llarg %s"
-#: builtin/init-db.c:141
+#: builtin/init-db.c:144
#, c-format
msgid "templates not found %s"
msgstr "no s'han trobat les plantilles %s"
-#: builtin/init-db.c:154
+#: builtin/init-db.c:157
#, c-format
msgid "not copying templates of a wrong format version %d from '%s'"
msgstr "no copiant plantilles d'una versió de format errònia %d de '%s'"
-#: builtin/init-db.c:192
+#: builtin/init-db.c:197
#, c-format
msgid "insane git directory %s"
msgstr "directori de git boig %s"
-#: builtin/init-db.c:323 builtin/init-db.c:326
+#: builtin/init-db.c:331 builtin/init-db.c:334
#, c-format
msgid "%s already exists"
msgstr "%s ja existeix"
-#: builtin/init-db.c:355
+#: builtin/init-db.c:363
#, c-format
msgid "unable to handle file type %d"
-msgstr "incapaç de manejar el tipus de fitxer %d"
+msgstr "no s'ha pogut gestionar el tipus de fitxer %d"
-#: builtin/init-db.c:358
+#: builtin/init-db.c:366
#, c-format
msgid "unable to move %s to %s"
-msgstr "incapaç de moure %s a %s"
+msgstr "no s'ha pogut moure %s a %s"
#. TRANSLATORS: The first '%s' is either "Reinitialized
#. existing" or "Initialized empty", the second " shared" or
#. "", and the last '%s%s' is the verbatim directory name.
-#: builtin/init-db.c:418
+#: builtin/init-db.c:426
#, c-format
msgid "%s%s Git repository in %s%s\n"
-msgstr "%s%s dipòsit de Git en %s%s\n"
+msgstr "%s dipòsit de Git%s a %s%s\n"
-#: builtin/init-db.c:419
+#: builtin/init-db.c:427
msgid "Reinitialized existing"
msgstr "S'ha reinicialitzat un existent"
-#: builtin/init-db.c:419
+#: builtin/init-db.c:427
msgid "Initialized empty"
msgstr "S'ha inicialitzat un buit"
-#: builtin/init-db.c:420
+#: builtin/init-db.c:428
msgid " shared"
msgstr " compartit"
-#: builtin/init-db.c:467
+#: builtin/init-db.c:475
msgid ""
"git init [-q | --quiet] [--bare] [--template=<template-directory>] [--"
"shared[=<permissions>]] [directory]"
@@ -6413,29 +6426,29 @@ msgstr ""
"git init [-q | --quiet] [--bare] [--template=<directori-de-plantilla>] [--"
"shared[=<permisos>]] [directori]"
-#: builtin/init-db.c:490
+#: builtin/init-db.c:498
msgid "permissions"
msgstr "permisos"
-#: builtin/init-db.c:491
+#: builtin/init-db.c:499
msgid "specify that the git repository is to be shared amongst several users"
msgstr "especifica que el dipòsit de git es compartirà entre diversos usuaris"
-#: builtin/init-db.c:493 builtin/prune-packed.c:57 builtin/repack.c:172
+#: builtin/init-db.c:501 builtin/prune-packed.c:57 builtin/repack.c:171
msgid "be quiet"
msgstr "calla"
-#: builtin/init-db.c:525 builtin/init-db.c:530
+#: builtin/init-db.c:533 builtin/init-db.c:538
#, c-format
msgid "cannot mkdir %s"
msgstr "no es pot mkdir %s"
-#: builtin/init-db.c:534
+#: builtin/init-db.c:542
#, c-format
msgid "cannot chdir to %s"
msgstr "no es pot chdir a %s"
-#: builtin/init-db.c:555
+#: builtin/init-db.c:563
#, c-format
msgid ""
"%s (or --work-tree=<directory>) not allowed without specifying %s (or --git-"
@@ -6444,10 +6457,10 @@ msgstr ""
"no es permet %s (o --work-tree=<directori>) sense especificar %s (o --git-"
"dir=<directori>)"
-#: builtin/init-db.c:583
+#: builtin/init-db.c:591
#, c-format
msgid "Cannot access work tree '%s'"
-msgstr "No es pot accedir al arbre de treball '%s'"
+msgstr "No es pot accedir a l'arbre de treball '%s'"
#: builtin/interpret-trailers.c:15
msgid ""
@@ -6470,17 +6483,17 @@ msgid "trailer(s) to add"
msgstr "remolcs a afegir"
#: builtin/log.c:41
-msgid "git log [<options>] [<revision range>] [[--] <path>...]\n"
-msgstr "git log [<opcions>] [<rang de revisions>] [[--] <ruta>...]\n"
+msgid "git log [<options>] [<revision range>] [[--] <path>...]"
+msgstr "git log [<opcions>] [<rang de revisions>] [[--] <camí>...]"
#: builtin/log.c:42
-msgid " or: git show [options] <object>..."
-msgstr " o: git show [opcions] <objecte>..."
+msgid "git show [options] <object>..."
+msgstr "git show [opcions] <objecte>..."
#: builtin/log.c:81
#, c-format
msgid "invalid --decorate option: %s"
-msgstr "opció --decorate invàlida: %s"
+msgstr "opció --decorate no vàlida: %s"
#: builtin/log.c:127
msgid "suppress diff output"
@@ -6562,11 +6575,11 @@ msgstr "Dos directoris de sortida?"
#: builtin/log.c:1186
msgid "use [PATCH n/m] even with a single patch"
-msgstr "usa [PATCH n/m] encara amb un pedaç solter"
+msgstr "usa [PATCH n/m] fins i tot amb un sol pedaç"
#: builtin/log.c:1189
msgid "use [PATCH] even with multiple patches"
-msgstr "usa [PATCH] encara amb múltiples pedaços"
+msgstr "usa [PATCH] fins i tot amb múltiples pedaços"
#: builtin/log.c:1193
msgid "print patches to standard out"
@@ -6594,7 +6607,7 @@ msgstr "comença nombrant els pedaços a <n> en lloc d'1"
#: builtin/log.c:1203
msgid "mark the series as Nth re-roll"
-msgstr "marca la sèrie com a la Nª llançada"
+msgstr "marca la sèrie com a l'enèsima llançada"
#: builtin/log.c:1205
msgid "Use [<prefix>] instead of [PATCH]"
@@ -6602,7 +6615,7 @@ msgstr "Usa [<prefix>] en lloc de [PATCH]"
#: builtin/log.c:1208
msgid "store resulting files in <dir>"
-msgstr "emmagatzema els fitxers resultants en <directori>"
+msgstr "emmagatzema els fitxers resultants a <directori>"
#: builtin/log.c:1211
msgid "don't strip/add [PATCH]"
@@ -6652,7 +6665,7 @@ msgstr "identitat"
#: builtin/log.c:1228
msgid "set From address to <ident> (or committer ident if absent)"
msgstr ""
-"estableix l'adreça From a <identitat> (o la identitat del comitent si absent)"
+"estableix l'adreça From a <identitat> (o la identitat del comitent si manca)"
#: builtin/log.c:1230
msgid "message-id"
@@ -6660,7 +6673,7 @@ msgstr "ID de missatge"
#: builtin/log.c:1231
msgid "make first mail a reply to <message-id>"
-msgstr "fes el primer missatge una resposta a <ID de missatge>"
+msgstr "fes del primer missatge una resposta a <ID de missatge>"
#: builtin/log.c:1232 builtin/log.c:1235
msgid "boundary"
@@ -6697,7 +6710,7 @@ msgstr "no imprimeixis els noms de fitxer del pedaç"
#: builtin/log.c:1320
#, c-format
msgid "invalid ident line: %s"
-msgstr "línia d'identitat invàlida: %s"
+msgstr "línia d'identitat no vàlida: %s"
#: builtin/log.c:1335
msgid "-n and -k are mutually exclusive."
@@ -6721,7 +6734,7 @@ msgstr "--check no té sentit"
#: builtin/log.c:1372
msgid "standard output, or directory, which one?"
-msgstr "sortida estàndard, o directori, qual dels dos?"
+msgstr "sortida estàndard o directori, quin dels dos?"
#: builtin/log.c:1374
#, c-format
@@ -6731,7 +6744,7 @@ msgstr "No s'ha pogut crear el directori '%s'"
#: builtin/log.c:1472
#, c-format
msgid "unable to read signature file '%s'"
-msgstr "incapaç de llegir el fitxer de firma '%s'"
+msgstr "no s'ha pogut llegir el fitxer de firma '%s'"
#: builtin/log.c:1535
msgid "Failed to create output files"
@@ -6746,7 +6759,7 @@ msgstr "git cherry [-v] [<font> [<cap> [<límit>]]]"
msgid ""
"Could not find a tracked remote branch, please specify <upstream> manually.\n"
msgstr ""
-"No s'ha pogut trobar una rama remota seguida, si us plau, especifiqueu "
+"No s'ha pogut trobar una branca remota seguida. Si us plau, especifiqueu "
"<font> manualment.\n"
#: builtin/log.c:1651 builtin/log.c:1653 builtin/log.c:1665
@@ -6768,31 +6781,32 @@ msgstr "usa lletres minúscules per als fitxers 'assume unchanged'"
#: builtin/ls-files.c:462
msgid "show cached files in the output (default)"
-msgstr "mostra els fitxers en cau en la sortida (per defecte)"
+msgstr ""
+"mostra en la sortida els fitxers desats en la memòria cau (per defecte)"
#: builtin/ls-files.c:464
msgid "show deleted files in the output"
-msgstr "mostra els fitxers suprimits en la sortida"
+msgstr "mostra en la sortida els fitxers suprimits"
#: builtin/ls-files.c:466
msgid "show modified files in the output"
-msgstr "mostra els fitxers modificats en la sortida"
+msgstr "mostra en la sortida els fitxers modificats"
#: builtin/ls-files.c:468
msgid "show other files in the output"
-msgstr "mostra els altres fitxers en la sortida"
+msgstr "mostra en la sortida els altres fitxers"
#: builtin/ls-files.c:470
msgid "show ignored files in the output"
-msgstr "mostra els fitxers ignorats en la sortida"
+msgstr "mostra en la sortida els fitxers ignorats"
#: builtin/ls-files.c:473
msgid "show staged contents' object name in the output"
-msgstr "mostra el nom d'objecte dels continguts allistats en la sortida"
+msgstr "mostra en la sortida el nom d'objecte dels continguts allistats"
#: builtin/ls-files.c:475
msgid "show files on the filesystem that need to be removed"
-msgstr "mostra els fitxers en el sistema de fitxers que s'han de treure"
+msgstr "mostra els fitxers en el sistema de fitxers que s'han d'eliminar"
#: builtin/ls-files.c:477
msgid "show 'other' directories' names only"
@@ -6804,7 +6818,7 @@ msgstr "no mostris els directoris buits"
#: builtin/ls-files.c:483
msgid "show unmerged files in the output"
-msgstr "mostra els fitxers sense fusionar en la sortida"
+msgstr "mostra en la sortida els fitxers sense fusionar"
#: builtin/ls-files.c:485
msgid "show resolve-undo information"
@@ -6828,7 +6842,7 @@ msgstr "afegeix les exclusions estàndards de git"
#: builtin/ls-files.c:498
msgid "make the output relative to the project top directory"
-msgstr "fes que la sortida sigui relativa al directori superior del project"
+msgstr "fes que la sortida sigui relativa al directori superior del projecte"
#: builtin/ls-files.c:501
msgid "if any <file> is not in the index, treat this as an error"
@@ -6841,7 +6855,7 @@ msgstr "arbre"
#: builtin/ls-files.c:503
msgid "pretend that paths removed since <tree-ish> are still present"
msgstr ""
-"pretenguis que les rutes tretes després de <arbre> encara estiguin presents"
+"pretén que els camins eliminats després de <arbre> encara estiguin presents"
#: builtin/ls-files.c:505
msgid "show debugging data"
@@ -6849,215 +6863,216 @@ msgstr "mostra les dades de depuració"
#: builtin/ls-tree.c:28
msgid "git ls-tree [<options>] <tree-ish> [<path>...]"
-msgstr "git ls-tree [<opcions>] <arbre> [<ruta>...]"
+msgstr "git ls-tree [<opcions>] <arbre> [<camí>...]"
-#: builtin/ls-tree.c:126
+#: builtin/ls-tree.c:127
msgid "only show trees"
msgstr "mostra només els arbres"
-#: builtin/ls-tree.c:128
+#: builtin/ls-tree.c:129
msgid "recurse into subtrees"
msgstr "recursa als subarbres"
-#: builtin/ls-tree.c:130
+#: builtin/ls-tree.c:131
msgid "show trees when recursing"
-msgstr "mostra els arbres al recursar"
+msgstr "mostra els arbres en recursar"
-#: builtin/ls-tree.c:133
+#: builtin/ls-tree.c:134
msgid "terminate entries with NUL byte"
-msgstr "termina les entrades amb un octet NUL"
+msgstr "acaba les entrades amb un octet NUL"
-#: builtin/ls-tree.c:134
+#: builtin/ls-tree.c:135
msgid "include object size"
msgstr "mida de l'objecte d'inclusió"
-#: builtin/ls-tree.c:136 builtin/ls-tree.c:138
+#: builtin/ls-tree.c:137 builtin/ls-tree.c:139
msgid "list only filenames"
msgstr "llista només els noms de fitxer"
-#: builtin/ls-tree.c:141
+#: builtin/ls-tree.c:142
msgid "use full path names"
-msgstr "usa els noms de ruta complets"
+msgstr "usa els noms de camí complets"
-#: builtin/ls-tree.c:143
+#: builtin/ls-tree.c:144
msgid "list entire tree; not just current directory (implies --full-name)"
-msgstr "llista l'arbre enter; no sol el directori actual (implica --full-name)"
+msgstr ""
+"llista l'arbre sencer; no només el directori actual (implica --full-name)"
-#: builtin/merge.c:44
+#: builtin/merge.c:45
msgid "git merge [options] [<commit>...]"
msgstr "git merge [opcions] [<comissió>...]"
-#: builtin/merge.c:45
+#: builtin/merge.c:46
msgid "git merge [options] <msg> HEAD <commit>"
msgstr "git merge [opcions] <missatge> HEAD <comissió>"
-#: builtin/merge.c:46
+#: builtin/merge.c:47
msgid "git merge --abort"
msgstr "git merge --abort"
-#: builtin/merge.c:99
+#: builtin/merge.c:100
msgid "switch `m' requires a value"
msgstr "l'opció `m' requereix un valor"
-#: builtin/merge.c:136
+#: builtin/merge.c:137
#, c-format
msgid "Could not find merge strategy '%s'.\n"
msgstr "No s'ha pogut trobar l'estratègia de fusió '%s'.\n"
-#: builtin/merge.c:137
+#: builtin/merge.c:138
#, c-format
msgid "Available strategies are:"
msgstr "Les estratègies disponibles són:"
-#: builtin/merge.c:142
+#: builtin/merge.c:143
#, c-format
msgid "Available custom strategies are:"
msgstr "Les estratègies personalitzades disponibles són:"
-#: builtin/merge.c:192
+#: builtin/merge.c:193
msgid "do not show a diffstat at the end of the merge"
msgstr "no mostris les estadístiques de diferència al final de la fusió"
-#: builtin/merge.c:195
+#: builtin/merge.c:196
msgid "show a diffstat at the end of the merge"
msgstr "mostra les estadístiques de diferència al final de la fusió"
-#: builtin/merge.c:196
+#: builtin/merge.c:197
msgid "(synonym to --stat)"
msgstr "(sinònim de --stat)"
-#: builtin/merge.c:198
+#: builtin/merge.c:199
msgid "add (at most <n>) entries from shortlog to merge commit message"
msgstr ""
"afegeix (com a màxim <n>) entrades del registre curt per a fusionar el "
"missatge de comissió"
-#: builtin/merge.c:201
+#: builtin/merge.c:202
msgid "create a single commit instead of doing a merge"
-msgstr "crea una comissió soltera en lloc de fusionar"
+msgstr "crea una única comissió en lloc de fusionar"
-#: builtin/merge.c:203
+#: builtin/merge.c:204
msgid "perform a commit if the merge succeeds (default)"
msgstr "realitza una comissió si la fusió té èxit (per defecte)"
-#: builtin/merge.c:205
+#: builtin/merge.c:206
msgid "edit message before committing"
msgstr "edita el missatge abans de cometre"
-#: builtin/merge.c:206
+#: builtin/merge.c:207
msgid "allow fast-forward (default)"
msgstr "permet l'avanç ràpid (per defecte)"
-#: builtin/merge.c:208
+#: builtin/merge.c:209
msgid "abort if fast-forward is not possible"
msgstr "avorta si l'avanç ràpid no és possible"
-#: builtin/merge.c:212
+#: builtin/merge.c:213
msgid "Verify that the named commit has a valid GPG signature"
msgstr "Verifica que la comissió anomenada tingui una firma GPG vàlida"
-#: builtin/merge.c:213 builtin/notes.c:741 builtin/revert.c:89
+#: builtin/merge.c:214 builtin/notes.c:753 builtin/revert.c:89
msgid "strategy"
msgstr "estratègia"
-#: builtin/merge.c:214
+#: builtin/merge.c:215
msgid "merge strategy to use"
msgstr "estratègia de fusió a usar"
-#: builtin/merge.c:215
+#: builtin/merge.c:216
msgid "option=value"
msgstr "opció=valor"
-#: builtin/merge.c:216
+#: builtin/merge.c:217
msgid "option for selected merge strategy"
msgstr "opció per a l'estratègia de fusió seleccionada"
-#: builtin/merge.c:218
+#: builtin/merge.c:219
msgid "merge commit message (for a non-fast-forward merge)"
-msgstr "missatge de comissió de fusió (per a una fusió no de avanç ràpid)"
+msgstr "missatge de comissió de fusió (per a una fusió no d'avanç ràpid)"
-#: builtin/merge.c:222
+#: builtin/merge.c:223
msgid "abort the current in-progress merge"
msgstr "avorta la fusió en curs actual"
-#: builtin/merge.c:250
+#: builtin/merge.c:251
msgid "could not run stash."
msgstr "no s'ha pogut executar stash."
-#: builtin/merge.c:255
+#: builtin/merge.c:256
msgid "stash failed"
msgstr "L'emmagatzemament ha fallat."
-#: builtin/merge.c:260
+#: builtin/merge.c:261
#, c-format
msgid "not a valid object: %s"
-msgstr "no és objecte vàlid: %s"
+msgstr "no és un objecte vàlid: %s"
-#: builtin/merge.c:279 builtin/merge.c:296
+#: builtin/merge.c:280 builtin/merge.c:297
msgid "read-tree failed"
msgstr "read-tree ha fallat"
-#: builtin/merge.c:326
+#: builtin/merge.c:327
msgid " (nothing to squash)"
msgstr " (res a aixafar)"
-#: builtin/merge.c:339
+#: builtin/merge.c:340
#, c-format
msgid "Squash commit -- not updating HEAD\n"
msgstr "Comissió d'aixafada -- no actualitzant HEAD\n"
-#: builtin/merge.c:371
+#: builtin/merge.c:372
msgid "Writing SQUASH_MSG"
msgstr "Escrivint SQUASH_MSG"
-#: builtin/merge.c:373
+#: builtin/merge.c:374
msgid "Finishing SQUASH_MSG"
-msgstr "Terminant SQUASH_MSG"
+msgstr "Finalitzant SQUASH_MSG"
-#: builtin/merge.c:396
+#: builtin/merge.c:397
#, c-format
msgid "No merge message -- not updating HEAD\n"
msgstr "Cap missatge de fusió -- no actualitzant HEAD\n"
-#: builtin/merge.c:446
+#: builtin/merge.c:447
#, c-format
msgid "'%s' does not point to a commit"
msgstr "'%s' no assenyala una comissió"
-#: builtin/merge.c:558
+#: builtin/merge.c:559
#, c-format
msgid "Bad branch.%s.mergeoptions string: %s"
msgstr "Cadena branch.%s.mergeoptions dolenta: %s"
-#: builtin/merge.c:653
+#: builtin/merge.c:654
msgid "git write-tree failed to write a tree"
msgstr "git write-tree ha fallat en escriure un arbre"
-#: builtin/merge.c:677
+#: builtin/merge.c:678
msgid "Not handling anything other than two heads merge."
-msgstr "No manejant res apart de la fusió de dos caps."
+msgstr "No gestionant res a part de la fusió de dos caps."
-#: builtin/merge.c:691
+#: builtin/merge.c:692
#, c-format
msgid "Unknown option for merge-recursive: -X%s"
msgstr "Opció desconeguda de merge-recursive: -X%s"
-#: builtin/merge.c:704
+#: builtin/merge.c:705
#, c-format
msgid "unable to write %s"
-msgstr "incapaç d'escriure %s"
+msgstr "no s'ha pogut escriure %s"
-#: builtin/merge.c:793
+#: builtin/merge.c:794
#, c-format
msgid "Could not read from '%s'"
msgstr "No s'ha pogut llegir de '%s'"
-#: builtin/merge.c:802
+#: builtin/merge.c:803
#, c-format
msgid "Not committing merge; use 'git commit' to complete the merge.\n"
-msgstr "No comitent la fusió; useu 'git commit' per a terminar la fusió.\n"
+msgstr "No cometent la fusió; useu 'git commit' per a completar la fusió.\n"
-#: builtin/merge.c:808
+#: builtin/merge.c:809
#, c-format
msgid ""
"Please enter a commit message to explain why this merge is necessary,\n"
@@ -7067,175 +7082,176 @@ msgid ""
"the commit.\n"
msgstr ""
"Si us plau, introduïu un missatge de comissió per a explicar per què\n"
-"aquesta fusió és necessari, especialment si fusiona una font\n"
-"actualitzada a una rama temàtica.\n"
+"aquesta fusió és necessària, especialment si fusiona una font\n"
+"actualitzada a una branca temàtica.\n"
"\n"
"S'ignoraran les línies que comencin amb '%c', i un missatge buit\n"
"avorta la comissió.\n"
-#: builtin/merge.c:832
+#: builtin/merge.c:833
msgid "Empty commit message."
msgstr "Missatge de comissió buit."
-#: builtin/merge.c:844
+#: builtin/merge.c:845
#, c-format
msgid "Wonderful.\n"
msgstr "Meravellós.\n"
-#: builtin/merge.c:907
+#: builtin/merge.c:900
#, c-format
msgid "Automatic merge failed; fix conflicts and then commit the result.\n"
msgstr ""
"La fusió automàtica ha fallat; arregleu els conflictes i després cometeu el "
"resultat.\n"
-#: builtin/merge.c:923
+#: builtin/merge.c:916
#, c-format
msgid "'%s' is not a commit"
msgstr "'%s' no és una comissió"
-#: builtin/merge.c:964
+#: builtin/merge.c:957
msgid "No current branch."
-msgstr "Cap rama actual."
+msgstr "Cap branca actual."
-#: builtin/merge.c:966
+#: builtin/merge.c:959
msgid "No remote for the current branch."
-msgstr "Cap remot per a la rama actual."
+msgstr "No hi ha cap remot per a la branca actual."
-#: builtin/merge.c:968
+#: builtin/merge.c:961
msgid "No default upstream defined for the current branch."
-msgstr "Cap font per defecte definida per a la rama actual."
+msgstr "No hi ha cap font per defecte definida per a la branca actual."
-#: builtin/merge.c:973
+#: builtin/merge.c:966
#, c-format
msgid "No remote-tracking branch for %s from %s"
-msgstr "Cap rama de seguiment remot per a %s de %s"
+msgstr "No hi ha cap branca de seguiment remot per a %s de %s"
-#: builtin/merge.c:1129
+#: builtin/merge.c:1122
msgid "There is no merge to abort (MERGE_HEAD missing)."
msgstr "No hi ha fusió a avortar (manca MERGE_HEAD)."
-#: builtin/merge.c:1145
+#: builtin/merge.c:1138
msgid ""
"You have not concluded your merge (MERGE_HEAD exists).\n"
"Please, commit your changes before you merge."
msgstr ""
-"No heu terminat la vostra fusió (MERGE_HEAD existeix).\n"
+"No heu completat la vostra fusió (MERGE_HEAD existeix).\n"
"Si us plau, cometeu els vostres canvis abans de fusionar."
-#: builtin/merge.c:1148 git-pull.sh:34
+#: builtin/merge.c:1141 git-pull.sh:34
msgid "You have not concluded your merge (MERGE_HEAD exists)."
-msgstr "No heu terminat la vostra fusió (MERGE_HEAD existeix)."
+msgstr "No heu completat la vostra fusió (MERGE_HEAD existeix)."
-#: builtin/merge.c:1152
+#: builtin/merge.c:1145
msgid ""
"You have not concluded your cherry-pick (CHERRY_PICK_HEAD exists).\n"
"Please, commit your changes before you merge."
msgstr ""
-"No heu terminat el vostre recull de cireres (CHERRY_PICK_HEAD existeix).\n"
+"No heu completat el vostre recull de cireres (CHERRY_PICK_HEAD existeix).\n"
"Si us plau, cometeu els vostres canvis abans de fusionar."
-#: builtin/merge.c:1155
+#: builtin/merge.c:1148
msgid "You have not concluded your cherry-pick (CHERRY_PICK_HEAD exists)."
msgstr ""
-"No heu terminat el vostre recull de cireres (CHERRY_PICK_HEAD existeix)."
+"No heu completat el vostre recull de cireres (CHERRY_PICK_HEAD existeix)."
-#: builtin/merge.c:1164
+#: builtin/merge.c:1157
msgid "You cannot combine --squash with --no-ff."
msgstr "No podeu combinar --squash amb --no-ff."
-#: builtin/merge.c:1173
+#: builtin/merge.c:1166
msgid "No commit specified and merge.defaultToUpstream not set."
msgstr ""
"No hi ha una comissió especificada i merge.defaultToUpstream no està "
"establert."
-#: builtin/merge.c:1205
+#: builtin/merge.c:1198
msgid "Can merge only exactly one commit into empty head"
msgstr "Es pot fusionar només exactament una comissió a un cap buit"
-#: builtin/merge.c:1208
+#: builtin/merge.c:1201
msgid "Squash commit into empty head not supported yet"
-msgstr "Aixafar una comissió a un cap buit encara no es suporta"
+msgstr "Aixafar una comissió a un cap buit encara no es permet"
-#: builtin/merge.c:1210
+#: builtin/merge.c:1203
msgid "Non-fast-forward commit does not make sense into an empty head"
msgstr "Una comissió no d'avanç ràpid no té sentit a un cap buit"
-#: builtin/merge.c:1215
+#: builtin/merge.c:1208
#, c-format
msgid "%s - not something we can merge"
-msgstr "%s - no és cosa que puguem fusionar"
+msgstr "%s - no és una cosa que puguem fusionar"
-#: builtin/merge.c:1266
+#: builtin/merge.c:1259
#, c-format
msgid "Commit %s has an untrusted GPG signature, allegedly by %s."
-msgstr "La comissió %s té una firma GPG no confiada, suposadament de %s."
+msgstr "La comissió %s té una firma GPG no fiable, suposadament de %s."
-#: builtin/merge.c:1269
+#: builtin/merge.c:1262
#, c-format
msgid "Commit %s has a bad GPG signature allegedly by %s."
msgstr "La comissió %s té una firma GPG dolenta suposadament de %s."
-#: builtin/merge.c:1272
+#: builtin/merge.c:1265
#, c-format
msgid "Commit %s does not have a GPG signature."
msgstr "La comissió %s no té firma GPG."
-#: builtin/merge.c:1275
+#: builtin/merge.c:1268
#, c-format
msgid "Commit %s has a good GPG signature by %s\n"
msgstr "La comissió %s té una firma GPG bona de %s\n"
-#: builtin/merge.c:1356
+#: builtin/merge.c:1349
#, c-format
msgid "Updating %s..%s\n"
msgstr "Actualitzant %s..%s\n"
-#: builtin/merge.c:1395
+#: builtin/merge.c:1388
#, c-format
msgid "Trying really trivial in-index merge...\n"
msgstr "Intentant una fusió molt trivial en l'índex...\n"
-#: builtin/merge.c:1402
+#: builtin/merge.c:1395
#, c-format
msgid "Nope.\n"
msgstr "No.\n"
-#: builtin/merge.c:1434
+#: builtin/merge.c:1427
msgid "Not possible to fast-forward, aborting."
msgstr "No és possible avançar ràpidament, avortant."
-#: builtin/merge.c:1457 builtin/merge.c:1536
+#: builtin/merge.c:1450 builtin/merge.c:1529
#, c-format
msgid "Rewinding the tree to pristine...\n"
msgstr "Rebobinant l'arbre a la pristina...\n"
-#: builtin/merge.c:1461
+#: builtin/merge.c:1454
#, c-format
msgid "Trying merge strategy %s...\n"
msgstr "Intentant l'estratègia de fusió %s...\n"
-#: builtin/merge.c:1527
+#: builtin/merge.c:1520
#, c-format
msgid "No merge strategy handled the merge.\n"
-msgstr "Cap estratègia de fusió ha manejat la fusió.\n"
+msgstr "Cap estratègia de fusió ha gestionat la fusió.\n"
-#: builtin/merge.c:1529
+#: builtin/merge.c:1522
#, c-format
msgid "Merge with strategy %s failed.\n"
msgstr "L'estratègia de fusió %s ha fallat.\n"
-#: builtin/merge.c:1538
+#: builtin/merge.c:1531
#, c-format
msgid "Using the %s to prepare resolving by hand.\n"
msgstr "Usant el %s per a preparar la resolució a mà.\n"
-#: builtin/merge.c:1550
+#: builtin/merge.c:1543
#, c-format
msgid "Automatic merge went well; stopped before committing as requested\n"
msgstr ""
-"La fusió automàtica ha sortit bé; aturat abans de cometre segons demanat\n"
+"La fusió automàtica ha sortit bé; s'ha aturat abans de cometre tal i com "
+"s'havia demanat\n"
#: builtin/merge-base.c:29
msgid "git merge-base [-a|--all] <commit> <commit>..."
@@ -7263,7 +7279,7 @@ msgstr "emet tots els avantpassats comuns"
#: builtin/merge-base.c:216
msgid "find ancestors for a single n-way merge"
-msgstr "troba els avantpassats per a una fusió soltera de n vies"
+msgstr "troba els avantpassats per a una sola fusió de n vies"
#: builtin/merge-base.c:218
msgid "list revs not reachable from others"
@@ -7324,11 +7340,11 @@ msgstr "git mktree [-z] [--missing] [--batch]"
#: builtin/mktree.c:150
msgid "input is NUL terminated"
-msgstr "l'entrada és terminada per NUL"
+msgstr "l'entrada és acabada amb NUL"
#: builtin/mktree.c:151 builtin/write-tree.c:24
msgid "allow missing objects"
-msgstr "permet els objectes mancants"
+msgstr "permet els objectes absents"
#: builtin/mktree.c:152
msgid "allow creation of more than one tree"
@@ -7341,7 +7357,7 @@ msgstr "git mv [opcions] <font>... <destí>"
#: builtin/mv.c:69
#, c-format
msgid "Directory %s is in index and no submodule?"
-msgstr "El directori %s està en l'índex i no hi ha submòdul?"
+msgstr "El directori %s és en l'índex i no hi ha cap submòdul?"
#: builtin/mv.c:71
msgid "Please stage your changes to .gitmodules or stash them to proceed"
@@ -7352,7 +7368,7 @@ msgstr ""
#: builtin/mv.c:89
#, c-format
msgid "%.*s is in index"
-msgstr "%.*s està en l'índex"
+msgstr "%.*s és en l'índex"
#: builtin/mv.c:111
msgid "force move/rename even if target exists"
@@ -7360,7 +7376,7 @@ msgstr "força el moviment / canvi de nom encara que el destí existeixi"
#: builtin/mv.c:112
msgid "skip move/rename errors"
-msgstr "salta els error de moviment / canvi de nom"
+msgstr "omet els errors de moviment / canvi de nom"
#: builtin/mv.c:151
#, c-format
@@ -7378,7 +7394,7 @@ msgstr "font dolenta"
#: builtin/mv.c:169
msgid "can not move directory into itself"
-msgstr "no es pot moure un directori al seu mateix"
+msgstr "no es pot moure un directori a dins d'ell mateix"
#: builtin/mv.c:172
msgid "cannot move directory over file"
@@ -7390,7 +7406,7 @@ msgstr "el directori font està buit"
#: builtin/mv.c:206
msgid "not under version control"
-msgstr "no està baix control de versions"
+msgstr "no està sota control de versions"
#: builtin/mv.c:209
msgid "destination exists"
@@ -7423,7 +7439,7 @@ msgstr "%s, origen=%s, destí=%s"
msgid "Renaming %s to %s\n"
msgstr "Canviant el nom de %s a %s\n"
-#: builtin/mv.c:256 builtin/remote.c:726 builtin/repack.c:358
+#: builtin/mv.c:256 builtin/remote.c:728 builtin/repack.c:355
#, c-format
msgid "renaming '%s' failed"
msgstr "el canvi del nom de '%s' ha fallat"
@@ -7474,11 +7490,11 @@ msgstr "git notes [--ref <referència_de_notes>] [llista [<objecte>]]"
#: builtin/notes.c:25
msgid ""
-"git notes [--ref <notes_ref>] add [-f] [-m <msg> | -F <file> | (-c | -C) "
-"<object>] [<object>]"
+"git notes [--ref <notes_ref>] add [-f] [--allow-empty] [-m <msg> | -F <file> "
+"| (-c | -C) <object>] [<object>]"
msgstr ""
-"git notes [--ref <referència_de_notes>] add [-f] [-m <missatge> | -F "
-"<fitxer> | (-c | -C) <objecte>] [<objecte>]"
+"git notes [--ref <referència_de_notes>] add [-f] [--allow-empty] [-m "
+"<missatge> | -F <fitxer> | (-c | -C) <objecte>] [<objecte>]"
#: builtin/notes.c:26
msgid "git notes [--ref <notes_ref>] copy [-f] <from-object> <to-object>"
@@ -7487,15 +7503,16 @@ msgstr ""
#: builtin/notes.c:27
msgid ""
-"git notes [--ref <notes_ref>] append [-m <msg> | -F <file> | (-c | -C) "
-"<object>] [<object>]"
+"git notes [--ref <notes_ref>] append [--allow-empty] [-m <msg> | -F <file> | "
+"(-c | -C) <object>] [<object>]"
msgstr ""
-"git notes [--ref <referència_de_notes>] append [-m <missatge> | -F <fitxer> "
-"| (-c | -C) <objecte>] [<objecte>]"
+"git notes [--ref <referència_de_notes>] append [--allow-empty] [-m "
+"<missatge> | -F <fitxer> | (-c | -C) <objecte>] [<objecte>]"
#: builtin/notes.c:28
-msgid "git notes [--ref <notes_ref>] edit [<object>]"
-msgstr "git notes [--ref <referència_de_notes>] edit [<objecte>]"
+msgid "git notes [--ref <notes_ref>] edit [--allow-empty] [<object>]"
+msgstr ""
+"git notes [--ref <referència_de_notes>] edit [--allow-empty] [<objecte>]"
#: builtin/notes.c:29
msgid "git notes [--ref <notes_ref>] show [<object>]"
@@ -7580,120 +7597,119 @@ msgstr "git notes prune [<opcions>]"
msgid "git notes get-ref"
msgstr "git notes get-ref"
-#: builtin/notes.c:136
+#: builtin/notes.c:146
#, c-format
msgid "unable to start 'show' for object '%s'"
-msgstr "incapaç d'iniciar 'show' per a l'objecte '%s'"
+msgstr "no s'ha pogut iniciar 'show' per a l'objecte '%s'"
-#: builtin/notes.c:140
+#: builtin/notes.c:150
msgid "could not read 'show' output"
msgstr "no s'ha pogut llegir la sortida de 'show'"
-#: builtin/notes.c:148
+#: builtin/notes.c:158
#, c-format
msgid "failed to finish 'show' for object '%s'"
-msgstr "s'ha fallat en terminar 'show' per a l'objecte '%s'"
+msgstr "s'ha fallat en finalitzar 'show' per a l'objecte '%s'"
-#: builtin/notes.c:166 builtin/tag.c:477
+#: builtin/notes.c:173 builtin/tag.c:477
#, c-format
msgid "could not create file '%s'"
msgstr "no s'ha pogut crear el fitxer '%s'"
-#: builtin/notes.c:185
+#: builtin/notes.c:192
msgid "Please supply the note contents using either -m or -F option"
msgstr ""
-"Si us plau, proveïu els continguts de la nota per usar o l'opció -m o "
+"Si us plau, proveïu els continguts de la nota fent servir l'opció -m o "
"l'opció -F"
-#: builtin/notes.c:206 builtin/notes.c:847
-#, c-format
-msgid "Removing note for object %s\n"
-msgstr "Traient la nota de l'objecte %s\n"
-
-#: builtin/notes.c:211
+#: builtin/notes.c:201
msgid "unable to write note object"
-msgstr "incapaç d'escriure l'objecte de nota"
+msgstr "no s'ha pogut escriure l'objecte de nota"
-#: builtin/notes.c:213
+#: builtin/notes.c:203
#, c-format
msgid "The note contents have been left in %s"
msgstr "Els continguts de la nota s'han deixat en %s"
-#: builtin/notes.c:247 builtin/tag.c:693
+#: builtin/notes.c:231 builtin/tag.c:693
#, c-format
msgid "cannot read '%s'"
msgstr "no es pot llegir '%s'"
-#: builtin/notes.c:249 builtin/tag.c:696
+#: builtin/notes.c:233 builtin/tag.c:696
#, c-format
msgid "could not open or read '%s'"
msgstr "no s'ha pogut obrir ni llegir '%s'"
-#: builtin/notes.c:268 builtin/notes.c:319 builtin/notes.c:321
-#: builtin/notes.c:381 builtin/notes.c:435 builtin/notes.c:518
-#: builtin/notes.c:523 builtin/notes.c:598 builtin/notes.c:640
-#: builtin/notes.c:842 builtin/tag.c:709
+#: builtin/notes.c:252 builtin/notes.c:303 builtin/notes.c:305
+#: builtin/notes.c:365 builtin/notes.c:420 builtin/notes.c:506
+#: builtin/notes.c:511 builtin/notes.c:589 builtin/notes.c:652
+#: builtin/notes.c:854 builtin/tag.c:709
#, c-format
msgid "Failed to resolve '%s' as a valid ref."
msgstr "S'ha fallat en resoldre '%s' com a referència vàlida."
-#: builtin/notes.c:271
+#: builtin/notes.c:255
#, c-format
msgid "Failed to read object '%s'."
msgstr "S'ha fallat en llegir l'objecte '%s'."
-#: builtin/notes.c:275
+#: builtin/notes.c:259
#, c-format
msgid "Cannot read note data from non-blob object '%s'."
msgstr "No es pot llegir les dades de node de l'objecte no de blob '%s'."
-#: builtin/notes.c:315
+#: builtin/notes.c:299
#, c-format
msgid "Malformed input line: '%s'."
-msgstr "Línia d'entrada malformada: '%s'."
+msgstr "Línia d'entrada mal formada: '%s'."
-#: builtin/notes.c:330
+#: builtin/notes.c:314
#, c-format
msgid "Failed to copy notes from '%s' to '%s'"
msgstr "S'ha fallat en copiar les notes de '%s' a '%s'"
-#: builtin/notes.c:374 builtin/notes.c:428 builtin/notes.c:501
-#: builtin/notes.c:513 builtin/notes.c:586 builtin/notes.c:633
-#: builtin/notes.c:907
+#: builtin/notes.c:358 builtin/notes.c:413 builtin/notes.c:489
+#: builtin/notes.c:501 builtin/notes.c:577 builtin/notes.c:645
+#: builtin/notes.c:919
msgid "too many parameters"
msgstr "massa paràmetres"
-#: builtin/notes.c:387 builtin/notes.c:646
+#: builtin/notes.c:371 builtin/notes.c:658
#, c-format
msgid "No note found for object %s."
-msgstr "Cap nota trobada per a l'objecte %s."
+msgstr "No s'ha trobat cap nota per a l'objecte %s."
-#: builtin/notes.c:409 builtin/notes.c:566
+#: builtin/notes.c:392 builtin/notes.c:555
msgid "note contents as a string"
-msgstr "nota els continguts com a cadena"
+msgstr "anota els continguts com a cadena"
-#: builtin/notes.c:412 builtin/notes.c:569
+#: builtin/notes.c:395 builtin/notes.c:558
msgid "note contents in a file"
-msgstr "nota els continguts en un fitxer"
+msgstr "anota els continguts en un fitxer"
-#: builtin/notes.c:414 builtin/notes.c:417 builtin/notes.c:571
-#: builtin/notes.c:574 builtin/tag.c:628
+#: builtin/notes.c:397 builtin/notes.c:400 builtin/notes.c:560
+#: builtin/notes.c:563 builtin/tag.c:628
msgid "object"
msgstr "objecte"
-#: builtin/notes.c:415 builtin/notes.c:572
+#: builtin/notes.c:398 builtin/notes.c:561
msgid "reuse and edit specified note object"
msgstr "reusa i edita l'objecte de nota especificat"
-#: builtin/notes.c:418 builtin/notes.c:575
+#: builtin/notes.c:401 builtin/notes.c:564
msgid "reuse specified note object"
msgstr "reusa l'objecte de nota especificat"
-#: builtin/notes.c:420 builtin/notes.c:488
+#: builtin/notes.c:404 builtin/notes.c:567
+msgid "allow storing empty note"
+msgstr "permet l'emmagatzematge d'una nota buida"
+
+#: builtin/notes.c:405 builtin/notes.c:476
msgid "replace existing notes"
msgstr "reemplaça les notes existents"
-#: builtin/notes.c:454
+#: builtin/notes.c:430
#, c-format
msgid ""
"Cannot add notes. Found existing notes for object %s. Use '-f' to overwrite "
@@ -7702,25 +7718,30 @@ msgstr ""
"No es pot afegir les notes. S'ha trobat notes existents de l'objecte %s. "
"Useu '-f' per a sobreescriure les notes existents."
-#: builtin/notes.c:459 builtin/notes.c:536
+#: builtin/notes.c:445 builtin/notes.c:524
#, c-format
msgid "Overwriting existing notes for object %s\n"
msgstr "Sobreescrivint les notes existents de l'objecte %s\n"
-#: builtin/notes.c:489
+#: builtin/notes.c:456 builtin/notes.c:617 builtin/notes.c:859
+#, c-format
+msgid "Removing note for object %s\n"
+msgstr "Eliminant la nota de l'objecte %s\n"
+
+#: builtin/notes.c:477
msgid "read objects from stdin"
msgstr "llegeix els objectes des d'stdin"
-#: builtin/notes.c:491
+#: builtin/notes.c:479
msgid "load rewriting config for <command> (implies --stdin)"
msgstr ""
"carrega la configuració de reescriptura per a <ordre> (implica --stdin)"
-#: builtin/notes.c:509
+#: builtin/notes.c:497
msgid "too few parameters"
msgstr "hi ha massa pocs paràmetres"
-#: builtin/notes.c:530
+#: builtin/notes.c:518
#, c-format
msgid ""
"Cannot copy notes. Found existing notes for object %s. Use '-f' to overwrite "
@@ -7729,74 +7750,74 @@ msgstr ""
"No es pot copiar les notes. S'han trobat notes existents de l'objecte %s. "
"Useu '-f' per a sobreescriure les notes existents."
-#: builtin/notes.c:542
+#: builtin/notes.c:530
#, c-format
msgid "Missing notes on source object %s. Cannot copy."
msgstr "Manquen notes a l'objecte font %s. No es pot copiar."
-#: builtin/notes.c:591
+#: builtin/notes.c:582
#, c-format
msgid ""
"The -m/-F/-c/-C options have been deprecated for the 'edit' subcommand.\n"
"Please use 'git notes add -f -m/-F/-c/-C' instead.\n"
msgstr ""
-"S'han desaprovat les opcions -m/-F/-c/-C del subordre 'edit'.\n"
-"Si us plau, useu 'git notes add -f -m/-F/-c/-C' en lloc.\n"
+"S'han desaprovat les opcions -m/-F/-c/-C en favor de la subordre 'edit'.\n"
+"Si us plau, useu 'git notes add -f -m/-F/-c/-C' en lloc d'això.\n"
-#: builtin/notes.c:738
+#: builtin/notes.c:750
msgid "General options"
msgstr "Opcions generals"
-#: builtin/notes.c:740
+#: builtin/notes.c:752
msgid "Merge options"
msgstr "Opcions de fusió"
-#: builtin/notes.c:742
+#: builtin/notes.c:754
msgid ""
"resolve notes conflicts using the given strategy (manual/ours/theirs/union/"
"cat_sort_uniq)"
msgstr ""
-"resol conflictes de nota per usar l'estratègia donada (manual/ours/theirs/"
+"resol els conflictes de nota usant l'estratègia donada (manual/ours/theirs/"
"union/cat_sort_uniq)"
-#: builtin/notes.c:744
+#: builtin/notes.c:756
msgid "Committing unmerged notes"
msgstr "Cometent les notes sense fusionar"
-#: builtin/notes.c:746
+#: builtin/notes.c:758
msgid "finalize notes merge by committing unmerged notes"
-msgstr "finalitza la fusió de notes per cometre les notes sense fusionar"
+msgstr "finalitza la fusió de notes cometent les notes sense fusionar"
-#: builtin/notes.c:748
+#: builtin/notes.c:760
msgid "Aborting notes merge resolution"
msgstr "Avortant la resolució de fusió de notes"
-#: builtin/notes.c:750
+#: builtin/notes.c:762
msgid "abort notes merge"
msgstr "avorta la fusió de notes"
-#: builtin/notes.c:845
+#: builtin/notes.c:857
#, c-format
msgid "Object %s has no note\n"
msgstr "L'objecte %s no té cap nota\n"
-#: builtin/notes.c:857
+#: builtin/notes.c:869
msgid "attempt to remove non-existent note is not an error"
-msgstr "l'intent de treure una nota no existent no és un error"
+msgstr "l'intent d'eliminar una nota no existent no és un error"
-#: builtin/notes.c:860
+#: builtin/notes.c:872
msgid "read object names from the standard input"
msgstr "llegeix els noms d'objecte des de l'entrada estàndard"
-#: builtin/notes.c:941
+#: builtin/notes.c:953
msgid "notes-ref"
msgstr "referència de notes"
-#: builtin/notes.c:942
+#: builtin/notes.c:954
msgid "use notes from <notes_ref>"
msgstr "usa les notes de <referència de notes>"
-#: builtin/notes.c:977 builtin/remote.c:1624
+#: builtin/notes.c:989 builtin/remote.c:1621
#, c-format
msgid "Unknown subcommand: %s"
msgstr "Subordre desconegut: %s"
@@ -7825,7 +7846,7 @@ msgstr "Escrivint els objectes"
#: builtin/pack-objects.c:1015
msgid "disabling bitmap writing, as some objects are not being packed"
msgstr ""
-"deshabilitant l'escriptura de mapes de bits, perquè alguns objectes no "
+"inhabilitant l'escriptura de mapes de bits, perquè alguns objectes no "
"s'estan empaquetant"
#: builtin/pack-objects.c:2175
@@ -7835,7 +7856,7 @@ msgstr "Comprimint objectes"
#: builtin/pack-objects.c:2572
#, c-format
msgid "unsupported index version %s"
-msgstr "versió d'índex no suportada %s"
+msgstr "versió d'índex no compatible %s"
#: builtin/pack-objects.c:2576
#, c-format
@@ -7850,150 +7871,154 @@ msgstr "l'opció %s no accepta la forma negativa"
#: builtin/pack-objects.c:2603
#, c-format
msgid "unable to parse value '%s' for option %s"
-msgstr "incapaç d'analitzar el valor '%s' per a l'opció %s"
+msgstr "no s'ha pogut analitzar el valor '%s' per a l'opció %s"
-#: builtin/pack-objects.c:2622
+#: builtin/pack-objects.c:2623
msgid "do not show progress meter"
msgstr "no mostris l'indicador de progrés"
-#: builtin/pack-objects.c:2624
+#: builtin/pack-objects.c:2625
msgid "show progress meter"
msgstr "mostra l'indicador de progrés"
-#: builtin/pack-objects.c:2626
+#: builtin/pack-objects.c:2627
msgid "show progress meter during object writing phase"
-msgstr "mostra l'indicador de progrés durant el fase d'escriptura d'objectes"
+msgstr "mostra l'indicador de progrés durant la fase d'escriptura d'objectes"
-#: builtin/pack-objects.c:2629
+#: builtin/pack-objects.c:2630
msgid "similar to --all-progress when progress meter is shown"
msgstr "similar a --all-progress quan l'indicador de progrés es mostra"
-#: builtin/pack-objects.c:2630
+#: builtin/pack-objects.c:2631
msgid "version[,offset]"
msgstr "versió[,desplaçament]"
-#: builtin/pack-objects.c:2631
+#: builtin/pack-objects.c:2632
msgid "write the pack index file in the specified idx format version"
msgstr ""
"escriu el fitxer d'índex de paquet en la versió de format d'índex "
"especificada"
-#: builtin/pack-objects.c:2634
+#: builtin/pack-objects.c:2635
msgid "maximum size of each output pack file"
msgstr "mida màxima de cada fitxer de paquet de sortida"
-#: builtin/pack-objects.c:2636
+#: builtin/pack-objects.c:2637
msgid "ignore borrowed objects from alternate object store"
msgstr ""
"ignora els objectes prestats d'un emmagatzemament d'objectes alternatiu"
-#: builtin/pack-objects.c:2638
+#: builtin/pack-objects.c:2639
msgid "ignore packed objects"
msgstr "ignora els objectes empaquetats"
-#: builtin/pack-objects.c:2640
+#: builtin/pack-objects.c:2641
msgid "limit pack window by objects"
msgstr "limita la finestra d'empaquetament per objectes"
-#: builtin/pack-objects.c:2642
+#: builtin/pack-objects.c:2643
msgid "limit pack window by memory in addition to object limit"
msgstr ""
"limita la finestra d'empaquetament per memòria a més del límit d'objectes"
-#: builtin/pack-objects.c:2644
+#: builtin/pack-objects.c:2645
msgid "maximum length of delta chain allowed in the resulting pack"
-msgstr "longitud màxima de la cadena de deltes permesa en el paquet resultat"
+msgstr "longitud màxima de la cadena de deltes permesa en el paquet resultant"
-#: builtin/pack-objects.c:2646
+#: builtin/pack-objects.c:2647
msgid "reuse existing deltas"
msgstr "reusa les deltes existents"
-#: builtin/pack-objects.c:2648
+#: builtin/pack-objects.c:2649
msgid "reuse existing objects"
msgstr "reusa els objectes existents"
-#: builtin/pack-objects.c:2650
+#: builtin/pack-objects.c:2651
msgid "use OFS_DELTA objects"
msgstr "usa objectes OFS_DELTA"
-#: builtin/pack-objects.c:2652
+#: builtin/pack-objects.c:2653
msgid "use threads when searching for best delta matches"
msgstr "usa fils en cercar les millores coincidències de delta"
-#: builtin/pack-objects.c:2654
+#: builtin/pack-objects.c:2655
msgid "do not create an empty pack output"
msgstr "no creïs una emissió de paquet buida"
-#: builtin/pack-objects.c:2656
+#: builtin/pack-objects.c:2657
msgid "read revision arguments from standard input"
msgstr "llegeix els paràmetres de revisió des de l'entrada estàndard"
-#: builtin/pack-objects.c:2658
+#: builtin/pack-objects.c:2659
msgid "limit the objects to those that are not yet packed"
msgstr "limita els objectes als que encara no s'hagin empaquetat"
-#: builtin/pack-objects.c:2661
+#: builtin/pack-objects.c:2662
msgid "include objects reachable from any reference"
msgstr "inclou els objectes abastables de qualsevulla referència"
-#: builtin/pack-objects.c:2664
+#: builtin/pack-objects.c:2665
msgid "include objects referred by reflog entries"
msgstr ""
-"inclou els objectes als quals les entrades del registre de referències "
-"refereixin"
+"inclou els objectes als quals facin referència les entrades del registre de "
+"referències"
-#: builtin/pack-objects.c:2667
+#: builtin/pack-objects.c:2668
msgid "include objects referred to by the index"
-msgstr "inclou els objectes als quals l'índex refereixi"
+msgstr "inclou els objectes als quals faci referència l'índex"
-#: builtin/pack-objects.c:2670
+#: builtin/pack-objects.c:2671
msgid "output pack to stdout"
msgstr "emet el paquet a stdout"
-#: builtin/pack-objects.c:2672
+#: builtin/pack-objects.c:2673
msgid "include tag objects that refer to objects to be packed"
msgstr ""
-"inclou els objectes d'etiqueta que refereixin als objectes que empaquetar"
+"inclou els objectes d'etiqueta que facin referència als objectes a empaquetar"
-#: builtin/pack-objects.c:2674
+#: builtin/pack-objects.c:2675
msgid "keep unreachable objects"
-msgstr "reté els objectes inabastables"
+msgstr "retén els objectes inabastables"
-#: builtin/pack-objects.c:2675 parse-options.h:140
+#: builtin/pack-objects.c:2676 parse-options.h:140
msgid "time"
msgstr "hora"
-#: builtin/pack-objects.c:2676
+#: builtin/pack-objects.c:2677
msgid "unpack unreachable objects newer than <time>"
-msgstr "desempaquetar els objectes inabastables més nous que <hora>"
+msgstr "desempaqueta els objectes inabastables més nous que <hora>"
-#: builtin/pack-objects.c:2679
+#: builtin/pack-objects.c:2680
msgid "create thin packs"
msgstr "crea paquets prims"
-#: builtin/pack-objects.c:2681
+#: builtin/pack-objects.c:2682
+msgid "create packs suitable for shallow fetches"
+msgstr "crea paquets adequats per als obteniments superficials"
+
+#: builtin/pack-objects.c:2684
msgid "ignore packs that have companion .keep file"
-msgstr "ignora els paquets que tinguin un fitxer .keep de company"
+msgstr "ignora els paquets que tinguin un fitxer .keep corresponent"
-#: builtin/pack-objects.c:2683
+#: builtin/pack-objects.c:2686
msgid "pack compression level"
msgstr "nivell de compressió de paquet"
-#: builtin/pack-objects.c:2685
+#: builtin/pack-objects.c:2688
msgid "do not hide commits by grafts"
msgstr "no amaguis les comissions per empelt"
-#: builtin/pack-objects.c:2687
+#: builtin/pack-objects.c:2690
msgid "use a bitmap index if available to speed up counting objects"
msgstr ""
-"usa un índex de mapa de bits, si disponible, per a accelerar el recompte "
-"d'objectes"
+"usa un índex de mapa de bits, si està disponible, per a accelerar el "
+"recompte d'objectes"
-#: builtin/pack-objects.c:2689
+#: builtin/pack-objects.c:2692
msgid "write a bitmap index together with the pack index"
msgstr "escriu un índex de mapa de bits junt amb l'índex de paquet"
-#: builtin/pack-objects.c:2778
+#: builtin/pack-objects.c:2783
msgid "Counting objects"
msgstr "Comptant els objectes"
@@ -8003,7 +8028,7 @@ msgstr "git pack-refs [opcions]"
#: builtin/pack-refs.c:14
msgid "pack everything"
-msgstr "empaqueta tot"
+msgstr "empaqueta-ho tot"
#: builtin/pack-refs.c:15
msgid "prune loose refs (default)"
@@ -8015,7 +8040,7 @@ msgstr "git prune-packed [-n|--dry-run] [-q|--quiet]"
#: builtin/prune-packed.c:40
msgid "Removing duplicate objects"
-msgstr "Traient objectes duplicats"
+msgstr "Eliminant objectes duplicats"
#: builtin/prune.c:12
msgid "git prune [-n] [-v] [--expire <time>] [--] [<head>...]"
@@ -8023,7 +8048,7 @@ msgstr "git prune [-n] [-v] [--expire <hora>] [--] [<cap>...]"
#: builtin/prune.c:106
msgid "do not remove, show only"
-msgstr "no treguis, només mostra"
+msgstr "no eliminis, només mostra"
#: builtin/prune.c:107
msgid "report pruned objects"
@@ -8031,7 +8056,7 @@ msgstr "informa d'objectes podats"
#: builtin/prune.c:110
msgid "expire objects older than <time>"
-msgstr "caduca els objectes més vells que <hora>"
+msgstr "fes caducar els objectes més vells que <hora>"