From: Junio C Hamano Date: Mon, 10 Sep 2012 22:37:37 +0000 (-0700) Subject: Merge branch 'bc/prune-info' into maint X-Git-Tag: v1.7.12.1~27 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/f56d036ce95616b3339a11ecf50b717d5cf67c85?hp=90b29cb7a8213a947e08c41ea4680ced7ac7c67c Merge branch 'bc/prune-info' into maint "git prune" without "-v" used to warn about leftover temporary files (which is an indication of an earlier aborted operation). * bc/prune-info: prune.c: only print informational message in show_only or verbose mode --- diff --git a/Documentation/CodingGuidelines b/Documentation/CodingGuidelines index 45577117c2..57da6aadeb 100644 --- a/Documentation/CodingGuidelines +++ b/Documentation/CodingGuidelines @@ -76,11 +76,19 @@ For shell scripts specifically (not exhaustive): - We do not use Process Substitution <(list) or >(list). + - Do not write control structures on a single line with semicolon. + "then" should be on the next line for if statements, and "do" + should be on the next line for "while" and "for". + - We prefer "test" over "[ ... ]". - We do not write the noiseword "function" in front of shell functions. + - We prefer a space between the function name and the parentheses. The + opening "{" should also be on the same line. + E.g.: my_function () { + - As to use of grep, stick to a subset of BRE (namely, no \{m,n\}, [::], [==], nor [..]) for portability. diff --git a/Documentation/RelNotes/1.7.11.5.txt b/Documentation/RelNotes/1.7.11.5.txt index 86df992c6b..0a2ed855c5 100644 --- a/Documentation/RelNotes/1.7.11.5.txt +++ b/Documentation/RelNotes/1.7.11.5.txt @@ -7,6 +7,10 @@ Fixes since v1.7.11.4 * The Makefile rule to create assembly output (primarily for debugging purposes) did not create it next to the source. + * The code to avoid mistaken attempt to add the object directory + itself as its own alternate could read beyond end of a string while + comparison. + * On some architectures, "block-sha1" did not compile correctly when compilers inferred alignment guarantees from our source we did not intend to make. @@ -25,4 +29,8 @@ Fixes since v1.7.11.4 * "git mergetool" did not support --tool-help option to give the list of supported backends, like "git difftool" does. + * "git grep" stopped spawning an external "grep" long time ago, but a + duplicated test to check internal and external "grep" was left + behind. + Also contains minor typofixes and documentation updates. diff --git a/Documentation/RelNotes/1.7.11.6.txt b/Documentation/RelNotes/1.7.11.6.txt new file mode 100644 index 0000000000..84ba827b1b --- /dev/null +++ b/Documentation/RelNotes/1.7.11.6.txt @@ -0,0 +1,62 @@ +Git v1.7.11.6 Release Notes +=========================== + +Fixes since v1.7.11.5 +--------------------- + +This consists primarily of documentation updates and low-impact code +clarification and bugfixes. + + - "ciabot" script (in contrib/) has been updated with extensive + documentation. + + - The "--rebase" option to "git pull" can be abbreviated to "-r", + but we didn't document it. + + - It was generally understood that "--long-option"s to many of our + subcommands can be abbreviated to the unique prefix, but it was not + easy to find it described for new readers of the documentation set. + + - The "--topo-order", "--date-order" (and the lack of either means + the default order) options to "rev-list" and "log" family of + commands were poorly described in the documentation. + + - Older parts of the documentation described as if having a regular + file in .git/refs/ hierarchy were the only way to have branches and + tags, which is not true for quite some time. + + - A utility shell function test_seq has been added as a replacement + for the 'seq' utility found on some platforms. + + - Fallback 'getpass' implementation made unportable use of stdio API. + + - "git commit --amend" let the user edit the log message and then + died when the human-readable committer name was given + insufficiently by getpwent(3). + + - The reflog entries left by "git rebase" and "git rebase -i" were + inconsistent (the interactive one gave an abbreviated object name). + + - When the user exports a non-default IFS without HT, scripts that + rely on being able to parse "ls-files -s | while read a b c..." + started to fail. Protect them from such a misconfiguration. + + - When "git push" triggered the automatic gc on the receiving end, a + message from "git prune" that said it was removing cruft leaked to + the standard output, breaking the communication protocol. + + - "git diff" had a confusion between taking data from a path in the + working tree and taking data from an object that happens to have + name 0{40} recorded in a tree. + + - "git send-email" did not unquote encoded words that appear on the + header correctly, and lost "_" from strings. + + - When the user gives an argument that can be taken as both a + revision name and a pathname without disambiguating with "--", we + used to give a help message "Use '--' to separate". The message + has been clarified to show where that '--' goes on the command + line. + + - "gitweb" when used with PATH_INFO failed to notice directories with + SP (and other characters that need URL-style quoting) in them. diff --git a/Documentation/RelNotes/1.7.12.txt b/Documentation/RelNotes/1.7.12.txt index fb7f761a38..010d8c7de4 100644 --- a/Documentation/RelNotes/1.7.12.txt +++ b/Documentation/RelNotes/1.7.12.txt @@ -116,6 +116,7 @@ Performance, Internal Implementation, etc. (please report possible regressions) * "git svn" got a large-looking code reorganization at the last minute before the code freeze. + Also contains minor documentation updates and code clean-ups. @@ -126,16 +127,6 @@ Unless otherwise noted, all the fixes since v1.7.11 in the maintenance releases are contained in this release (see release notes to them for details). - * "git grep" stopped spawning an external "grep" long time ago, but a - duplicated test to check internal and external "grep" was left - behind. - (merge 4ca9453 rj/maint-grep-remove-redundant-test later to maint). - - * The code to avoid mistaken attempt to add the object directory - itself as its own alternate could read beyond end of a string while - comparison. - (merge cb2912c hv/link-alt-odb-entry later to maint). - * "git submodule add" was confused when the superproject did not have its repository in its usual place in the working tree and GIT_DIR and GIT_WORK_TREE was used to access it. diff --git a/Documentation/git-credential.txt b/Documentation/git-credential.txt index 53adee3203..810e957124 100644 --- a/Documentation/git-credential.txt +++ b/Documentation/git-credential.txt @@ -3,7 +3,7 @@ git-credential(1) NAME ---- -git-credential - retrieve and store user credentials +git-credential - Retrieve and store user credentials SYNOPSIS -------- diff --git a/Documentation/git-describe.txt b/Documentation/git-describe.txt index 039cce2e98..72d6bb612b 100644 --- a/Documentation/git-describe.txt +++ b/Documentation/git-describe.txt @@ -36,12 +36,12 @@ OPTIONS --all:: Instead of using only the annotated tags, use any ref - found in `.git/refs/`. This option enables matching + found in `refs/` namespace. This option enables matching any known branch, remote-tracking branch, or lightweight tag. --tags:: Instead of using only the annotated tags, use any tag - found in `.git/refs/tags`. This option enables matching + found in `refs/tags` namespace. This option enables matching a lightweight (non-annotated) tag. --contains:: diff --git a/Documentation/git-filter-branch.txt b/Documentation/git-filter-branch.txt index 81f58234a7..15e7ac80c0 100644 --- a/Documentation/git-filter-branch.txt +++ b/Documentation/git-filter-branch.txt @@ -32,7 +32,8 @@ changes, which would normally have no effect. Nevertheless, this may be useful in the future for compensating for some git bugs or such, therefore such a usage is permitted. -*NOTE*: This command honors `.git/info/grafts` and `.git/refs/replace/`. +*NOTE*: This command honors `.git/info/grafts` file and refs in +the `refs/replace/` namespace. If you have any grafts or replacement refs defined, running this command will make them permanent. diff --git a/Documentation/git-fsck.txt b/Documentation/git-fsck.txt index bbb25da2dd..da348fc942 100644 --- a/Documentation/git-fsck.txt +++ b/Documentation/git-fsck.txt @@ -23,8 +23,8 @@ OPTIONS An object to treat as the head of an unreachability trace. + If no objects are given, 'git fsck' defaults to using the -index file, all SHA1 references in .git/refs/*, and all reflogs (unless ---no-reflogs is given) as heads. +index file, all SHA1 references in `refs` namespace, and all reflogs +(unless --no-reflogs is given) as heads. --unreachable:: Print out objects that exist but that aren't reachable from any diff --git a/Documentation/git-lost-found.txt b/Documentation/git-lost-found.txt index c406a11001..d54932889f 100644 --- a/Documentation/git-lost-found.txt +++ b/Documentation/git-lost-found.txt @@ -48,7 +48,8 @@ $ gitk $(cd .git/lost-found/commit && echo ??*) ------------ After making sure you know which the object is the tag you are looking -for, you can reconnect it to your regular .git/refs hierarchy. +for, you can reconnect it to your regular `refs` hierarchy by using +the `update-ref` command. ------------ $ git cat-file -t 1ef2b196 diff --git a/Documentation/git-pack-refs.txt b/Documentation/git-pack-refs.txt index 10afd4edfe..f131677478 100644 --- a/Documentation/git-pack-refs.txt +++ b/Documentation/git-pack-refs.txt @@ -14,7 +14,8 @@ DESCRIPTION ----------- Traditionally, tips of branches and tags (collectively known as -'refs') were stored one file per ref under `$GIT_DIR/refs` +'refs') were stored one file per ref in a (sub)directory +under `$GIT_DIR/refs` directory. While many branch tips tend to be updated often, most tags and some branch tips are never updated. When a repository has hundreds or thousands of tags, this @@ -22,13 +23,14 @@ one-file-per-ref format both wastes storage and hurts performance. This command is used to solve the storage and performance -problem by stashing the refs in a single file, +problem by storing the refs in a single file, `$GIT_DIR/packed-refs`. When a ref is missing from the -traditional `$GIT_DIR/refs` hierarchy, it is looked up in this +traditional `$GIT_DIR/refs` directory hierarchy, it is looked +up in this file and used if found. Subsequent updates to branches always create new files under -`$GIT_DIR/refs` hierarchy. +`$GIT_DIR/refs` directory hierarchy. A recommended practice to deal with a repository with too many refs is to pack its refs with `--all --prune` once, and @@ -57,6 +59,15 @@ a repository with many branches of historical interests. The command usually removes loose refs under `$GIT_DIR/refs` hierarchy after packing them. This option tells it not to. + +BUGS +---- + +Older documentation written before the packed-refs mechanism was +introduced may still say things like ".git/refs/heads/ file +exists" when it means "branch exists". + + GIT --- Part of the linkgit:git[1] suite diff --git a/Documentation/git-pull.txt b/Documentation/git-pull.txt index defb544ed0..67fa5ee195 100644 --- a/Documentation/git-pull.txt +++ b/Documentation/git-pull.txt @@ -101,6 +101,7 @@ include::merge-options.txt[] :git-pull: 1 +-r:: --rebase:: Rebase the current branch on top of the upstream branch after fetching. If there is a remote-tracking branch corresponding to diff --git a/Documentation/git-replace.txt b/Documentation/git-replace.txt index 17df525275..51131d0858 100644 --- a/Documentation/git-replace.txt +++ b/Documentation/git-replace.txt @@ -14,14 +14,13 @@ SYNOPSIS DESCRIPTION ----------- -Adds a 'replace' reference in `.git/refs/replace/` +Adds a 'replace' reference in `refs/replace/` namespace. The name of the 'replace' reference is the SHA1 of the object that is replaced. The content of the 'replace' reference is the SHA1 of the replacement object. -Unless `-f` is given, the 'replace' reference must not yet exist in -`.git/refs/replace/` directory. +Unless `-f` is given, the 'replace' reference must not yet exist. Replacement references will be used by default by all git commands except those doing reachability traversal (prune, pack transfer and diff --git a/Documentation/git-tag.txt b/Documentation/git-tag.txt index e36a7c3d1e..247534e908 100644 --- a/Documentation/git-tag.txt +++ b/Documentation/git-tag.txt @@ -20,11 +20,10 @@ SYNOPSIS DESCRIPTION ----------- -Add a tag reference in `.git/refs/tags/`, unless `-d/-l/-v` is given +Add a tag reference in `refs/tags/`, unless `-d/-l/-v` is given to delete, list or verify tags. -Unless `-f` is given, the tag to be created must not yet exist in the -`.git/refs/tags/` directory. +Unless `-f` is given, the named tag must not yet exist. If one of `-a`, `-s`, or `-u ` is passed, the command creates a 'tag' object, and requires a tag message. Unless diff --git a/Documentation/git.txt b/Documentation/git.txt index 7af8aaa047..27da0eb209 100644 --- a/Documentation/git.txt +++ b/Documentation/git.txt @@ -33,7 +33,7 @@ as defined in the configuration file (see linkgit:git-config[1]). Formatted and hyperlinked version of the latest git documentation can be viewed at -`http://www.kernel.org/pub/software/scm/git/docs/`. +`http://git-htmldocs.googlecode.com/git/git.html`. ifdef::stalenotes[] [NOTE] @@ -44,9 +44,15 @@ unreleased) version of git, that is available from 'master' branch of the `git.git` repository. Documentation for older releases are available here: -* link:v1.7.11.4/git.html[documentation for release 1.7.11.4] +* link:v1.7.12/git.html[documentation for release 1.7.12] * release notes for + link:RelNotes/1.7.12.txt[1.7.12]. + +* link:v1.7.11.5/git.html[documentation for release 1.7.11.5] + +* release notes for + link:RelNotes/1.7.11.5.txt[1.7.11.5], link:RelNotes/1.7.11.4.txt[1.7.11.4], link:RelNotes/1.7.11.3.txt[1.7.11.3], link:RelNotes/1.7.11.2.txt[1.7.11.2], diff --git a/Documentation/gitcli.txt b/Documentation/gitcli.txt index ea17f7a53b..3e72a5d68e 100644 --- a/Documentation/gitcli.txt +++ b/Documentation/gitcli.txt @@ -62,6 +62,14 @@ scripting git: `git log -1 HEAD` but write `git log -1 HEAD --`; the former will not work if you happen to have a file called `HEAD` in the work tree. + * many commands allow a long option "--option" to be abbreviated + only to their unique prefix (e.g. if there is no other option + whose name begins with "opt", you may be able to spell "--opt" to + invoke the "--option" flag), but you should fully spell them out + when writing your scripts; later versions of Git may introduce a + new option whose name shares the same prefix, e.g. "--optimize", + to make a short prefix that used to be unique no longer unique. + ENHANCED OPTION PARSER ---------------------- diff --git a/Documentation/rev-list-options.txt b/Documentation/rev-list-options.txt index d9b2b5b2e0..def1340ac7 100644 --- a/Documentation/rev-list-options.txt +++ b/Documentation/rev-list-options.txt @@ -578,16 +578,33 @@ Commit Ordering By default, the commits are shown in reverse chronological order. ---topo-order:: +--date-order:: + Show no parents before all of its children are shown, but + otherwise show commits in the commit timestamp order. - This option makes them appear in topological order (i.e. - descendant commits are shown before their parents). +--topo-order:: + Show no parents before all of its children are shown, and + avoid showing commits on multiple lines of history + intermixed. ++ +For example, in a commit history like this: ++ +---------------------------------------------------------------- ---date-order:: + ---1----2----4----7 + \ \ + 3----5----6----8--- - This option is similar to '--topo-order' in the sense that no - parent comes before all of its children, but otherwise things - are still ordered in the commit timestamp order. +---------------------------------------------------------------- ++ +where the numbers denote the order of commit timestamps, `git +rev-list` and friends with `--date-order` show the commits in the +timestamp order: 8 7 6 5 4 3 2 1. ++ +With `--topo-order`, they would show 8 6 5 3 7 4 2 1 (or 8 7 4 2 6 5 +3 1); some older commits are shown before newer ones in order to +avoid showing the commits from two parallel development track mixed +together. --reverse:: diff --git a/GIT-VERSION-GEN b/GIT-VERSION-GEN index 54c1fc86e0..b27a2ff687 100755 --- a/GIT-VERSION-GEN +++ b/GIT-VERSION-GEN @@ -1,7 +1,7 @@ #!/bin/sh GVF=GIT-VERSION-FILE -DEF_VER=v1.7.12-rc2 +DEF_VER=v1.7.12 LF=' ' diff --git a/Makefile b/Makefile index 15d13197d4..6b0c961d3a 100644 --- a/Makefile +++ b/Makefile @@ -1014,6 +1014,7 @@ ifeq ($(uname_S),SunOS) NO_REGEX = YesPlease NO_FNMATCH_CASEFOLD = YesPlease NO_MSGFMT_EXTENDED_OPTIONS = YesPlease + HAVE_DEV_TTY = YesPlease ifeq ($(uname_R),5.6) SOCKLEN_T = int NO_HSTRERROR = YesPlease diff --git a/builtin.h b/builtin.h index ba6626b035..8e377522fe 100644 --- a/builtin.h +++ b/builtin.h @@ -43,7 +43,7 @@ extern int check_pager_config(const char *cmd); struct diff_options; extern void setup_diff_pager(struct diff_options *); -extern int textconv_object(const char *path, unsigned mode, const unsigned char *sha1, char **buf, unsigned long *buf_size); +extern int textconv_object(const char *path, unsigned mode, const unsigned char *sha1, int sha1_valid, char **buf, unsigned long *buf_size); extern int cmd_add(int argc, const char **argv, const char *prefix); extern int cmd_annotate(int argc, const char **argv, const char *prefix); diff --git a/builtin/blame.c b/builtin/blame.c index 0d50273ce9..f2c48ef5af 100644 --- a/builtin/blame.c +++ b/builtin/blame.c @@ -110,6 +110,7 @@ static int diff_hunks(mmfile_t *file_a, mmfile_t *file_b, long ctxlen, int textconv_object(const char *path, unsigned mode, const unsigned char *sha1, + int sha1_valid, char **buf, unsigned long *buf_size) { @@ -117,7 +118,7 @@ int textconv_object(const char *path, struct userdiff_driver *textconv; df = alloc_filespec(path); - fill_filespec(df, sha1, mode); + fill_filespec(df, sha1, sha1_valid, mode); textconv = get_textconv(df); if (!textconv) { free_filespec(df); @@ -142,7 +143,7 @@ static void fill_origin_blob(struct diff_options *opt, num_read_blob++; if (DIFF_OPT_TST(opt, ALLOW_TEXTCONV) && - textconv_object(o->path, o->mode, o->blob_sha1, &file->ptr, &file_size)) + textconv_object(o->path, o->mode, o->blob_sha1, 1, &file->ptr, &file_size)) ; else file->ptr = read_sha1_file(o->blob_sha1, &type, &file_size); @@ -2123,7 +2124,7 @@ static struct commit *fake_working_tree_commit(struct diff_options *opt, switch (st.st_mode & S_IFMT) { case S_IFREG: if (DIFF_OPT_TST(opt, ALLOW_TEXTCONV) && - textconv_object(read_from, mode, null_sha1, &buf_ptr, &buf_len)) + textconv_object(read_from, mode, null_sha1, 0, &buf_ptr, &buf_len)) strbuf_attach(&buf, buf_ptr, buf_len, buf_len + 1); else if (strbuf_read_file(&buf, read_from, st.st_size) != st.st_size) die_errno("cannot open or read '%s'", read_from); @@ -2516,7 +2517,7 @@ int cmd_blame(int argc, const char **argv, const char *prefix) die("no such path %s in %s", path, final_commit_name); if (DIFF_OPT_TST(&sb.revs->diffopt, ALLOW_TEXTCONV) && - textconv_object(path, o->mode, o->blob_sha1, (char **) &sb.final_buf, + textconv_object(path, o->mode, o->blob_sha1, 1, (char **) &sb.final_buf, &sb.final_buf_size)) ; else diff --git a/builtin/cat-file.c b/builtin/cat-file.c index af74e775a1..0eca2d7bd0 100644 --- a/builtin/cat-file.c +++ b/builtin/cat-file.c @@ -146,7 +146,7 @@ static int cat_one_file(int opt, const char *exp_type, const char *obj_name) die("git cat-file --textconv %s: must be ", obj_name); - if (!textconv_object(obj_context.path, obj_context.mode, sha1, &buf, &size)) + if (!textconv_object(obj_context.path, obj_context.mode, sha1, 1, &buf, &size)) die("git cat-file --textconv: unable to run textconv on %s", obj_name); break; diff --git a/builtin/diff.c b/builtin/diff.c index da8f6aac2b..bf72298752 100644 --- a/builtin/diff.c +++ b/builtin/diff.c @@ -29,6 +29,8 @@ static void stuff_change(struct diff_options *opt, unsigned old_mode, unsigned new_mode, const unsigned char *old_sha1, const unsigned char *new_sha1, + int old_sha1_valid, + int new_sha1_valid, const char *old_name, const char *new_name) { @@ -54,8 +56,8 @@ static void stuff_change(struct diff_options *opt, one = alloc_filespec(old_name); two = alloc_filespec(new_name); - fill_filespec(one, old_sha1, old_mode); - fill_filespec(two, new_sha1, new_mode); + fill_filespec(one, old_sha1, old_sha1_valid, old_mode); + fill_filespec(two, new_sha1, new_sha1_valid, new_mode); diff_queue(&diff_queued_diff, one, two); } @@ -84,6 +86,7 @@ static int builtin_diff_b_f(struct rev_info *revs, stuff_change(&revs->diffopt, blob[0].mode, canon_mode(st.st_mode), blob[0].sha1, null_sha1, + 1, 0, path, path); diffcore_std(&revs->diffopt); diff_flush(&revs->diffopt); @@ -108,6 +111,7 @@ static int builtin_diff_blobs(struct rev_info *revs, stuff_change(&revs->diffopt, blob[0].mode, blob[1].mode, blob[0].sha1, blob[1].sha1, + 1, 1, blob[0].name, blob[1].name); diffcore_std(&revs->diffopt); diff_flush(&revs->diffopt); diff --git a/builtin/receive-pack.c b/builtin/receive-pack.c index 0afb8b2896..3f05d971ec 100644 --- a/builtin/receive-pack.c +++ b/builtin/receive-pack.c @@ -977,7 +977,8 @@ int cmd_receive_pack(int argc, const char **argv, const char *prefix) const char *argv_gc_auto[] = { "gc", "--auto", "--quiet", NULL, }; - run_command_v_opt(argv_gc_auto, RUN_GIT_CMD); + int opt = RUN_GIT_CMD | RUN_COMMAND_STDOUT_TO_STDERR; + run_command_v_opt(argv_gc_auto, opt); } if (auto_update_server_info) update_server_info(0); diff --git a/combine-diff.c b/combine-diff.c index 9786680368..bb1cc96c4e 100644 --- a/combine-diff.c +++ b/combine-diff.c @@ -111,7 +111,7 @@ static char *grab_blob(const unsigned char *sha1, unsigned int mode, return xcalloc(1, 1); } else if (textconv) { struct diff_filespec *df = alloc_filespec(path); - fill_filespec(df, sha1, mode); + fill_filespec(df, sha1, 1, mode); *size = fill_textconv(textconv, df, &blob); free_filespec(df); } else { @@ -823,7 +823,7 @@ static void show_patch_diff(struct combine_diff_path *elem, int num_parent, &result_size, NULL, NULL); } else if (textconv) { struct diff_filespec *df = alloc_filespec(elem->path); - fill_filespec(df, null_sha1, st.st_mode); + fill_filespec(df, null_sha1, 0, st.st_mode); result_size = fill_textconv(textconv, df, &result); free_filespec(df); } else if (0 <= (fd = open(elem->path, O_RDONLY))) { diff --git a/command-list.txt b/command-list.txt index 14ea67af03..ec64cacf06 100644 --- a/command-list.txt +++ b/command-list.txt @@ -25,6 +25,7 @@ git-commit mainporcelain common git-commit-tree plumbingmanipulators git-config ancillarymanipulators git-count-objects ancillaryinterrogators +git-credential purehelpers git-cvsexportcommit foreignscminterface git-cvsimport foreignscminterface git-cvsserver foreignscminterface diff --git a/compat/terminal.c b/compat/terminal.c index 6d16c8fba0..bbb038dd01 100644 --- a/compat/terminal.c +++ b/compat/terminal.c @@ -59,6 +59,7 @@ char *git_terminal_prompt(const char *prompt, int echo) r = strbuf_getline(&buf, fh, '\n'); if (!echo) { + fseek(fh, SEEK_CUR, 0); putc('\n', fh); fflush(fh); } diff --git a/contrib/ciabot/INSTALL b/contrib/ciabot/INSTALL new file mode 100644 index 0000000000..7222961d35 --- /dev/null +++ b/contrib/ciabot/INSTALL @@ -0,0 +1,54 @@ += Installation instructions = + +Two scripts are included. The Python one (ciabot.py) is faster and +more capable; the shell one (ciabot.sh) is a fallback in case Python +gives your git hosting site indigestion. (I know of no such sites.) + +It is no longer necessary to modify the script in order to put it +in place; in fact, this is now discouraged. It is entirely +configurable with the following git config variables: + +ciabot.project = name of the project +ciabot.repo = name of the project repo for gitweb/cgit purposes +ciabot.xmlrpc = if true, ship notifications via XML-RPC +ciabot.revformat = format in which the revision is shown + +The revformat variable may have the following values +raw -> full hex ID of commit +short -> first 12 chars of hex ID +describe -> describe relative to last tag, falling back to short + +ciabot.project defaults to the directory name of the repository toplevel. +ciabot.repo defaults to ciabot.project lowercased. +ciabot.xmlrpc defaults to True +ciabot.revformat defaults to 'describe'. + +This means that in the normal case you need not do any configuration at all, +however setting ciabot.project will allow the hook to run slightly faster. + +Once you've set these variables, try your script with -n to see the +notification message dumped to stdout and verify that it looks sane. + +To live-test these scripts, your project needs to have been registered with +the CIA site. Here are the steps: + +1. Open an IRC window on irc://freenode/commits or your registered + project IRC channel. + +2. Run ciabot.py and/or ciabot.sh from any directory under git + control. + +You should see a notification on the channel for your most recent commit. + +After verifying correct function, install one of these scripts either +in a post-commit hook or in an update hook. + +In post-commit, run it without arguments. It will query for +current HEAD and the latest commit ID to get the information it +needs. + +In update, call it with a refname followed by a list of commits: +You want to reverse the order git rev-list emits because it lists +from most recent to oldest. + +/path/to/ciabot.py ${refname} $(git rev-list ${oldhead}..${newhead} | tac) diff --git a/contrib/ciabot/README b/contrib/ciabot/README index 3b916acece..2dfe1f91f5 100644 --- a/contrib/ciabot/README +++ b/contrib/ciabot/README @@ -8,5 +8,4 @@ You probably want the Python version; it's faster, more capable, and better documented. The shell version is maintained only as a fallback for use on hosting sites that don't permit Python hook scripts. -You will find installation instructions for each script in its comment -header. +See the file INSTALL for installation instructions. diff --git a/contrib/ciabot/ciabot.py b/contrib/ciabot/ciabot.py index 9775dffb5d..bd24395d4c 100755 --- a/contrib/ciabot/ciabot.py +++ b/contrib/ciabot/ciabot.py @@ -10,44 +10,45 @@ # usage: ciabot.py [-V] [-n] [-p projectname] [refname [commits...]] # # This script is meant to be run either in a post-commit hook or in an -# update hook. If there's nothing unusual about your hosting setup, -# you can specify the project name with a -p option and avoid having -# to modify this script. Try it with -n to see the notification mail -# dumped to stdout and verify that it looks sane. With -V it dumps its -# version and exits. +# update hook. Try it with -n to see the notification mail dumped to +# stdout and verify that it looks sane. With -V it dumps its version +# and exits. # -# In post-commit, run it without arguments (other than possibly a -p -# option). It will query for current HEAD and the latest commit ID to -# get the information it needs. +# In post-commit, run it without arguments. It will query for +# current HEAD and the latest commit ID to get the information it +# needs. # # In update, call it with a refname followed by a list of commits: -# You want to reverse the order git rev-list emits becxause it lists +# You want to reverse the order git rev-list emits because it lists # from most recent to oldest. # # /path/to/ciabot.py ${refname} $(git rev-list ${oldhead}..${newhead} | tac) # -# Note: this script uses mail, not XML-RPC, in order to avoid stalling -# until timeout when the CIA XML-RPC server is down. +# Configuration variables affecting this script: # - +# ciabot.project = name of the project +# ciabot.repo = name of the project repo for gitweb/cgit purposes +# ciabot.xmlrpc = if true (default), ship notifications via XML-RPC +# ciabot.revformat = format in which the revision is shown # -# The project as known to CIA. You will either want to change this -# or invoke the script with a -p option to set it. +# ciabot.project defaults to the directory name of the repository toplevel. +# ciabot.repo defaults to ciabot.project lowercased. # -project=None - +# This means that in the normal case you need not do any configuration at all, +# but setting the project name will speed it up slightly. # -# You may not need to change these: +# The revformat variable may have the following values +# raw -> full hex ID of commit +# short -> first 12 chars of hex ID +# describe = -> describe relative to last tag, falling back to short +# The default is 'describe'. +# +# Note: the CIA project now says only XML-RPC is reliable, so +# we default to that. # -import os, sys, commands, socket, urllib - -# Name of the repository. -# You can hardwire this to make the script faster. -repo = os.path.basename(os.getcwd()) -# Fully-qualified domain name of this host. -# You can hardwire this to make the script faster. -host = socket.getfqdn() +import os, sys, commands, socket, urllib +from xml.sax.saxutils import escape # Changeset URL prefix for your repo: when the commit ID is appended # to this, it should point at a CGI that will display the commit @@ -72,7 +73,7 @@ CIA Python client for Git - %(gitver)s + %(version)s %(generator)s @@ -98,19 +99,18 @@ # No user-serviceable parts below this line: # -# Addresses for the e-mail. The from address is a dummy, since CIA -# will never reply to this mail. -fromaddr = "CIABOT-NOREPLY@" + host -toaddr = "cia@cia.navi.cx" +# Where to ship e-mail notifications. +toaddr = "cia@cia.vc" # Identify the generator script. # Should only change when the script itself gets a new home and maintainer. -generator="http://www.catb.org/~esr/ciabot.py" +generator = "http://www.catb.org/~esr/ciabot.py" +version = "3.6" def do(command): return commands.getstatusoutput(command)[1] -def report(refname, merged): +def report(refname, merged, xmlrpc=True): "Generate a commit notification to be reported to CIA" # Try to tinyfy a reference to a web view for this commit. @@ -121,32 +121,27 @@ def report(refname, merged): branch = os.path.basename(refname) - # Compute a shortnane for the revision - rev = do("git describe '"+ merged +"' 2>/dev/null") or merged[:12] - - # Extract the neta-information for the commit - rawcommit = do("git cat-file commit " + merged) + # Compute a description for the revision + if revformat == 'raw': + rev = merged + elif revformat == 'short': + rev = '' + else: # revformat == 'describe' + rev = do("git describe %s 2>/dev/null" % merged) + if not rev: + rev = merged[:12] + + # Extract the meta-information for the commit files=do("git diff-tree -r --name-only '"+ merged +"' | sed -e '1d' -e 's-.*-&-'") - inheader = True - headers = {} - logmsg = "" - for line in rawcommit.split("\n"): - if inheader: - if line: - fields = line.split() - headers[fields[0]] = " ".join(fields[1:]) - else: - inheader = False - else: - logmsg = line - break - (author, ts) = headers["author"].split(">") + metainfo = do("git log -1 '--pretty=format:%an <%ae>%n%at%n%s' " + merged) + (author, ts, logmsg) = metainfo.split("\n") + logmsg = escape(logmsg) - # This discards the part of the authors addrsss after @. - # Might be bnicece to ship the full email address, if not + # This discards the part of the author's address after @. + # Might be be nice to ship the full email address, if not # for spammers' address harvesters - getting this wrong # would make the freenode #commits channel into harvester heaven. - author = author.replace("<", "").split("@")[0].split()[-1] + author = escape(author.replace("<", "").split("@")[0].split()[-1]) # This ignores the timezone. Not clear what to do with it... ts = ts.strip().split()[0] @@ -155,8 +150,7 @@ def report(refname, merged): context.update(globals()) out = xml % context - - message = '''\ + mail = '''\ Message-ID: <%(merged)s.%(author)s@%(project)s> From: %(fromaddr)s To: %(toaddr)s @@ -165,34 +159,56 @@ def report(refname, merged): %(out)s''' % locals() - return message + if xmlrpc: + return out + else: + return mail if __name__ == "__main__": import getopt + # Get all config variables + revformat = do("git config --get ciabot.revformat") + project = do("git config --get ciabot.project") + repo = do("git config --get ciabot.repo") + xmlrpc = do("git config --get ciabot.xmlrpc") + xmlrpc = not (xmlrpc and xmlrpc == "false") + + host = socket.getfqdn() + fromaddr = "CIABOT-NOREPLY@" + host + try: - (options, arguments) = getopt.getopt(sys.argv[1:], "np:V") + (options, arguments) = getopt.getopt(sys.argv[1:], "np:xV") except getopt.GetoptError, msg: print "ciabot.py: " + str(msg) raise SystemExit, 1 - mailit = True + notify = True for (switch, val) in options: if switch == '-p': project = val elif switch == '-n': - mailit = False + notify = False + elif switch == '-x': + xmlrpc = True elif switch == '-V': - print "ciabot.py: version 3.2" + print "ciabot.py: version", version sys.exit(0) - # Cough and die if user has not specified a project + # The project variable defaults to the name of the repository toplevel. if not project: - sys.stderr.write("ciabot.py: no project specified, bailing out.\n") - sys.exit(1) - - # We'll need the git version number. - gitver = do("git --version").split()[0] + here = os.getcwd() + while True: + if os.path.exists(os.path.join(here, ".git")): + project = os.path.basename(here) + break + elif here == '/': + sys.stderr.write("ciabot.py: no .git below root!\n") + sys.exit(1) + here = os.path.dirname(here) + + if not repo: + repo = project.lower() urlprefix = urlprefix % globals() @@ -205,18 +221,29 @@ def report(refname, merged): refname = arguments[0] merges = arguments[1:] - if mailit: - import smtplib - server = smtplib.SMTP('localhost') + if notify: + if xmlrpc: + import xmlrpclib + server = xmlrpclib.Server('http://cia.vc/RPC2'); + else: + import smtplib + server = smtplib.SMTP('localhost') for merged in merges: - message = report(refname, merged) - if mailit: - server.sendmail(fromaddr, [toaddr], message) - else: + message = report(refname, merged, xmlrpc) + if not notify: print message + elif xmlrpc: + try: + # RPC server is flaky, this can fail due to timeout. + server.hub.deliver(message) + except socket.error, e: + sys.stderr.write("%s\n" % e) + else: + server.sendmail(fromaddr, [toaddr], message) - if mailit: - server.quit() + if notify: + if not xmlrpc: + server.quit() #End diff --git a/contrib/ciabot/ciabot.sh b/contrib/ciabot/ciabot.sh index eb87bba38e..3fbbc534ae 100755 --- a/contrib/ciabot/ciabot.sh +++ b/contrib/ciabot/ciabot.sh @@ -3,6 +3,8 @@ # Copyright (c) 2006 Fernando J. Pereda # Copyright (c) 2008 Natanael Copa # Copyright (c) 2010 Eric S. Raymond +# Assistance and review by Petr Baudis, author of ciabot.pl, +# is gratefully acknowledged. # # This is a version 3.x of ciabot.sh; use -V to find the exact # version. Versions 1 and 2 were shipped in 2006 and 2008 and are not @@ -11,6 +13,7 @@ # Note: This script should be considered obsolete. # There is a faster, better-documented rewrite in Python: find it as ciabot.py # Use this only if your hosting site forbids Python hooks. +# It requires: git(1), hostname(1), cut(1), sendmail(1), and wget(1). # # Originally based on Git ciabot.pl by Petr Baudis. # This script contains porcelain and porcelain byproducts. @@ -18,15 +21,13 @@ # usage: ciabot.sh [-V] [-n] [-p projectname] [refname commit] # # This script is meant to be run either in a post-commit hook or in an -# update hook. If there's nothing unusual about your hosting setup, -# you can specify the project name with a -p option and avoid having -# to modify this script. Try it with -n first to see the notification -# mail dumped to stdout and verify that it looks sane. Use -V to dump -# the version and exit. +# update hook. Try it with -n to see the notification mail dumped to +# stdout and verify that it looks sane. With -V it dumps its version +# and exits. # -# In post-commit, run it without arguments (other than possibly a -p -# option). It will query for current HEAD and the latest commit ID to -# get the information it needs. +# In post-commit, run it without arguments. It will query for +# current HEAD and the latest commit ID to get the information it +# needs. # # In update, you have to call it once per merged commit: # @@ -34,33 +35,76 @@ # oldhead=$2 # newhead=$3 # for merged in $(git rev-list ${oldhead}..${newhead} | tac) ; do -# /path/to/ciabot.bash ${refname} ${merged} +# /path/to/ciabot.sh ${refname} ${merged} # done # -# The reason for the tac call ids that git rev-list emits commits from +# The reason for the tac call is that git rev-list emits commits from # most recent to least - better to ship notifactions from oldest to newest. # -# Note: this script uses mail, not XML-RPC, in order to avoid stalling -# until timeout when the CIA XML-RPC server is down. +# Configuration variables affecting this script: # - +# ciabot.project = name of the project +# ciabot.repo = name of the project repo for gitweb/cgit purposes +# ciabot.revformat = format in which the revision is shown # -# The project as known to CIA. You will either want to change this -# or set the project name with a -p option. +# ciabot.project defaults to the directory name of the repository toplevel. +# ciabot.repo defaults to ciabot.project lowercased. # -project= - +# This means that in the normal case you need not do any configuration at all, +# but setting the project name will speed it up slightly. # -# You may not need to change these: +# The revformat variable may have the following values +# raw -> full hex ID of commit +# short -> first 12 chars of hex ID +# describe = -> describe relative to last tag, falling back to short +# The default is 'describe'. # +# Note: the shell ancestors of this script used mail, not XML-RPC, in +# order to avoid stalling until timeout when the CIA XML-RPC server is +# down. It is unknown whether this is still an issue in 2010, but +# XML-RPC would be annoying to do from sh in any case. (XML-RPC does +# have the advantage that it guarantees notification of multiple commits +# shpped from an update in their actual order.) +# + +# The project as known to CIA. You can set this with a -p option, +# or let it default to the directory name of the repo toplevel. +project=$(git config --get ciabot.project) + +if [ -z $project ] +then + here=`pwd`; + while :; do + if [ -d $here/.git ] + then + project=`basename $here` + break + elif [ $here = '/' ] + then + echo "ciabot.sh: no .git below root!" + exit 1 + fi + here=`dirname $here` + done +fi -# Name of the repository. -# You can hardwire this to make the script faster. -repo="`basename ${PWD}`" +# Name of the repo for gitweb/cgit purposes +repo=$(git config --get ciabot.repo) +[ -z $repo] && repo=$(echo "${project}" | tr '[A-Z]' '[a-z]') -# Fully qualified domain name of the repo host. -# You can hardwire this to make the script faster. -host=`hostname --fqdn` +# What revision format do we want in the summary? +revformat=$(git config --get ciabot.revformat) + +# Fully qualified domain name of the repo host. You can hardwire this +# to make the script faster. The -f option works under Linux and FreeBSD, +# but not OpenBSD and NetBSD. But under OpenBSD and NetBSD, +# hostname without options gives the FQDN. +if hostname -f >/dev/null 2>&1 +then + hostname=`hostname -f` +else + hostname=`hostname` +fi # Changeset URL prefix for your repo: when the commit ID is appended # to this, it should point at a CGI that will display the commit @@ -73,13 +117,14 @@ urlprefix="http://${host}/cgi-bin/cgit.cgi/${repo}/commit/?id=" # You probably will not need to change the following: # -# Identify the script. Should change only when the script itself -# gets a new home and maintainer. +# Identify the script. The 'generator' variable should change only +# when the script itself gets a new home and maintainer. generator="http://www.catb.org/~esr/ciabot/ciabot.sh" +version=3.5 # Addresses for the e-mail -from="CIABOT-NOREPLY@${host}" -to="cia@cia.navi.cx" +from="CIABOT-NOREPLY@${hostname}" +to="cia@cia.vc" # SMTP client to use - may need to edit the absolute pathname for your system sendmail="sendmail -t -f ${from}" @@ -97,7 +142,7 @@ do case $opt in p) project=$2; shift ; shift ;; n) mode=dumpit; shift ;; - V) echo "ciabot.sh: version 3.2"; exit 0; shift ;; + V) echo "ciabot.sh: version $version"; exit 0; shift ;; esac done @@ -128,33 +173,29 @@ fi refname=${refname##refs/heads/} -gitver=$(git --version) -gitver=${gitver##* } - -rev=$(git describe ${merged} 2>/dev/null) -# ${merged:0:12} was the only bashism left in the 2008 version of this -# script, according to checkbashisms. Replace it with ${merged} here -# because it was just a fallback anyway, and it's worth accepting a -# longer fallback for faster execution and removing the bash -# dependency. -[ -z ${rev} ] && rev=${merged} +case $revformat in +raw) rev=$merged ;; +short) rev='' ;; +*) rev=$(git describe ${merged} 2>/dev/null) ;; +esac +[ -z ${rev} ] && rev=$(echo "$merged" | cut -c 1-12) -# This discards the part of the author's address after @. +# We discard the part of the author's address after @. # Might be nice to ship the full email address, if not # for spammers' address harvesters - getting this wrong # would make the freenode #commits channel into harvester heaven. -rawcommit=$(git cat-file commit ${merged}) -author=$(echo "$rawcommit" | sed -n -e '/^author .*<\([^@]*\).*$/s--\1-p') -logmessage=$(echo "$rawcommit" | sed -e '1,/^$/d' | head -n 1) -logmessage=$(echo "$logmessage" | sed 's/\&/&\;/g; s//>\;/g') -ts=$(echo "$rawcommit" | sed -n -e '/^author .*> \([0-9]\+\).*$/s--\1-p') +author=$(git log -1 '--pretty=format:%an <%ae>' $merged) +author=$(echo "$author" | sed -n -e '/^.*<\([^@]*\).*$/s--\1-p') + +logmessage=$(git log -1 '--pretty=format:%s' $merged) +ts=$(git log -1 '--pretty=format:%at' $merged) files=$(git diff-tree -r --name-only ${merged} | sed -e '1d' -e 's-.*-&-') out=" CIA Shell client for Git - ${gitver} + ${version} ${generator} diff --git a/diff-lib.c b/diff-lib.c index fc0dff31b5..f35de0ffa0 100644 --- a/diff-lib.c +++ b/diff-lib.c @@ -206,7 +206,8 @@ int run_diff_files(struct rev_info *revs, unsigned int option) if (silent_on_removed) continue; diff_addremove(&revs->diffopt, '-', ce->ce_mode, - ce->sha1, ce->name, 0); + ce->sha1, !is_null_sha1(ce->sha1), + ce->name, 0); continue; } changed = match_stat_with_submodule(&revs->diffopt, ce, &st, @@ -220,6 +221,7 @@ int run_diff_files(struct rev_info *revs, unsigned int option) newmode = ce_mode_from_stat(ce, st.st_mode); 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)), ce->name, 0, dirty_submodule); } @@ -236,11 +238,12 @@ int run_diff_files(struct rev_info *revs, unsigned int option) static void diff_index_show_file(struct rev_info *revs, const char *prefix, struct cache_entry *ce, - const unsigned char *sha1, unsigned int mode, + const unsigned char *sha1, int sha1_valid, + unsigned int mode, unsigned dirty_submodule) { diff_addremove(&revs->diffopt, prefix[0], mode, - sha1, ce->name, dirty_submodule); + sha1, sha1_valid, ce->name, dirty_submodule); } static int get_stat_data(struct cache_entry *ce, @@ -295,7 +298,7 @@ static void show_new_file(struct rev_info *revs, &dirty_submodule, &revs->diffopt) < 0) return; - diff_index_show_file(revs, "+", new, sha1, mode, dirty_submodule); + diff_index_show_file(revs, "+", new, sha1, !is_null_sha1(sha1), mode, dirty_submodule); } static int show_modified(struct rev_info *revs, @@ -312,7 +315,7 @@ static int show_modified(struct rev_info *revs, &dirty_submodule, &revs->diffopt) < 0) { if (report_missing) diff_index_show_file(revs, "-", old, - old->sha1, old->ce_mode, 0); + old->sha1, 1, old->ce_mode, 0); return -1; } @@ -347,7 +350,8 @@ static int show_modified(struct rev_info *revs, return 0; diff_change(&revs->diffopt, oldmode, mode, - old->sha1, sha1, old->name, 0, dirty_submodule); + old->sha1, sha1, 1, !is_null_sha1(sha1), + old->name, 0, dirty_submodule); return 0; } @@ -380,7 +384,7 @@ static void do_oneway_diff(struct unpack_trees_options *o, struct diff_filepair *pair; pair = diff_unmerge(&revs->diffopt, idx->name); if (tree) - fill_filespec(pair->one, tree->sha1, tree->ce_mode); + fill_filespec(pair->one, tree->sha1, 1, tree->ce_mode); return; } @@ -396,7 +400,7 @@ static void do_oneway_diff(struct unpack_trees_options *o, * Something removed from the tree? */ if (!idx) { - diff_index_show_file(revs, "-", tree, tree->sha1, tree->ce_mode, 0); + diff_index_show_file(revs, "-", tree, tree->sha1, 1, tree->ce_mode, 0); return; } diff --git a/diff-no-index.c b/diff-no-index.c index 7d805a06af..0b46a0f79f 100644 --- a/diff-no-index.c +++ b/diff-no-index.c @@ -82,7 +82,7 @@ static struct diff_filespec *noindex_filespec(const char *name, int mode) if (!name) name = "/dev/null"; s = alloc_filespec(name); - fill_filespec(s, null_sha1, mode); + fill_filespec(s, null_sha1, 0, mode); if (name == file_from_standard_input) populate_from_stdin(s); return s; diff --git a/diff.c b/diff.c index 95706a5b40..359f40a210 100644 --- a/diff.c +++ b/diff.c @@ -2541,12 +2541,12 @@ void free_filespec(struct diff_filespec *spec) } void fill_filespec(struct diff_filespec *spec, const unsigned char *sha1, - unsigned short mode) + int sha1_valid, unsigned short mode) { if (mode) { spec->mode = canon_mode(mode); hashcpy(spec->sha1, sha1); - spec->sha1_valid = !is_null_sha1(sha1); + spec->sha1_valid = sha1_valid; } } @@ -4693,6 +4693,7 @@ static int is_submodule_ignored(const char *path, struct diff_options *options) void diff_addremove(struct diff_options *options, int addremove, unsigned mode, const unsigned char *sha1, + int sha1_valid, const char *concatpath, unsigned dirty_submodule) { struct diff_filespec *one, *two; @@ -4724,9 +4725,9 @@ void diff_addremove(struct diff_options *options, two = alloc_filespec(concatpath); if (addremove != '+') - fill_filespec(one, sha1, mode); + fill_filespec(one, sha1, sha1_valid, mode); if (addremove != '-') { - fill_filespec(two, sha1, mode); + fill_filespec(two, sha1, sha1_valid, mode); two->dirty_submodule = dirty_submodule; } @@ -4739,6 +4740,7 @@ void diff_change(struct diff_options *options, unsigned old_mode, unsigned new_mode, const unsigned char *old_sha1, const unsigned char *new_sha1, + int old_sha1_valid, int new_sha1_valid, const char *concatpath, unsigned old_dirty_submodule, unsigned new_dirty_submodule) { @@ -4753,6 +4755,8 @@ void diff_change(struct diff_options *options, const unsigned char *tmp_c; tmp = old_mode; old_mode = new_mode; new_mode = tmp; tmp_c = old_sha1; old_sha1 = new_sha1; new_sha1 = tmp_c; + tmp = old_sha1_valid; old_sha1_valid = new_sha1_valid; + new_sha1_valid = tmp; tmp = old_dirty_submodule; old_dirty_submodule = new_dirty_submodule; new_dirty_submodule = tmp; } @@ -4763,8 +4767,8 @@ void diff_change(struct diff_options *options, one = alloc_filespec(concatpath); two = alloc_filespec(concatpath); - fill_filespec(one, old_sha1, old_mode); - fill_filespec(two, new_sha1, new_mode); + fill_filespec(one, old_sha1, old_sha1_valid, old_mode); + fill_filespec(two, new_sha1, new_sha1_valid, new_mode); one->dirty_submodule = old_dirty_submodule; two->dirty_submodule = new_dirty_submodule; diff --git a/diff.h b/diff.h index e027650cb0..815dd7af57 100644 --- a/diff.h +++ b/diff.h @@ -19,12 +19,14 @@ typedef void (*change_fn_t)(struct diff_options *options, unsigned old_mode, unsigned new_mode, const unsigned char *old_sha1, const unsigned char *new_sha1, + int old_sha1_valid, int new_sha1_valid, const char *fullpath, unsigned old_dirty_submodule, unsigned new_dirty_submodule); typedef void (*add_remove_fn_t)(struct diff_options *options, int addremove, unsigned mode, const unsigned char *sha1, + int sha1_valid, const char *fullpath, unsigned dirty_submodule); typedef void (*diff_format_fn_t)(struct diff_queue_struct *q, @@ -214,12 +216,15 @@ extern void diff_addremove(struct diff_options *, int addremove, unsigned mode, const unsigned char *sha1, + int sha1_valid, const char *fullpath, unsigned dirty_submodule); extern void diff_change(struct diff_options *, unsigned mode1, unsigned mode2, const unsigned char *sha1, const unsigned char *sha2, + int sha1_valid, + int sha2_valid, const char *fullpath, unsigned dirty_submodule1, unsigned dirty_submodule2); diff --git a/diffcore-rename.c b/diffcore-rename.c index 216a7a4bbc..512d0ac5fd 100644 --- a/diffcore-rename.c +++ b/diffcore-rename.c @@ -48,7 +48,7 @@ static struct diff_rename_dst *locate_rename_dst(struct diff_filespec *two, memmove(rename_dst + first + 1, rename_dst + first, (rename_dst_nr - first - 1) * sizeof(*rename_dst)); rename_dst[first].two = alloc_filespec(two->path); - fill_filespec(rename_dst[first].two, two->sha1, two->mode); + fill_filespec(rename_dst[first].two, two->sha1, two->sha1_valid, two->mode); rename_dst[first].pair = NULL; return &(rename_dst[first]); } diff --git a/diffcore.h b/diffcore.h index be0739c5c4..1c16c8595b 100644 --- a/diffcore.h +++ b/diffcore.h @@ -55,7 +55,7 @@ struct diff_filespec { extern struct diff_filespec *alloc_filespec(const char *); extern void free_filespec(struct diff_filespec *); extern void fill_filespec(struct diff_filespec *, const unsigned char *, - unsigned short); + int, unsigned short); extern int diff_populate_filespec(struct diff_filespec *, int); extern void diff_free_filespec_data(struct diff_filespec *); diff --git a/fsck.c b/fsck.c index 4c63b2cc41..7395ef6a42 100644 --- a/fsck.c +++ b/fsck.c @@ -139,6 +139,7 @@ static int verify_ordered(unsigned mode1, const char *name1, unsigned mode2, con static int fsck_tree(struct tree *item, int strict, fsck_error error_func) { int retval; + int has_null_sha1 = 0; int has_full_path = 0; int has_empty_name = 0; int has_zero_pad = 0; @@ -157,9 +158,12 @@ static int fsck_tree(struct tree *item, int strict, fsck_error error_func) while (desc.size) { unsigned mode; const char *name; + const unsigned char *sha1; - tree_entry_extract(&desc, &name, &mode); + sha1 = tree_entry_extract(&desc, &name, &mode); + if (is_null_sha1(sha1)) + has_null_sha1 = 1; if (strchr(name, '/')) has_full_path = 1; if (!*name) @@ -207,6 +211,8 @@ static int fsck_tree(struct tree *item, int strict, fsck_error error_func) } retval = 0; + if (has_null_sha1) + retval += error_func(&item->object, FSCK_WARN, "contains entries pointing to null sha1"); if (has_full_path) retval += error_func(&item->object, FSCK_WARN, "contains full pathnames"); if (has_empty_name) diff --git a/git-rebase--interactive.sh b/git-rebase--interactive.sh index 0d2056f027..a09e8423dd 100644 --- a/git-rebase--interactive.sh +++ b/git-rebase--interactive.sh @@ -569,11 +569,10 @@ do_next () { test -s "$todo" && return comment_for_reflog finish && - shortonto=$(git rev-parse --short $onto) && newhead=$(git rev-parse HEAD) && case $head_name in refs/*) - message="$GIT_REFLOG_ACTION: $head_name onto $shortonto" && + message="$GIT_REFLOG_ACTION: $head_name onto $onto" && git update-ref -m "$message" $head_name $newhead $orig_head && git symbolic-ref \ -m "$GIT_REFLOG_ACTION: returning to $head_name" \ diff --git a/git-send-email.perl b/git-send-email.perl index ef30c557c7..664713709c 100755 --- a/git-send-email.perl +++ b/git-send-email.perl @@ -862,11 +862,13 @@ sub make_message_id { sub unquote_rfc2047 { local ($_) = @_; my $encoding; - if (s/=\?([^?]+)\?q\?(.*)\?=/$2/g) { + s{=\?([^?]+)\?q\?(.*?)\?=}{ $encoding = $1; - s/_/ /g; - s/=([0-9A-F]{2})/chr(hex($1))/eg; - } + my $e = $2; + $e =~ s/_/ /g; + $e =~ s/=([0-9A-F]{2})/chr(hex($1))/eg; + $e; + }eg; return wantarray ? ($_, $encoding) : $_; } diff --git a/git-sh-setup.sh b/git-sh-setup.sh index 770a86e2b7..ee0e0bc045 100644 --- a/git-sh-setup.sh +++ b/git-sh-setup.sh @@ -9,8 +9,12 @@ # you would cause "cd" to be taken to unexpected places. If you # like CDPATH, define it for your interactive shell sessions without # exporting it. +# But we protect ourselves from such a user mistake nevertheless. unset CDPATH +# Similarly for IFS +unset IFS + git_broken_path_fix () { case ":$PATH:" in *:$1:*) : ok ;; diff --git a/git-svn.perl b/git-svn.perl index 5711c5719f..828b8f0c8e 100755 --- a/git-svn.perl +++ b/git-svn.perl @@ -777,6 +777,44 @@ sub populate_merge_info { return undef; } +sub dcommit_rebase { + my ($is_last, $current, $fetched_ref, $svn_error) = @_; + my @diff; + + if ($svn_error) { + print STDERR "\nERROR from SVN:\n", + $svn_error->expanded_message, "\n"; + } + unless ($_no_rebase) { + # we always want to rebase against the current HEAD, + # not any head that was passed to us + @diff = command('diff-tree', $current, + $fetched_ref, '--'); + my @finish; + if (@diff) { + @finish = rebase_cmd(); + print STDERR "W: $current and ", $fetched_ref, + " differ, using @finish:\n", + join("\n", @diff), "\n"; + } elsif ($is_last) { + print "No changes between ", $current, " and ", + $fetched_ref, + "\nResetting to the latest ", + $fetched_ref, "\n"; + @finish = qw/reset --mixed/; + } + command_noisy(@finish, $fetched_ref) if @finish; + } + if ($svn_error) { + die "ERROR: Not all changes have been committed into SVN" + .($_no_rebase ? ".\n" : ", however the committed\n" + ."ones (if any) seem to be successfully integrated " + ."into the working tree.\n") + ."Please see the above messages for details.\n"; + } + return @diff; +} + sub cmd_dcommit { my $head = shift; command_noisy(qw/update-index --refresh/); @@ -904,6 +942,7 @@ sub cmd_dcommit { } my $rewritten_parent; + my $current_head = command_oneline(qw/rev-parse HEAD/); Git::SVN::remove_username($expect_url); if (defined($_merge_info)) { $_merge_info =~ tr{ }{\n}; @@ -943,6 +982,14 @@ sub cmd_dcommit { }, mergeinfo => $_merge_info, svn_path => ''); + + my $err_handler = $SVN::Error::handler; + $SVN::Error::handler = sub { + my $err = shift; + dcommit_rebase(1, $current_head, $gs->refname, + $err); + }; + if (!Git::SVN::Editor->new(\%ed_opts)->apply_diff) { print "No changes\n$d~1 == $d\n"; } elsif ($parents->{$d} && @{$parents->{$d}}) { @@ -950,31 +997,19 @@ sub cmd_dcommit { $parents->{$d}; } $_fetch_all ? $gs->fetch_all : $gs->fetch; + $SVN::Error::handler = $err_handler; $last_rev = $cmt_rev; next if $_no_rebase; - # we always want to rebase against the current HEAD, - # not any head that was passed to us - my @diff = command('diff-tree', $d, - $gs->refname, '--'); - my @finish; - if (@diff) { - @finish = rebase_cmd(); - print STDERR "W: $d and ", $gs->refname, - " differ, using @finish:\n", - join("\n", @diff), "\n"; - } else { - print "No changes between current HEAD and ", - $gs->refname, - "\nResetting to the latest ", - $gs->refname, "\n"; - @finish = qw/reset --mixed/; - } - command_noisy(@finish, $gs->refname); + my @diff = dcommit_rebase(@$linear_refs == 0, $d, + $gs->refname, undef); - $rewritten_parent = command_oneline(qw/rev-parse HEAD/); + $rewritten_parent = command_oneline(qw/rev-parse/, + $gs->refname); if (@diff) { + $current_head = command_oneline(qw/rev-parse + HEAD/); @refs = (); my ($url_, $rev_, $uuid_, $gs_) = working_head_info('HEAD', \@refs); @@ -1019,6 +1054,7 @@ sub cmd_dcommit { } $parents = \%p; $linear_refs = \@l; + undef $last_rev; } } } diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl index 3d6a705388..7f8c1878d4 100755 --- a/gitweb/gitweb.perl +++ b/gitweb/gitweb.perl @@ -54,6 +54,11 @@ sub evaluate_uri { # to build the base URL ourselves: our $path_info = decode_utf8($ENV{"PATH_INFO"}); if ($path_info) { + # $path_info has already been URL-decoded by the web server, but + # $my_url and $my_uri have not. URL-decode them so we can properly + # strip $path_info. + $my_url = unescape($my_url); + $my_uri = unescape($my_uri); if ($my_url =~ s,\Q$path_info\E$,, && $my_uri =~ s,\Q$path_info\E$,, && defined $ENV{'SCRIPT_NAME'}) { diff --git a/perl/Git/SVN.pm b/perl/Git/SVN.pm index b8b34744ea..8478d0c952 100644 --- a/perl/Git/SVN.pm +++ b/perl/Git/SVN.pm @@ -1616,6 +1616,24 @@ sub tie_for_persistent_memoization { Memoize::unmemoize 'has_no_changes'; } + sub clear_memoized_mergeinfo_caches { + die "Only call this method in non-memoized context" if ($memoized); + + my $cache_path = "$ENV{GIT_DIR}/svn/.caches/"; + return unless -d $cache_path; + + for my $cache_file (("$cache_path/lookup_svn_merge", + "$cache_path/check_cherry_pick", + "$cache_path/has_no_changes")) { + for my $suffix (qw(yaml db)) { + my $file = "$cache_file.$suffix"; + next unless -e $file; + unlink($file) or die "unlink($file) failed: $!\n"; + } + } + } + + Memoize::memoize 'Git::SVN::repos_root'; } @@ -2107,8 +2125,13 @@ sub rev_map_set { sysopen(my $fh, $db_lock, O_RDWR | O_CREAT) or croak "Couldn't open $db_lock: $!\n"; - $update_ref eq 'reset' ? _rev_map_reset($fh, $rev, $commit) : - _rev_map_set($fh, $rev, $commit); + if ($update_ref eq 'reset') { + clear_memoized_mergeinfo_caches(); + _rev_map_reset($fh, $rev, $commit); + } else { + _rev_map_set($fh, $rev, $commit); + } + if ($sync) { $fh->flush or die "Couldn't flush $db_lock: $!\n"; $fh->sync or die "Couldn't sync $db_lock: $!\n"; diff --git a/po/de.po b/po/de.po index c44cabe7b4..2739bc0a31 100644 --- a/po/de.po +++ b/po/de.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: git 1.7.12\n" "Report-Msgid-Bugs-To: Git Mailing List \n" -"POT-Creation-Date: 2012-07-30 09:18+0800\n" +"POT-Creation-Date: 2012-08-06 23:47+0800\n" "PO-Revision-Date: 2012-03-28 18:46+0200\n" "Last-Translator: Ralf Thielow \n" "Language-Team: German\n" @@ -232,8 +232,8 @@ msgstr "" "%s" #: diff.c:1400 -msgid " 0 files changed\n" -msgstr " 0 Dateien geändert\n" +msgid " 0 files changed" +msgstr " 0 Dateien geändert" #: diff.c:1404 #, c-format @@ -347,6 +347,272 @@ msgstr[1] "" "\n" "Hast du eines von diesen gemeint?" +#: merge-recursive.c:190 +#, c-format +msgid "(bad commit)\n" +msgstr "(ungültige Version)\n" + +#: merge-recursive.c:206 +#, c-format +msgid "addinfo_cache failed for path '%s'" +msgstr "addinfo_cache für Pfad '%s' fehlgeschlagen" + +#: merge-recursive.c:268 +msgid "error building trees" +msgstr "Fehler beim Erstellen der Bäume" + +#: merge-recursive.c:497 +msgid "diff setup failed" +msgstr "diff_setup_done fehlgeschlagen" + +#: merge-recursive.c:627 +msgid "merge-recursive: disk full?" +msgstr "merge-recursive: Festplatte voll?" + +#: merge-recursive.c:690 +#, c-format +msgid "failed to create path '%s'%s" +msgstr "Fehler beim Erstellen des Pfades '%s'%s" + +#: merge-recursive.c:701 +#, c-format +msgid "Removing %s to make room for subdirectory\n" +msgstr "Entferne %s um Platz für Unterverzeichnis zu schaffen\n" + +#. something else exists +#. .. but not some other error (who really cares what?) +#: merge-recursive.c:715 merge-recursive.c:736 +msgid ": perhaps a D/F conflict?" +msgstr ": vielleicht ein Verzeichnis/Datei-Konflikt?" + +#: merge-recursive.c:726 +#, c-format +msgid "refusing to lose untracked file at '%s'" +msgstr "verweigere, da unbeobachtete Dateien in '%s' verloren gehen würden" + +#: merge-recursive.c:766 +#, c-format +msgid "cannot read object %s '%s'" +msgstr "kann Objekt %s '%s' nicht lesen" + +#: merge-recursive.c:768 +#, c-format +msgid "blob expected for %s '%s'" +msgstr "Blob erwartet für %s '%s'" + +#: merge-recursive.c:791 builtin/clone.c:302 +#, c-format +msgid "failed to open '%s'" +msgstr "Fehler beim Öffnen von '%s'" + +#: merge-recursive.c:799 +#, c-format +msgid "failed to symlink '%s'" +msgstr "Fehler beim Erstellen einer symbolischen Verknüpfung für '%s'" + +#: merge-recursive.c:802 +#, c-format +msgid "do not know what to do with %06o %s '%s'" +msgstr "weiß nicht was mit %06o %s '%s' zu machen ist" + +#: merge-recursive.c:939 +msgid "Failed to execute internal merge" +msgstr "Fehler bei Ausführung der internen Zusammenführung" + +#: merge-recursive.c:943 +#, c-format +msgid "Unable to add %s to database" +msgstr "Konnte %s nicht zur Datenbank hinzufügen" + +#: merge-recursive.c:959 +msgid "unsupported object type in the tree" +msgstr "nicht unterstützter Objekttyp im Baum" + +#: merge-recursive.c:1038 merge-recursive.c:1052 +#, c-format +msgid "" +"CONFLICT (%s/delete): %s deleted in %s and %s in %s. Version %s of %s left " +"in tree." +msgstr "" +"KONFLIKT (%s/löschen): %s gelöscht in %s und %s in %s. Stand %s von %s wurde " +"im Arbeitsbereich gelassen." + +#: merge-recursive.c:1044 merge-recursive.c:1057 +#, c-format +msgid "" +"CONFLICT (%s/delete): %s deleted in %s and %s in %s. Version %s of %s left " +"in tree at %s." +msgstr "" +"KONFLIKT (%s/löschen): %s gelöscht in %s und %s in %s. Stand %s von %s wurde " +"im Arbeitsbereich bei %s gelassen." + +#: merge-recursive.c:1098 +msgid "rename" +msgstr "umbenennen" + +#: merge-recursive.c:1098 +msgid "renamed" +msgstr "umbenannt" + +#: merge-recursive.c:1154 +#, c-format +msgid "%s is a directory in %s adding as %s instead" +msgstr "%s ist ein Verzeichnis in %s, füge es stattdessen als %s hinzu" + +#: merge-recursive.c:1176 +#, c-format +msgid "" +"CONFLICT (rename/rename): Rename \"%s\"->\"%s\" in branch \"%s\" rename \"%s" +"\"->\"%s\" in \"%s\"%s" +msgstr "" +"KONFLIKT (umbenennen/umbenennen): Benenne um \"%s\"->\"%s\" in Zweig \"%s\" " +"und \"%s\"->\"%s\" in Zweig \"%s\"%s" + +#: merge-recursive.c:1181 +msgid " (left unresolved)" +msgstr " (bleibt unaufgelöst)" + +#: merge-recursive.c:1235 +#, c-format +msgid "CONFLICT (rename/rename): Rename %s->%s in %s. Rename %s->%s in %s" +msgstr "" +"KONFLIKT (umbenennen/umbenennen): Benenne um %s->%s in %s. Benenne um %s->%s " +"in %s" + +#: merge-recursive.c:1265 +#, c-format +msgid "Renaming %s to %s and %s to %s instead" +msgstr "Benenne stattdessen %s nach %s und %s nach %s um" + +#: merge-recursive.c:1464 +#, c-format +msgid "CONFLICT (rename/add): Rename %s->%s in %s. %s added in %s" +msgstr "" +"KONFLIKT (umbenennen/hinzufügen): Benenne um %s->%s in %s. %s hinzugefügt in " +"%s" + +#: merge-recursive.c:1474 +#, c-format +msgid "Adding merged %s" +msgstr "Füge zusammengeführte Datei %s hinzu" + +#: merge-recursive.c:1479 merge-recursive.c:1677 +#, c-format +msgid "Adding as %s instead" +msgstr "Füge stattdessen als %s hinzu" + +#: merge-recursive.c:1530 +#, c-format +msgid "cannot read object %s" +msgstr "kann Objekt %s nicht lesen" + +#: merge-recursive.c:1533 +#, c-format +msgid "object %s is not a blob" +msgstr "Objekt %s ist kein Blob" + +#: merge-recursive.c:1581 +msgid "modify" +msgstr "ändern" + +#: merge-recursive.c:1581 +msgid "modified" +msgstr "geändert" + +#: merge-recursive.c:1591 +msgid "content" +msgstr "Inhalt" + +#: merge-recursive.c:1598 +msgid "add/add" +msgstr "hinzufügen/hinzufügen" + +#: merge-recursive.c:1632 +#, c-format +msgid "Skipped %s (merged same as existing)" +msgstr "%s ausgelassen (Ergebnis der Zusammenführung existiert bereits)" + +#: merge-recursive.c:1646 +#, c-format +msgid "Auto-merging %s" +msgstr "automatische Zusammenführung von %s" + +#: merge-recursive.c:1650 git-submodule.sh:844 +msgid "submodule" +msgstr "Unterprojekt" + +#: merge-recursive.c:1651 +#, c-format +msgid "CONFLICT (%s): Merge conflict in %s" +msgstr "KONFLIKT (%s): Zusammenführungskonflikt in %s" + +#: merge-recursive.c:1741 +#, c-format +msgid "Removing %s" +msgstr "Entferne %s" + +#: merge-recursive.c:1766 +msgid "file/directory" +msgstr "Datei/Verzeichnis" + +#: merge-recursive.c:1772 +msgid "directory/file" +msgstr "Verzeichnis/Datei" + +#: merge-recursive.c:1777 +#, c-format +msgid "CONFLICT (%s): There is a directory with name %s in %s. Adding %s as %s" +msgstr "" +"KONFLIKT (%s): Es existiert bereits ein Verzeichnis %s in %s. Füge %s als %s " +"hinzu." + +#: merge-recursive.c:1787 +#, c-format +msgid "Adding %s" +msgstr "Füge %s hinzu" + +#: merge-recursive.c:1804 +msgid "Fatal merge failure, shouldn't happen." +msgstr "Fataler Fehler bei der Zusammenführung. Sollte nicht passieren." + +#: merge-recursive.c:1823 +msgid "Already up-to-date!" +msgstr "Bereits aktuell!" + +#: merge-recursive.c:1832 +#, c-format +msgid "merging of trees %s and %s failed" +msgstr "Zusammenführen der Bäume %s und %s fehlgeschlagen" + +#: merge-recursive.c:1862 +#, c-format +msgid "Unprocessed path??? %s" +msgstr "unverarbeiteter Pfad??? %s" + +#: merge-recursive.c:1907 +msgid "Merging:" +msgstr "Zusammenführung:" + +#: merge-recursive.c:1920 +#, c-format +msgid "found %u common ancestor:" +msgid_plural "found %u common ancestors:" +msgstr[0] "%u gemeinsamen Vorfahren gefunden" +msgstr[1] "%u gemeinsame Vorfahren gefunden" + +#: merge-recursive.c:1957 +msgid "merge returned no commit" +msgstr "Zusammenführung hat keine Version zurückgegeben" + +#: merge-recursive.c:2014 +#, c-format +msgid "Could not parse object '%s'" +msgstr "Konnte Objekt '%s' nicht parsen." + +#: merge-recursive.c:2026 builtin/merge.c:697 +msgid "Unable to write index." +msgstr "Konnte Bereitstellung nicht schreiben." + #: parse-options.c:494 msgid "..." msgstr "..." @@ -1537,8 +1803,9 @@ msgstr "wendet den Patch an (Benutzung mit --stat/--summary/--check)" #: builtin/apply.c:4312 msgid "attempt three-way merge if a patch does not apply" -msgstr "versucht 3-Wege-Zusammenführung, wenn der Patch nicht angewendet " -"werden konnte" +msgstr "" +"versucht 3-Wege-Zusammenführung, wenn der Patch nicht angewendet werden " +"konnte" #: builtin/apply.c:4314 msgid "build a temporary index based on embedded index information" @@ -2146,11 +2413,6 @@ msgstr "Entferne nicht %s\n" msgid "reference repository '%s' is not a local directory." msgstr "Referenziertes Projektarchiv '%s' ist kein lokales Verzeichnis." -#: builtin/clone.c:302 -#, c-format -msgid "failed to open '%s'" -msgstr "Fehler beim Öffnen von '%s'" - #: builtin/clone.c:306 #, c-format msgid "failed to create directory '%s'" @@ -2629,7 +2891,7 @@ msgid "" "not exceeded, and then \"git reset HEAD\" to recover." msgstr "" "Das Projektarchiv wurde aktualisiert, aber die \"new_index\"-Datei\n" -"konnte nicht geschrieben werden. Prüfe, dass dein Speicher nicht\n" +"konnte nicht geschrieben werden. Prüfe, dass deine Festplatte nicht\n" "voll und Dein Kontingent nicht aufgebraucht ist und führe\n" "anschließend \"git reset HEAD\" zu Wiederherstellung aus." @@ -3638,10 +3900,6 @@ msgstr "\"git write-tree\" schlug beim Schreiben eines Baumes fehl" msgid "failed to read the cache" msgstr "Lesen des Zwischenspeichers fehlgeschlagen" -#: builtin/merge.c:697 -msgid "Unable to write index." -msgstr "Konnte Bereitstellung nicht schreiben." - #: builtin/merge.c:710 msgid "Not handling anything other than two heads merge." msgstr "Es wird nur die Zusammenführung von zwei Zweigen behandelt." @@ -5075,11 +5333,11 @@ msgstr "" #: git-am.sh:105 #, sh-format msgid "" -"When you have resolved this problem run \"$cmdline --resolved\".\n" -"If you would prefer to skip this patch, instead run \"$cmdline --skip\".\n" -"To restore the original branch and stop patching run \"$cmdline --abort\"." +"When you have resolved this problem, run \"$cmdline --resolved\".\n" +"If you prefer to skip this patch, run \"$cmdline --skip\" instead.\n" +"To restore the original branch and stop patching, run \"$cmdline --abort\"." msgstr "" -"Wenn du das Problem aufgelöst hast, führe \"$cmdline --resolved\" aus.\n" +"Wenn du das Problem gelöst hast, führe \"$cmdline --resolved\" aus.\n" "Falls du diesen Patch auslassen möchtest, führe stattdessen \"$cmdline --skip" "\" aus.\n" "Um den ursprünglichen Zweig wiederherzustellen und die Anwendung der " @@ -5096,6 +5354,12 @@ msgstr "" "Dem Projektarchiv fehlen notwendige Blobs um auf eine 3-Wege-Zusammenführung " "zurückzufallen." +#: git-am.sh:139 +msgid "Using index info to reconstruct a base tree..." +msgstr "" +"Verwende Informationen aus der Bereitstellung um einen Basisbaum " +"nachzustellen" + #: git-am.sh:154 msgid "" "Did you hand edit your patch?\n" @@ -5108,45 +5372,53 @@ msgstr "" msgid "Falling back to patching base and 3-way merge..." msgstr "Falle zurück zum Patchen der Basis und der 3-Wege-Zusammenführung..." -#: git-am.sh:275 +#: git-am.sh:179 +msgid "Failed to merge in the changes." +msgstr "Zusammenführung der Änderungen fehlgeschlagen" + +#: git-am.sh:274 msgid "Only one StGIT patch series can be applied at once" msgstr "Es kann nur eine StGIT Patch-Serie auf einmal angewendet werden." -#: git-am.sh:362 +#: git-am.sh:361 #, sh-format msgid "Patch format $patch_format is not supported." msgstr "Patch-Format $patch_format wird nicht unterstützt." -#: git-am.sh:364 +#: git-am.sh:363 msgid "Patch format detection failed." msgstr "Patch-Formaterkennung fehlgeschlagen." -#: git-am.sh:418 -msgid "-d option is no longer supported. Do not use." -msgstr "-d Option wird nicht länger unterstützt. Nicht benutzen." +#: git-am.sh:389 +msgid "" +"The -b/--binary option has been a no-op for long time, and\n" +"it will be removed. Please do not use it anymore." +msgstr "" +"Die -b/--binary Option hat seit Langem keinen Effekt und wird\n" +"entfernt. Bitte nicht mehr verwenden." -#: git-am.sh:481 +#: git-am.sh:477 #, sh-format msgid "previous rebase directory $dotest still exists but mbox given." msgstr "" "Vorheriges Verzeichnis des Neuaufbaus $dotest existiert noch, aber mbox " "gegeben." -#: git-am.sh:486 +#: git-am.sh:482 msgid "Please make up your mind. --skip or --abort?" msgstr "Bitte werde dir klar. --skip oder --abort?" -#: git-am.sh:513 +#: git-am.sh:509 msgid "Resolve operation not in progress, we are not resuming." msgstr "Es ist keine Auflösung im Gange, es wird nicht fortgesetzt." -#: git-am.sh:579 +#: git-am.sh:575 #, sh-format msgid "Dirty index: cannot apply patches (dirty: $files)" msgstr "" "Unsaubere Bereitstellung: kann Patches nicht anwenden (unsauber: $files)" -#: git-am.sh:683 +#: git-am.sh:679 #, sh-format msgid "" "Patch is empty. Was it split wrong?\n" @@ -5160,33 +5432,33 @@ msgstr "" "Patches\n" "abzubrechen, führe \"$cmdline --abort\" aus." -#: git-am.sh:710 +#: git-am.sh:706 msgid "Patch does not have a valid e-mail address." msgstr "Patch enthält keine gültige eMail-Adresse." -#: git-am.sh:757 +#: git-am.sh:753 msgid "cannot be interactive without stdin connected to a terminal." msgstr "" "Kann nicht interaktiv sein, ohne dass die Standard-Eingabe mit einem " "Terminal verbunden ist." -#: git-am.sh:761 +#: git-am.sh:757 msgid "Commit Body is:" msgstr "Beschreibung der Eintragung ist:" #. TRANSLATORS: Make sure to include [y], [n], [e], [v] and [a] #. in your translation. The program will only accept English #. input at this point. -#: git-am.sh:768 +#: git-am.sh:764 msgid "Apply? [y]es/[n]o/[e]dit/[v]iew patch/[a]ccept all " msgstr "Anwenden? [y]es/[n]o/[e]dit/[v]iew patch/[a]ccept all " -#: git-am.sh:804 +#: git-am.sh:800 #, sh-format msgid "Applying: $FIRSTLINE" msgstr "Wende an: $FIRSTLINE" -#: git-am.sh:825 +#: git-am.sh:821 msgid "" "No changes - did you forget to use 'git add'?\n" "If there is nothing left to stage, chances are that something else\n" @@ -5197,7 +5469,7 @@ msgstr "" "diese bereits anderweitig eingefügt worden sein; du könntest diesen Patch\n" "auslassen." -#: git-am.sh:833 +#: git-am.sh:829 msgid "" "You still have unmerged paths in your index\n" "did you forget to use 'git add'?" @@ -5205,16 +5477,16 @@ msgstr "" "Du hast immer noch nicht zusammengeführte Pfade in der Bereitstellung.\n" "Hast du vergessen 'git add' zu benutzen?" -#: git-am.sh:849 +#: git-am.sh:845 msgid "No changes -- Patch already applied." msgstr "Keine Änderungen -- Patches bereits angewendet." -#: git-am.sh:859 +#: git-am.sh:855 #, sh-format msgid "Patch failed at $msgnum $FIRSTLINE" msgstr "Anwendung des Patches fehlgeschlagen bei $msgnum $FIRSTLINE" -#: git-am.sh:880 +#: git-am.sh:876 msgid "applying to an empty history" msgstr "wende zu leerer Historie an" @@ -5419,6 +5691,131 @@ msgstr "Kann nicht mehrere Zweige in einen ungeborenen Zweig zusammenführen" msgid "Cannot rebase onto multiple branches" msgstr "kann nicht auf mehrere Zweige neu aufbauen" +#: git-rebase.sh:52 +msgid "" +"When you have resolved this problem, run \"git rebase --continue\".\n" +"If you prefer to skip this patch, run \"git rebase --skip\" instead.\n" +"To check out the original branch and stop rebasing, run \"git rebase --abort" +"\"." +msgstr "" +"Wenn du das Problem aufgelöst hast, führe \"git rebase --continue\" aus.\n" +"Falls du diesen Patch auslassen möchtest, führe stattdessen \"git rebase --" +"skip\" aus.\n" +"Um den ursprünglichen Zweig wiederherzustellen und den Neuaufbau " +"abzubrechen,\n" +"führe \"git rebase --abort\" aus." + +#: git-rebase.sh:159 +msgid "The pre-rebase hook refused to rebase." +msgstr "Der \"pre-rebase hook\" hat den Neuaufbau zurückgewiesen." + +#: git-rebase.sh:164 +msgid "It looks like git-am is in progress. Cannot rebase." +msgstr "\"git-am\" scheint im Gange zu sein. Kann nicht neu aufbauen." + +#: git-rebase.sh:295 +msgid "The --exec option must be used with the --interactive option" +msgstr "Die --exec Option muss mit der --interactive Option benutzt werden" + +#: git-rebase.sh:300 +msgid "No rebase in progress?" +msgstr "Kein Neuaufbau im Gange?" + +#: git-rebase.sh:313 +msgid "Cannot read HEAD" +msgstr "Kann Zweigspitze (HEAD) nicht lesen" + +#: git-rebase.sh:316 +msgid "" +"You must edit all merge conflicts and then\n" +"mark them as resolved using git add" +msgstr "" +"Du musst alle Zusammenführungskonflikte editieren und diese dann\n" +"mittels \"git add\" als aufgelöst markieren" + +#: git-rebase.sh:334 +#, sh-format +msgid "Could not move back to $head_name" +msgstr "Konnte nicht zu $head_name zurückgehen" + +#: git-rebase.sh:350 +#, sh-format +msgid "" +"It seems that there is already a $state_dir_base directory, and\n" +"I wonder if you are in the middle of another rebase. If that is the\n" +"case, please try\n" +"\t$cmd_live_rebase\n" +"If that is not the case, please\n" +"\t$cmd_clear_stale_rebase\n" +"and run me again. I am stopping in case you still have something\n" +"valuable there." +msgstr "" +"Es scheint so, als gäbe es das Verzeichnis $state_dir_base bereits, und\n" +"es wäre verwunderlich, wenn ein Neuaufbau bereits im Gange ist. Wenn das\n" +"der Fall ist, probiere bitte\n" +"\t$cmd_live_rebase\n" +"Wenn das nicht der Fall ist, probiere bitte\n" +"\t$cmd_clear_stale_rebase\n" +"und führe dieses Kommando nochmal aus. Es wird angehalten, falls bereits\n" +"etwas Nützliches vorhanden ist." + +#: git-rebase.sh:395 +#, sh-format +msgid "invalid upstream $upstream_name" +msgstr "ungültiger Übernahmezweig $upstream_name" + +#: git-rebase.sh:419 +#, sh-format +msgid "$onto_name: there are more than one merge bases" +msgstr "$onto_name: es gibt mehr als eine Zusammenführungsbasis" + +#: git-rebase.sh:422 git-rebase.sh:426 +#, sh-format +msgid "$onto_name: there is no merge base" +msgstr "$onto_name: es gibt keine Zusammenführungsbasis" + +#: git-rebase.sh:431 +#, sh-format +msgid "Does not point to a valid commit: $onto_name" +msgstr "$onto_name zeigt auf keine gültige Version" + +#: git-rebase.sh:454 +#, sh-format +msgid "fatal: no such branch: $branch_name" +msgstr "fatal: Zweig $branch_name nicht gefunden" + +#: git-rebase.sh:474 +msgid "Please commit or stash them." +msgstr "Bitte trage die Änderungen ein oder benutze \"stash\"." + +#: git-rebase.sh:492 +#, sh-format +msgid "Current branch $branch_name is up to date." +msgstr "Aktueller Zweig $branch_name ist auf dem neusten Stand." + +#: git-rebase.sh:495 +#, sh-format +msgid "Current branch $branch_name is up to date, rebase forced." +msgstr "" +"Aktueller Zweig $branch_name ist auf dem neusten Stand, Neuaufbau erzwungen." + +#: git-rebase.sh:506 +#, sh-format +msgid "Changes from $mb to $onto:" +msgstr "Änderungen von $mb zu $onto:" + +#. Detach HEAD and reset the tree +#: git-rebase.sh:515 +msgid "First, rewinding head to replay your work on top of it..." +msgstr "" +"Zunächst wird die Zweigspitze zurückgespult, um deine Änderungen\n" +"darauf neu anzuwenden..." + +#: git-rebase.sh:523 +#, sh-format +msgid "Fast-forwarded $branch_name to $onto_name." +msgstr "$branch_name zu $onto_name vorgespult." + #: git-stash.sh:51 msgid "git stash clear with parameters is unimplemented" msgstr "git stash clear mit Parametern ist nicht implementiert" @@ -5707,8 +6104,8 @@ msgid "Failed to recurse into submodule path '$sm_path'" msgstr "Fehler bei Rekursion in Unterprojekt-Pfad '$sm_path'" #: git-submodule.sh:754 -msgid "--cached cannot be used with --files" -msgstr "--cached kann nicht mit --files benutzt werden" +msgid "The --cached option cannot be used with the --files option" +msgstr "Die --cached Option kann nicht mit der --files Option benutzt werden" #. unexpected type #: git-submodule.sh:794 @@ -5736,10 +6133,6 @@ msgstr "" msgid "blob" msgstr "Blob" -#: git-submodule.sh:844 -msgid "submodule" -msgstr "Unterprojekt" - #: git-submodule.sh:881 msgid "# Submodules changed but not updated:" msgstr "# Unterprojekte geändert, aber nicht aktualisiert:" @@ -5753,6 +6146,9 @@ msgstr "# Änderungen in Unterprojekt zum Eintragen:" msgid "Synchronizing submodule url for '$name'" msgstr "Synchronisiere Unterprojekt-URL für '$name'" +#~ msgid "-d option is no longer supported. Do not use." +#~ msgstr "-d Option wird nicht länger unterstützt. Nicht benutzen." + #~ msgid "%s: has been deleted/renamed" #~ msgstr "%s wurde gelöscht/umbenannt" diff --git a/po/git.pot b/po/git.pot index 73eb449526..5c586d6007 100644 --- a/po/git.pot +++ b/po/git.pot @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: Git Mailing List \n" -"POT-Creation-Date: 2012-08-02 09:26+0800\n" +"POT-Creation-Date: 2012-08-06 23:47+0800\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -565,21 +565,23 @@ msgstr "" msgid "Merging:" msgstr "" -#: merge-recursive.c:1918 +#: merge-recursive.c:1920 #, c-format -msgid "found %u common ancestor(s):" -msgstr "" +msgid "found %u common ancestor:" +msgid_plural "found %u common ancestors:" +msgstr[0] "" +msgstr[1] "" -#: merge-recursive.c:1954 +#: merge-recursive.c:1957 msgid "merge returned no commit" msgstr "" -#: merge-recursive.c:2011 +#: merge-recursive.c:2014 #, c-format msgid "Could not parse object '%s'" msgstr "" -#: merge-recursive.c:2023 builtin/merge.c:697 +#: merge-recursive.c:2026 builtin/merge.c:697 msgid "Unable to write index." msgstr "" diff --git a/po/sv.po b/po/sv.po index 2635c2cf7b..b327a0e8bc 100644 --- a/po/sv.po +++ b/po/sv.po @@ -5,10 +5,10 @@ # msgid "" msgstr "" -"Project-Id-Version: git 1.7.10\n" +"Project-Id-Version: git 1.7.12\n" "Report-Msgid-Bugs-To: Git Mailing List \n" -"POT-Creation-Date: 2012-07-03 10:23+0800\n" -"PO-Revision-Date: 2012-07-04 19:33+0100\n" +"POT-Creation-Date: 2012-08-06 23:47+0800\n" +"PO-Revision-Date: 2012-08-14 09:58+0100\n" "Last-Translator: Peter Krefting \n" "Language-Team: Swedish \n" "Language: sv\n" @@ -48,7 +48,7 @@ msgstr "'%s' ser inte ut som en v2-bundle-fil" msgid "unrecognized header: %s%s (%d)" msgstr "okänt huvud: %s%s (%d)" -#: bundle.c:89 builtin/commit.c:696 +#: bundle.c:89 builtin/commit.c:699 #, c-format msgid "could not open '%s'" msgstr "kunde inte öppna \"%s\"" @@ -58,7 +58,7 @@ msgid "Repository lacks these prerequisite commits:" msgstr "Arkivet saknar dessa nödvändiga incheckningar:" #: bundle.c:164 sequencer.c:550 sequencer.c:982 builtin/log.c:290 -#: builtin/log.c:721 builtin/log.c:1310 builtin/log.c:1529 builtin/merge.c:347 +#: builtin/log.c:726 builtin/log.c:1316 builtin/log.c:1535 builtin/merge.c:347 #: builtin/shortlog.c:181 msgid "revision walk setup failed" msgstr "misslyckades skapa revisionstraversering" @@ -85,7 +85,7 @@ msgstr[1] "Paketet (bundlen) kräver dessa %d referenser" msgid "rev-list died" msgstr "rev-list dog" -#: bundle.c:300 builtin/log.c:1206 builtin/shortlog.c:284 +#: bundle.c:300 builtin/log.c:1212 builtin/shortlog.c:284 #, c-format msgid "unrecognized argument: %s" msgstr "okänt argument: %s" @@ -231,8 +231,8 @@ msgstr "" "%s" #: diff.c:1400 -msgid " 0 files changed\n" -msgstr " 0 filer ändrade\n" +msgid " 0 files changed" +msgstr " 0 filer ändrade" #: diff.c:1404 #, c-format @@ -255,7 +255,7 @@ msgid_plural ", %d deletions(-)" msgstr[0] ", %d borttagning(-)" msgstr[1] ", %d borttagningar(-)" -#: diff.c:3478 +#: diff.c:3461 #, c-format msgid "" "Failed to parse --dirstat/-X option parameter:\n" @@ -291,16 +291,16 @@ msgstr "\"%s\": %s" msgid "'%s': short read %s" msgstr "\"%s\": kort läsning %s" -#: help.c:208 +#: help.c:212 #, c-format msgid "available git commands in '%s'" msgstr "git-kommandon tillgängliga i \"%s\"" -#: help.c:215 +#: help.c:219 msgid "git commands available from elsewhere on your $PATH" msgstr "git-kommandon från andra platser i din $PATH" -#: help.c:271 +#: help.c:275 #, c-format msgid "" "'%s' appears to be a git command, but we were not\n" @@ -309,11 +309,11 @@ msgstr "" "\"%s\" verkar vara ett git-kommando, men vi kan inte\n" "köra det. Kanske git-%s är trasigt?" -#: help.c:328 +#: help.c:332 msgid "Uh oh. Your system reports no Git commands at all." msgstr "Oj då. Ditt system rapporterar inga Git-kommandon alls." -#: help.c:350 +#: help.c:354 #, c-format msgid "" "WARNING: You called a Git command named '%s', which does not exist.\n" @@ -322,17 +322,17 @@ msgstr "" "VARNING: Du anropade ett Git-kommando vid namn \"%s\", som inte finns.\n" "Fortsätter under förutsättningen att du menade \"%s\"" -#: help.c:355 +#: help.c:359 #, c-format msgid "in %0.1f seconds automatically..." msgstr "automatiskt om %0.1f sekunder..." -#: help.c:362 +#: help.c:366 #, c-format msgid "git: '%s' is not a git command. See 'git --help'." msgstr "git: \"%s\" är inte ett git-kommando. Se \"git --help\"." -#: help.c:366 +#: help.c:370 msgid "" "\n" "Did you mean this?" @@ -346,35 +346,297 @@ msgstr[1] "" "\n" "Menade du ett av dessa?" -#: parse-options.c:493 +#: merge-recursive.c:190 +#, c-format +msgid "(bad commit)\n" +msgstr "(felaktig incheckning)\n" + +#: merge-recursive.c:206 +#, c-format +msgid "addinfo_cache failed for path '%s'" +msgstr "addinfo_cache misslyckades för sökvägen \"%s\"" + +#: merge-recursive.c:268 +msgid "error building trees" +msgstr "fel vid byggande av träd" + +#: merge-recursive.c:497 +msgid "diff setup failed" +msgstr "misslyckades sätta upp för diff" + +#: merge-recursive.c:627 +msgid "merge-recursive: disk full?" +msgstr "merge-recursive: disk full?" + +#: merge-recursive.c:690 +#, c-format +msgid "failed to create path '%s'%s" +msgstr "misslyckades skapa sökvägen \"%s\"%s" + +#: merge-recursive.c:701 +#, c-format +msgid "Removing %s to make room for subdirectory\n" +msgstr "Tar bort %s för att göra plats för underkatalog\n" + +#. something else exists +#. .. but not some other error (who really cares what?) +#: merge-recursive.c:715 merge-recursive.c:736 +msgid ": perhaps a D/F conflict?" +msgstr ": kanske en K/F-konflikt?" + +#: merge-recursive.c:726 +#, c-format +msgid "refusing to lose untracked file at '%s'" +msgstr "vägrar förlora ospårad fil vid \"%s\"" + +#: merge-recursive.c:766 +#, c-format +msgid "cannot read object %s '%s'" +msgstr "kan inte läsa objektet %s: \"%s\"" + +#: merge-recursive.c:768 +#, c-format +msgid "blob expected for %s '%s'" +msgstr "blob förväntades för %s \"%s\"" + +#: merge-recursive.c:791 builtin/clone.c:302 +#, c-format +msgid "failed to open '%s'" +msgstr "misslyckades öppna \"%s\"" + +#: merge-recursive.c:799 +#, c-format +msgid "failed to symlink '%s'" +msgstr "misslyckades ta skapa symboliska länken \"%s\"" + +#: merge-recursive.c:802 +#, c-format +msgid "do not know what to do with %06o %s '%s'" +msgstr "vet inte hur %06o %s \"%s\" skall hanteras" + +#: merge-recursive.c:939 +msgid "Failed to execute internal merge" +msgstr "Misslyckades exekvera intern sammanslagning" + +#: merge-recursive.c:943 +#, c-format +msgid "Unable to add %s to database" +msgstr "Kunde inte lägga till %s till databasen" + +#: merge-recursive.c:959 +msgid "unsupported object type in the tree" +msgstr "objekttyp som ej stöds upptäcktes i trädet" + +#: merge-recursive.c:1038 merge-recursive.c:1052 +#, c-format +msgid "" +"CONFLICT (%s/delete): %s deleted in %s and %s in %s. Version %s of %s left " +"in tree." +msgstr "" +"KONFLIKT (%s/radera): %s raderad i %s och %s i %s. Versionen %s av %s lämnad " +"i trädet." + +#: merge-recursive.c:1044 merge-recursive.c:1057 +#, c-format +msgid "" +"CONFLICT (%s/delete): %s deleted in %s and %s in %s. Version %s of %s left " +"in tree at %s." +msgstr "" +"KONFLIKT (%s/radera): %s raderad i %s och %s i %s. Versionen %s av %s lämnad " +"i trädet vid %s." + +#: merge-recursive.c:1098 +msgid "rename" +msgstr "namnbyte" + +#: merge-recursive.c:1098 +msgid "renamed" +msgstr "namnbytt" + +#: merge-recursive.c:1154 +#, c-format +msgid "%s is a directory in %s adding as %s instead" +msgstr "%s är en katalog i %s lägger till som %s istället" + +#: merge-recursive.c:1176 +#, c-format +msgid "" +"CONFLICT (rename/rename): Rename \"%s\"->\"%s\" in branch \"%s\" rename \"%s" +"\"->\"%s\" in \"%s\"%s" +msgstr "" +"KONFLIKT (namnbyte/namnbyte): Namnbyte \"%s\"->\"%s\" på grenen \"%s\" " +"namnbyte \"%s\"->\"%s\" i \"%s\"%s" + +#: merge-recursive.c:1181 +msgid " (left unresolved)" +msgstr " (lämnad olöst)" + +#: merge-recursive.c:1235 +#, c-format +msgid "CONFLICT (rename/rename): Rename %s->%s in %s. Rename %s->%s in %s" +msgstr "" +"KONFLIKT (namnbyte/namnbyte): Namnbyte %s->%s i %s. Namnbyte %s->%s i %s" + +#: merge-recursive.c:1265 +#, c-format +msgid "Renaming %s to %s and %s to %s instead" +msgstr "Byter namn på %s till %s och %s till %s istället" + +#: merge-recursive.c:1464 +#, c-format +msgid "CONFLICT (rename/add): Rename %s->%s in %s. %s added in %s" +msgstr "KONFLIKT (namnbyte/tillägg): Namnbyte %s->%s i %s. %s tillagd i %s" + +#: merge-recursive.c:1474 +#, c-format +msgid "Adding merged %s" +msgstr "Lägger till sammanslagen %s" + +#: merge-recursive.c:1479 merge-recursive.c:1677 +#, c-format +msgid "Adding as %s instead" +msgstr "Lägger till som %s iställer" + +#: merge-recursive.c:1530 +#, c-format +msgid "cannot read object %s" +msgstr "kan inte läsa objektet %s" + +#: merge-recursive.c:1533 +#, c-format +msgid "object %s is not a blob" +msgstr "objektet %s är inte en blob" + +#: merge-recursive.c:1581 +msgid "modify" +msgstr "ändra" + +#: merge-recursive.c:1581 +msgid "modified" +msgstr "ändrad" + +#: merge-recursive.c:1591 +msgid "content" +msgstr "innehåll" + +#: merge-recursive.c:1598 +msgid "add/add" +msgstr "tillägg/tillägg" + +#: merge-recursive.c:1632 +#, c-format +msgid "Skipped %s (merged same as existing)" +msgstr "Hoppade över %s (sammanslagen samma som befintlig)" + +#: merge-recursive.c:1646 +#, c-format +msgid "Auto-merging %s" +msgstr "Slår ihop %s automatiskt" + +#: merge-recursive.c:1650 git-submodule.sh:844 +msgid "submodule" +msgstr "undermodul" + +#: merge-recursive.c:1651 +#, c-format +msgid "CONFLICT (%s): Merge conflict in %s" +msgstr "KONFLIKT (%s): Sammanslagningskonflikt i %s" + +#: merge-recursive.c:1741 +#, c-format +msgid "Removing %s" +msgstr "Tar bort %s" + +#: merge-recursive.c:1766 +msgid "file/directory" +msgstr "fil/katalog" + +#: merge-recursive.c:1772 +msgid "directory/file" +msgstr "katalog/fil" + +#: merge-recursive.c:1777 +#, c-format +msgid "CONFLICT (%s): There is a directory with name %s in %s. Adding %s as %s" +msgstr "" +"KONFLIKT (%s): Det finns en katalog med namnet %s i %s. Lägger till %s som %s" + +#: merge-recursive.c:1787 +#, c-format +msgid "Adding %s" +msgstr "Lägger till %s" + +#: merge-recursive.c:1804 +msgid "Fatal merge failure, shouldn't happen." +msgstr "Ödesdigert sammanslagningsfel, borde inte inträffa." + +#: merge-recursive.c:1823 +msgid "Already up-to-date!" +msgstr "Redan à jour!" + +#: merge-recursive.c:1832 +#, c-format +msgid "merging of trees %s and %s failed" +msgstr "sammanslagning av träden %s och %s misslyckades" + +#: merge-recursive.c:1862 +#, c-format +msgid "Unprocessed path??? %s" +msgstr "Obehandlad sökväg??? %s" + +#: merge-recursive.c:1907 +msgid "Merging:" +msgstr "Slår ihop:" + +#: merge-recursive.c:1920 +#, c-format +msgid "found %u common ancestor:" +msgid_plural "found %u common ancestors:" +msgstr[0] "hittade %u gemensam förfader:" +msgstr[1] "hittade %u gemensamma förfäder:" + +#: merge-recursive.c:1957 +msgid "merge returned no commit" +msgstr "sammanslagningen returnerade ingen incheckning" + +#: merge-recursive.c:2014 +#, c-format +msgid "Could not parse object '%s'" +msgstr "Kunde inte tolka objektet \"%s\"" + +#: merge-recursive.c:2026 builtin/merge.c:697 +msgid "Unable to write index." +msgstr "Kunde inte skriva indexet." + +#: parse-options.c:494 msgid "..." msgstr "..." -#: parse-options.c:511 +#: parse-options.c:512 #, c-format msgid "usage: %s" msgstr "användning: %s" #. TRANSLATORS: the colon here should align with the #. one in "usage: %s" translation -#: parse-options.c:515 +#: parse-options.c:516 #, c-format msgid " or: %s" msgstr " eller: %s" -#: parse-options.c:518 +#: parse-options.c:519 #, c-format msgid " %s" msgstr " %s" -#: remote.c:1629 +#: remote.c:1632 #, 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] "Din gren ligger före \"%s\" med %d incheckning.\n" msgstr[1] "Din gren ligger före \"%s\" med %d incheckningar.\n" -#: remote.c:1635 +#: remote.c:1638 #, c-format msgid "Your branch is behind '%s' by %d commit, and can be fast-forwarded.\n" msgid_plural "" @@ -384,7 +646,7 @@ msgstr[0] "" msgstr[1] "" "Din gren ligger efter \"%s\" med %d incheckningar, och kan snabbspolas.\n" -#: remote.c:1643 +#: remote.c:1646 #, c-format msgid "" "Your branch and '%s' have diverged,\n" @@ -608,7 +870,7 @@ msgstr "kan inte bestämma HEAD" msgid "cannot abort from a branch yet to be born" msgstr "kan inte avbryta från en gren som ännu inte är född" -#: sequencer.c:805 builtin/apply.c:3697 +#: sequencer.c:805 builtin/apply.c:3988 #, c-format msgid "cannot open %s: %s" msgstr "kan inte öppna %s: %s" @@ -640,21 +902,21 @@ msgstr "Kan inte ångra som första incheckning" msgid "Can't cherry-pick into empty head" msgstr "Kan inte göra \"cherry-pick\" i ett tomt huvud" -#: sha1_name.c:864 +#: sha1_name.c:1044 msgid "HEAD does not point to a branch" msgstr "HEAD pekar inte på en gren" -#: sha1_name.c:867 +#: sha1_name.c:1047 #, c-format msgid "No such branch: '%s'" msgstr "Okänd gren: \"%s\"" -#: sha1_name.c:869 +#: sha1_name.c:1049 #, c-format msgid "No upstream configured for branch '%s'" msgstr "Ingen standarduppström angiven för grenen \"%s\"" -#: sha1_name.c:872 +#: sha1_name.c:1052 #, c-format msgid "Upstream branch '%s' not stored as a remote-tracking branch" msgstr "Uppströmsgrenen \"%s\" är inte lagrad som en fjärrspårande gren" @@ -668,343 +930,343 @@ msgstr "kan inte slå upp aktuell användare i passwd-filen: %s" msgid "no such user" msgstr "okänd användare" -#: wt-status.c:141 +#: wt-status.c:140 msgid "Unmerged paths:" msgstr "Ej sammanslagna sökvägar:" -#: wt-status.c:168 wt-status.c:195 +#: wt-status.c:167 wt-status.c:194 #, c-format msgid " (use \"git reset %s ...\" to unstage)" msgstr " (använd \"git reset %s ...\" för att ta bort från kö)" -#: wt-status.c:170 wt-status.c:197 +#: wt-status.c:169 wt-status.c:196 msgid " (use \"git rm --cached ...\" to unstage)" msgstr " (använd \"git rm --cached ...\" för att ta bort från kö)" -#: wt-status.c:174 +#: wt-status.c:173 msgid " (use \"git add ...\" to mark resolution)" msgstr " (använd \"git add ...\" för att ange lösning)" -#: wt-status.c:176 wt-status.c:180 +#: wt-status.c:175 wt-status.c:179 msgid " (use \"git add/rm ...\" as appropriate to mark resolution)" msgstr " (använd \"git add/rm ...\" som lämpligt för att ange lösning)" -#: wt-status.c:178 +#: wt-status.c:177 msgid " (use \"git rm ...\" to mark resolution)" msgstr " (använd \"git rm ...\" för att ange lösning)" -#: wt-status.c:189 +#: wt-status.c:188 msgid "Changes to be committed:" msgstr "Ändringar att checka in:" -#: wt-status.c:207 +#: wt-status.c:206 msgid "Changes not staged for commit:" msgstr "Ändringar ej i incheckningskön:" -#: wt-status.c:211 +#: wt-status.c:210 msgid " (use \"git add ...\" to update what will be committed)" msgstr "" " (använd \"git add ...\" för att uppdatera vad som skall checkas in)" -#: wt-status.c:213 +#: wt-status.c:212 msgid " (use \"git add/rm ...\" to update what will be committed)" msgstr "" " (använd \"git add/rm ...\" för att uppdatera vad som skall checkas in)" -#: wt-status.c:214 +#: wt-status.c:213 msgid "" " (use \"git checkout -- ...\" to discard changes in working directory)" msgstr "" " (använd \"git checkout -- ...\" för att förkasta ändringar i " "arbetskatalogen)" -#: wt-status.c:216 +#: wt-status.c:215 msgid " (commit or discard the untracked or modified content in submodules)" msgstr "" " (checka in eller förkasta ospårat eller ändrat innehåll i undermoduler)" # %s är ett verb ("Untracked"/"Ignored"); lägg till ett -e. -#: wt-status.c:225 +#: wt-status.c:224 #, c-format msgid "%s files:" msgstr "%se filer:" -#: wt-status.c:228 +#: wt-status.c:227 #, c-format msgid " (use \"git %s ...\" to include in what will be committed)" msgstr "" -" (använd \"git %s ...\" för att ta med i vad som skall checkas in)" +" (använd \"git %s ...\" för att ta med i det som skall checkas in)" -#: wt-status.c:245 +#: wt-status.c:244 msgid "bug" msgstr "programfel" -#: wt-status.c:250 +#: wt-status.c:249 msgid "both deleted:" msgstr "borttaget av bägge:" -#: wt-status.c:251 +#: wt-status.c:250 msgid "added by us:" msgstr "tillagt av oss:" -#: wt-status.c:252 +#: wt-status.c:251 msgid "deleted by them:" msgstr "borttaget av dem:" -#: wt-status.c:253 +#: wt-status.c:252 msgid "added by them:" msgstr "tillagt av dem:" -#: wt-status.c:254 +#: wt-status.c:253 msgid "deleted by us:" msgstr "borttaget av oss:" -#: wt-status.c:255 +#: wt-status.c:254 msgid "both added:" msgstr "tillagt av bägge:" -#: wt-status.c:256 +#: wt-status.c:255 msgid "both modified:" msgstr "ändrat av bägge:" -#: wt-status.c:286 +#: wt-status.c:285 msgid "new commits, " msgstr "nya incheckningar, " -#: wt-status.c:288 +#: wt-status.c:287 msgid "modified content, " msgstr "ändrat innehåll, " -#: wt-status.c:290 +#: wt-status.c:289 msgid "untracked content, " msgstr "ospårat innehåll, " -#: wt-status.c:304 +#: wt-status.c:303 #, c-format msgid "new file: %s" msgstr "ny fil: %s" -#: wt-status.c:307 +#: wt-status.c:306 #, c-format msgid "copied: %s -> %s" msgstr "kopierad: %s -> %s" -#: wt-status.c:310 +#: wt-status.c:309 #, c-format msgid "deleted: %s" msgstr "borttagen: %s" -#: wt-status.c:313 +#: wt-status.c:312 #, c-format msgid "modified: %s" msgstr "ändrad: %s" -#: wt-status.c:316 +#: wt-status.c:315 #, c-format msgid "renamed: %s -> %s" msgstr "namnbyte: %s -> %s" -#: wt-status.c:319 +#: wt-status.c:318 #, c-format msgid "typechange: %s" msgstr "typbyte: %s" -#: wt-status.c:322 +#: wt-status.c:321 #, c-format msgid "unknown: %s" msgstr "okänd: %s" -#: wt-status.c:325 +#: wt-status.c:324 #, c-format msgid "unmerged: %s" msgstr "osammansl.: %s" -#: wt-status.c:328 +#: wt-status.c:327 #, c-format msgid "bug: unhandled diff status %c" msgstr "programfel: diff-status %c ej hanterad" -#: wt-status.c:786 +#: wt-status.c:785 msgid "You have unmerged paths." msgstr "Du har ej sammanslagna sökvägar." -#: wt-status.c:789 wt-status.c:913 +#: wt-status.c:788 wt-status.c:912 msgid " (fix conflicts and run \"git commit\")" msgstr " (rätta konflikter och kör \"git commit\")" -#: wt-status.c:792 +#: wt-status.c:791 msgid "All conflicts fixed but you are still merging." msgstr "Alla konflikter har rättats men du är fortfarande i en sammanslagning." -#: wt-status.c:795 +#: wt-status.c:794 msgid " (use \"git commit\" to conclude merge)" msgstr " (använd \"git commit\" för att slutföra sammanslagningen)" -#: wt-status.c:805 +#: wt-status.c:804 msgid "You are in the middle of an am session." msgstr "Du är i mitten av en körning av \"git am\"." -#: wt-status.c:808 +#: wt-status.c:807 msgid "The current patch is empty." msgstr "Aktuell patch är tom." -#: wt-status.c:812 +#: wt-status.c:811 msgid " (fix conflicts and then run \"git am --resolved\")" msgstr " (rätta konflikter och kör sedan \"git am --resolved\")" -#: wt-status.c:814 +#: wt-status.c:813 msgid " (use \"git am --skip\" to skip this patch)" msgstr " (använd \"git am --skip\" för att hoppa över patchen)" -#: wt-status.c:816 +#: wt-status.c:815 msgid " (use \"git am --abort\" to restore the original branch)" msgstr " (använd \"git am --abort\" för att återställa ursprungsgrenen)" -#: wt-status.c:874 wt-status.c:884 +#: wt-status.c:873 wt-status.c:883 msgid "You are currently rebasing." msgstr "Du håller på med en ombasering." -#: wt-status.c:877 +#: wt-status.c:876 msgid " (fix conflicts and then run \"git rebase --continue\")" msgstr " (rätta konflikter och kör sedan \"git rebase --continue\")" -#: wt-status.c:879 +#: wt-status.c:878 msgid " (use \"git rebase --skip\" to skip this patch)" msgstr " (använd \"git rebase --skip\" för att hoppa över patchen)" -#: wt-status.c:881 +#: wt-status.c:880 msgid " (use \"git rebase --abort\" to check out the original branch)" msgstr " (använd \"git rebase --abort\" för att checka ut ursprungsgrenen)" -#: wt-status.c:887 +#: wt-status.c:886 msgid " (all conflicts fixed: run \"git rebase --continue\")" msgstr " (alla konflikter rättade: kör \"git rebase --continue\")" -#: wt-status.c:889 +#: wt-status.c:888 msgid "You are currently splitting a commit during a rebase." msgstr "Du håller på att dela upp en incheckning i en ombasering." -#: wt-status.c:892 +#: wt-status.c:891 msgid " (Once your working directory is clean, run \"git rebase --continue\")" msgstr " (Så fort din arbetskatalog är ren, kör \"git rebase --continue\")" -#: wt-status.c:894 +#: wt-status.c:893 msgid "You are currently editing a commit during a rebase." msgstr "Du håller på att redigera en incheckning under en ombasering." -#: wt-status.c:897 +#: wt-status.c:896 msgid " (use \"git commit --amend\" to amend the current commit)" msgstr "" " (använd \"git commit --amend\" för att lägga till på aktuell incheckning)" -#: wt-status.c:899 +#: wt-status.c:898 msgid "" " (use \"git rebase --continue\" once you are satisfied with your changes)" msgstr " (använd \"git rebase --continue\" när du är nöjd med dina ändringar)" -#: wt-status.c:909 +#: wt-status.c:908 msgid "You are currently cherry-picking." msgstr "Du håller på med en \"cherry-pick\"." -#: wt-status.c:916 +#: wt-status.c:915 msgid " (all conflicts fixed: run \"git commit\")" msgstr " (alla konflikter har rättats: kör \"git commit\")" -#: wt-status.c:925 +#: wt-status.c:924 msgid "You are currently bisecting." msgstr "Du håller på med en \"bisect\"." -#: wt-status.c:928 +#: wt-status.c:927 msgid " (use \"git bisect reset\" to get back to the original branch)" msgstr "" " (använd \"git bisect reset\" för att komma tillbaka till ursprungsgrenen)" -#: wt-status.c:979 +#: wt-status.c:978 msgid "On branch " msgstr "På grenen " -#: wt-status.c:986 +#: wt-status.c:985 msgid "Not currently on any branch." msgstr "Inte på någon gren för närvarande." -#: wt-status.c:998 +#: wt-status.c:997 msgid "Initial commit" msgstr "Första incheckning" -#: wt-status.c:1012 +#: wt-status.c:1011 msgid "Untracked" msgstr "Ospårad" -#: wt-status.c:1014 +#: wt-status.c:1013 msgid "Ignored" msgstr "Ignorerad" # %s är nästa sträng eller tom. -#: wt-status.c:1016 +#: wt-status.c:1015 #, c-format msgid "Untracked files not listed%s" msgstr "Ospårade filer visas ej%s" -#: wt-status.c:1018 +#: wt-status.c:1017 msgid " (use -u option to show untracked files)" msgstr " (använd flaggan -u för att visa ospårade filer)" -#: wt-status.c:1024 +#: wt-status.c:1023 msgid "No changes" msgstr "Inga ändringar" -#: wt-status.c:1028 +#: wt-status.c:1027 #, c-format msgid "no changes added to commit%s\n" msgstr "inga ändringar att checka in%s\n" -#: wt-status.c:1030 +#: wt-status.c:1029 msgid " (use \"git add\" and/or \"git commit -a\")" msgstr " (använd \"git add\" och/eller \"git commit -a\")" -#: wt-status.c:1032 +#: wt-status.c:1031 #, c-format msgid "nothing added to commit but untracked files present%s\n" msgstr "inget köat för incheckning, men ospårade filer finns%s\n" -#: wt-status.c:1034 +#: wt-status.c:1033 msgid " (use \"git add\" to track)" -msgstr " (använd \"git add\" för att spåra)" +msgstr " (spåra med \"git add\")" -#: wt-status.c:1036 wt-status.c:1039 wt-status.c:1042 +#: wt-status.c:1035 wt-status.c:1038 wt-status.c:1041 #, c-format msgid "nothing to commit%s\n" msgstr "inget att checka in%s\n" -#: wt-status.c:1037 +#: wt-status.c:1036 msgid " (create/copy files and use \"git add\" to track)" -msgstr " (skapa/kopiera filer och använd \"git add\" för att spåra)" +msgstr " (skapa/kopiera filer och spåra med \"git add\")" -#: wt-status.c:1040 +#: wt-status.c:1039 msgid " (use -u to show untracked files)" msgstr " (använd -u för att visa ospårade filer)" -#: wt-status.c:1043 +#: wt-status.c:1042 msgid " (working directory clean)" msgstr " (arbetskatalogen ren)" -#: wt-status.c:1151 +#: wt-status.c:1150 msgid "HEAD (no branch)" msgstr "HEAD (ingen gren)" -#: wt-status.c:1157 +#: wt-status.c:1156 msgid "Initial commit on " msgstr "Första incheckning på " -#: wt-status.c:1172 +#: wt-status.c:1171 msgid "behind " msgstr "efter " -#: wt-status.c:1175 wt-status.c:1178 +#: wt-status.c:1174 wt-status.c:1177 msgid "ahead " msgstr "före " -#: wt-status.c:1180 +#: wt-status.c:1179 msgid ", behind " msgstr ", efter " @@ -1013,7 +1275,7 @@ msgstr ", efter " msgid "unexpected diff status %c" msgstr "diff-status %c förväntades inte" -#: builtin/add.c:67 builtin/commit.c:226 +#: builtin/add.c:67 builtin/commit.c:229 msgid "updating files failed" msgstr "misslyckades uppdatera filer" @@ -1103,75 +1365,75 @@ msgstr "Inget angivet, inget tillagt.\n" msgid "Maybe you wanted to say 'git add .'?\n" msgstr "Kanske menade du att skriva \"git add .\"?\n" -#: builtin/add.c:420 builtin/clean.c:95 builtin/commit.c:286 builtin/mv.c:82 +#: builtin/add.c:420 builtin/clean.c:95 builtin/commit.c:289 builtin/mv.c:82 #: builtin/rm.c:162 msgid "index file corrupt" msgstr "indexfilen trasig" -#: builtin/add.c:480 builtin/apply.c:4108 builtin/mv.c:229 builtin/rm.c:260 +#: builtin/add.c:480 builtin/apply.c:4433 builtin/mv.c:229 builtin/rm.c:260 msgid "Unable to write new index file" msgstr "Kunde inte skriva ny indexfil" -#: builtin/apply.c:53 +#: builtin/apply.c:57 msgid "git apply [options] [...]" msgstr "git apply [flaggor] [...]" -#: builtin/apply.c:106 +#: builtin/apply.c:110 #, c-format msgid "unrecognized whitespace option '%s'" msgstr "okänt alternativ för whitespace: \"%s\"" -#: builtin/apply.c:121 +#: builtin/apply.c:125 #, c-format msgid "unrecognized whitespace ignore option '%s'" msgstr "okänt alternativ för ignore-whitespace: \"%s\"" -#: builtin/apply.c:815 +#: builtin/apply.c:824 #, c-format msgid "Cannot prepare timestamp regexp %s" msgstr "Kan inte förbereda reguljärt uttryck för tidsstämpeln %s" -#: builtin/apply.c:824 +#: builtin/apply.c:833 #, c-format msgid "regexec returned %d for input: %s" msgstr "regexec returnerade %d för indata: %s" -#: builtin/apply.c:905 +#: builtin/apply.c:914 #, c-format msgid "unable to find filename in patch at line %d" msgstr "kan inte hitta filnamn i patchen på rad %d" -#: builtin/apply.c:937 +#: builtin/apply.c:946 #, c-format msgid "git apply: bad git-diff - expected /dev/null, got %s on line %d" msgstr "git apply: dålig git-diff - förväntade /dev/null, fick %s på rad %d" -#: builtin/apply.c:941 +#: builtin/apply.c:950 #, c-format msgid "git apply: bad git-diff - inconsistent new filename on line %d" msgstr "git apply: dålig git-diff - motsägande nytt filnamn på rad %d" -#: builtin/apply.c:942 +#: builtin/apply.c:951 #, c-format msgid "git apply: bad git-diff - inconsistent old filename on line %d" msgstr "git apply: dålig git-diff - motsägande gammalt filnamn på rad %d" -#: builtin/apply.c:949 +#: builtin/apply.c:958 #, c-format msgid "git apply: bad git-diff - expected /dev/null on line %d" msgstr "git apply: dålig git-diff - förväntade /dev/null på rad %d" -#: builtin/apply.c:1394 +#: builtin/apply.c:1403 #, c-format msgid "recount: unexpected line: %.*s" msgstr "recount: förväntade rad: %.*s" -#: builtin/apply.c:1451 +#: builtin/apply.c:1460 #, c-format msgid "patch fragment without header at line %d: %.*s" msgstr "patch-fragment utan huvud på rad %d: %.*s" -#: builtin/apply.c:1468 +#: builtin/apply.c:1477 #, c-format msgid "" "git diff header lacks filename information when removing %d leading pathname " @@ -1187,82 +1449,82 @@ msgstr[1] "" "sökvägskomponenter\n" "tas bort (rad %d)" -#: builtin/apply.c:1628 +#: builtin/apply.c:1637 msgid "new file depends on old contents" msgstr "ny fil beror på gammalt innehåll" -#: builtin/apply.c:1630 +#: builtin/apply.c:1639 msgid "deleted file still has contents" msgstr "borttagen fil har fortfarande innehåll" -#: builtin/apply.c:1656 +#: builtin/apply.c:1665 #, c-format msgid "corrupt patch at line %d" msgstr "trasig patch på rad %d" -#: builtin/apply.c:1692 +#: builtin/apply.c:1701 #, c-format msgid "new file %s depends on old contents" msgstr "nya filen %s beror på gammalt innehåll" -#: builtin/apply.c:1694 +#: builtin/apply.c:1703 #, c-format msgid "deleted file %s still has contents" msgstr "borttagna filen %s har fortfarande innehåll" -#: builtin/apply.c:1697 +#: builtin/apply.c:1706 #, c-format msgid "** warning: file %s becomes empty but is not deleted" msgstr "** varning: filen %s blir tom men har inte tagits bort" -#: builtin/apply.c:1843 +#: builtin/apply.c:1852 #, c-format msgid "corrupt binary patch at line %d: %.*s" msgstr "trasig binärpatch på rad %d: %.*s" #. there has to be one hunk (forward hunk) -#: builtin/apply.c:1872 +#: builtin/apply.c:1881 #, c-format msgid "unrecognized binary patch at line %d" msgstr "binärpatchen på rad %d känns inte igen" -#: builtin/apply.c:1958 +#: builtin/apply.c:1967 #, c-format msgid "patch with only garbage at line %d" msgstr "patch med bara skräp på rad %d" -#: builtin/apply.c:2048 +#: builtin/apply.c:2057 #, c-format msgid "unable to read symlink %s" msgstr "kunde inte läsa symboliska länken %s" -#: builtin/apply.c:2052 +#: builtin/apply.c:2061 #, c-format msgid "unable to open or read %s" msgstr "kunde inte öppna eller läsa %s" -#: builtin/apply.c:2123 +#: builtin/apply.c:2132 msgid "oops" msgstr "hoppsan" -#: builtin/apply.c:2645 +#: builtin/apply.c:2654 #, c-format msgid "invalid start of line: '%c'" msgstr "felaktig inledning på rad: \"%c\"" -#: builtin/apply.c:2763 +#: builtin/apply.c:2772 #, c-format msgid "Hunk #%d succeeded at %d (offset %d line)." msgid_plural "Hunk #%d succeeded at %d (offset %d lines)." msgstr[0] "Stycke %d lyckades på %d (offset %d rad)." msgstr[1] "Stycke %d lyckades på %d (offset %d rader)." -#: builtin/apply.c:2775 +#: builtin/apply.c:2784 #, c-format msgid "Context reduced to (%ld/%ld) to apply fragment at %d" msgstr "Sammanhang reducerat till (%ld/%ld) för att tillämpa fragment vid %d" -#: builtin/apply.c:2781 +#: builtin/apply.c:2790 #, c-format msgid "" "while searching for:\n" @@ -1271,313 +1533,321 @@ msgstr "" "vid sökning efter:\n" "%.*s" -#: builtin/apply.c:2800 +#: builtin/apply.c:2809 #, c-format msgid "missing binary patch data for '%s'" msgstr "saknar binära patchdata för \"%s\"" -#: builtin/apply.c:2903 +#: builtin/apply.c:2912 #, c-format msgid "binary patch does not apply to '%s'" msgstr "binärpatchen kan inte tillämpas på \"%s\"" -#: builtin/apply.c:2909 +#: builtin/apply.c:2918 #, c-format msgid "binary patch to '%s' creates incorrect result (expecting %s, got %s)" msgstr "binärpatchen på \"%s\" ger felaktigt resultat (förväntade %s, fick %s)" -#: builtin/apply.c:2930 +#: builtin/apply.c:2939 #, c-format msgid "patch failed: %s:%ld" msgstr "patch misslyckades: %s:%ld" -#: builtin/apply.c:3045 +#: builtin/apply.c:3061 #, c-format -msgid "patch %s has been renamed/deleted" -msgstr "patchen %s har ändrat namn/tagits bort" +msgid "cannot checkout %s" +msgstr "kan inte checka ut %s" -#: builtin/apply.c:3052 builtin/apply.c:3069 +#: builtin/apply.c:3106 builtin/apply.c:3115 builtin/apply.c:3159 #, c-format msgid "read of %s failed" msgstr "misslyckades läsa %s" -#: builtin/apply.c:3084 -msgid "removal patch leaves file contents" -msgstr "patch för borttagning lämnar kvar filinnehåll" - -#: builtin/apply.c:3105 +#: builtin/apply.c:3139 builtin/apply.c:3361 #, c-format -msgid "%s: already exists in working directory" -msgstr "%s: finns redan i arbetskatalogen" +msgid "path %s has been renamed/deleted" +msgstr "sökvägen %s har ändrat namn/tagits bort" -#: builtin/apply.c:3143 +#: builtin/apply.c:3220 builtin/apply.c:3375 #, c-format -msgid "%s: has been deleted/renamed" -msgstr "%s: har tagits bort/ändrat namn" +msgid "%s: does not exist in index" +msgstr "%s: finns inte i indexet" -#: builtin/apply.c:3148 builtin/apply.c:3179 +#: builtin/apply.c:3224 builtin/apply.c:3367 builtin/apply.c:3389 #, c-format msgid "%s: %s" msgstr "%s: %s" -#: builtin/apply.c:3159 -#, c-format -msgid "%s: does not exist in index" -msgstr "%s: finns inte i indexet" - -#: builtin/apply.c:3173 +#: builtin/apply.c:3229 builtin/apply.c:3383 #, c-format msgid "%s: does not match index" msgstr "%s: motsvarar inte indexet" -#: builtin/apply.c:3190 +#: builtin/apply.c:3331 +msgid "removal patch leaves file contents" +msgstr "patch för borttagning lämnar kvar filinnehåll" + +#: builtin/apply.c:3400 #, c-format msgid "%s: wrong type" msgstr "%s: fel typ" -#: builtin/apply.c:3192 +#: builtin/apply.c:3402 #, c-format msgid "%s has type %o, expected %o" msgstr "%s har typen %o, förväntade %o" -#: builtin/apply.c:3247 +#: builtin/apply.c:3503 #, c-format msgid "%s: already exists in index" msgstr "%s: finns redan i indexet" -#: builtin/apply.c:3267 +#: builtin/apply.c:3506 +#, c-format +msgid "%s: already exists in working directory" +msgstr "%s: finns redan i arbetskatalogen" + +#: builtin/apply.c:3526 #, c-format msgid "new mode (%o) of %s does not match old mode (%o)" msgstr "nytt läge (%o) för %s motsvarar inte gammalt läge (%o)" -#: builtin/apply.c:3272 +#: builtin/apply.c:3531 #, c-format msgid "new mode (%o) of %s does not match old mode (%o) of %s" msgstr "nytt läge (%o) för %s motsvarar inte gammalt läge (%o) för %s" -#: builtin/apply.c:3280 +#: builtin/apply.c:3539 #, c-format msgid "%s: patch does not apply" msgstr "%s: patchen kan inte tillämpas" -#: builtin/apply.c:3293 +#: builtin/apply.c:3552 #, c-format msgid "Checking patch %s..." msgstr "Kontrollerar patchen %s..." -#: builtin/apply.c:3348 builtin/checkout.c:212 builtin/reset.c:158 +#: builtin/apply.c:3607 builtin/checkout.c:213 builtin/reset.c:158 #, c-format msgid "make_cache_entry failed for path '%s'" msgstr "make_cache_entry misslyckades för sökvägen \"%s\"" -#: builtin/apply.c:3491 +#: builtin/apply.c:3750 #, c-format msgid "unable to remove %s from index" msgstr "kan inte ta bort %s från indexet" -#: builtin/apply.c:3518 +#: builtin/apply.c:3778 #, c-format msgid "corrupt patch for subproject %s" msgstr "trasig patch för underprojektet %s" -#: builtin/apply.c:3522 +#: builtin/apply.c:3782 #, c-format msgid "unable to stat newly created file '%s'" msgstr "kan inte ta status på nyligen skapade filen \"%s\"" -#: builtin/apply.c:3527 +#: builtin/apply.c:3787 #, c-format msgid "unable to create backing store for newly created file %s" msgstr "kan inte skapa säkerhetsminne för nyligen skapade filen %s" -#: builtin/apply.c:3530 +#: builtin/apply.c:3790 builtin/apply.c:3898 #, c-format msgid "unable to add cache entry for %s" msgstr "kan inte lägga till cachepost för %s" -#: builtin/apply.c:3563 +#: builtin/apply.c:3823 #, c-format msgid "closing file '%s'" msgstr "stänger filen \"%s\"" -#: builtin/apply.c:3612 +#: builtin/apply.c:3872 #, c-format msgid "unable to write file '%s' mode %o" msgstr "kan inte skriva filen \"%s\" läge %o" -#: builtin/apply.c:3668 +#: builtin/apply.c:3959 #, c-format msgid "Applied patch %s cleanly." msgstr "Tillämpade patchen %s rent." -#: builtin/apply.c:3676 +#: builtin/apply.c:3967 msgid "internal error" msgstr "internt fel" #. Say this even without --verbose -#: builtin/apply.c:3679 +#: builtin/apply.c:3970 #, c-format msgid "Applying patch %%s with %d reject..." msgid_plural "Applying patch %%s with %d rejects..." msgstr[0] "Tillämpade patchen %%s med %d refuserad..." msgstr[1] "Tillämpade patchen %%s med %d refuserade..." -#: builtin/apply.c:3689 +#: builtin/apply.c:3980 #, c-format msgid "truncating .rej filename to %.*s.rej" msgstr "trunkerar .rej-filnamnet till %.*s.rej" -#: builtin/apply.c:3710 +#: builtin/apply.c:4001 #, c-format msgid "Hunk #%d applied cleanly." msgstr "Stycke %d tillämpades rent." -#: builtin/apply.c:3713 +#: builtin/apply.c:4004 #, c-format msgid "Rejected hunk #%d." msgstr "Refuserar stycke %d." -#: builtin/apply.c:3844 +#: builtin/apply.c:4154 msgid "unrecognized input" msgstr "indata känns inte igen" -#: builtin/apply.c:3855 +#: builtin/apply.c:4165 msgid "unable to read index file" msgstr "kan inte läsa indexfilen" -#: builtin/apply.c:3970 builtin/apply.c:3973 +#: builtin/apply.c:4284 builtin/apply.c:4287 msgid "path" msgstr "sökväg" -#: builtin/apply.c:3971 +#: builtin/apply.c:4285 msgid "don't apply changes matching the given path" msgstr "tillämpa inte ändringar som motsvarar given sökväg" -#: builtin/apply.c:3974 +#: builtin/apply.c:4288 msgid "apply changes matching the given path" msgstr "tillämpa ändringar som motsvarar given sökväg" -#: builtin/apply.c:3976 +#: builtin/apply.c:4290 msgid "num" msgstr "antal" -#: builtin/apply.c:3977 +#: builtin/apply.c:4291 msgid "remove leading slashes from traditional diff paths" msgstr "ta bort inledande snedstreck från traditionella diff-sökvägar" -#: builtin/apply.c:3980 +#: builtin/apply.c:4294 msgid "ignore additions made by the patch" msgstr "ignorera tillägg gjorda av patchen" -#: builtin/apply.c:3982 +#: builtin/apply.c:4296 msgid "instead of applying the patch, output diffstat for the input" msgstr "istället för att tillämpa patchen, skriv ut diffstat för indata" -#: builtin/apply.c:3986 +#: builtin/apply.c:4300 msgid "shows number of added and deleted lines in decimal notation" msgstr "visar antal tillagda och borttagna rader decimalt" -#: builtin/apply.c:3988 +#: builtin/apply.c:4302 msgid "instead of applying the patch, output a summary for the input" msgstr "istället för att tillämpa patchen, skriv ut en summering av indata" -#: builtin/apply.c:3990 +#: builtin/apply.c:4304 msgid "instead of applying the patch, see if the patch is applicable" msgstr "istället för att tillämpa patchen, se om patchen kan tillämpas" -#: builtin/apply.c:3992 +#: builtin/apply.c:4306 msgid "make sure the patch is applicable to the current index" msgstr "se till att patchen kan tillämpas på aktuellt index" -#: builtin/apply.c:3994 +#: builtin/apply.c:4308 msgid "apply a patch without touching the working tree" msgstr "tillämpa en patch utan att röra arbetskatalogen" -#: builtin/apply.c:3996 +#: builtin/apply.c:4310 msgid "also apply the patch (use with --stat/--summary/--check)" msgstr "tillämpa också patchen (använd med --stat/--summary/--check)" -#: builtin/apply.c:3998 +#: builtin/apply.c:4312 +msgid "attempt three-way merge if a patch does not apply" +msgstr "försök en trevägssammanslagning om patchen inte kan tillämpas" + +#: builtin/apply.c:4314 msgid "build a temporary index based on embedded index information" msgstr "bygg ett temporärt index baserat på inbyggd indexinformation" -#: builtin/apply.c:4000 +#: builtin/apply.c:4316 msgid "paths are separated with NUL character" msgstr "sökvägar avdelas med NUL-tecken" -#: builtin/apply.c:4003 +#: builtin/apply.c:4319 msgid "ensure at least lines of context match" msgstr "se till att åtminstone rader sammanhang är lika" -#: builtin/apply.c:4004 +#: builtin/apply.c:4320 msgid "action" msgstr "åtgärd" -#: builtin/apply.c:4005 +#: builtin/apply.c:4321 msgid "detect new or modified lines that have whitespace errors" msgstr "detektera nya eller ändrade rader som har fel i blanktecken" -#: builtin/apply.c:4008 builtin/apply.c:4011 +#: builtin/apply.c:4324 builtin/apply.c:4327 msgid "ignore changes in whitespace when finding context" msgstr "ignorera ändringar i blanktecken för sammanhang" -#: builtin/apply.c:4014 +#: builtin/apply.c:4330 msgid "apply the patch in reverse" msgstr "tillämpa patchen baklänges" -#: builtin/apply.c:4016 +#: builtin/apply.c:4332 msgid "don't expect at least one line of context" msgstr "förvänta inte minst en rad sammanhang" -#: builtin/apply.c:4018 +#: builtin/apply.c:4334 msgid "leave the rejected hunks in corresponding *.rej files" msgstr "lämna refuserade stycken i motsvarande *.rej-filer" -#: builtin/apply.c:4020 +#: builtin/apply.c:4336 msgid "allow overlapping hunks" msgstr "tillåt överlappande stycken" -#: builtin/apply.c:4021 +#: builtin/apply.c:4337 msgid "be verbose" msgstr "var pratsam" -#: builtin/apply.c:4023 +#: builtin/apply.c:4339 msgid "tolerate incorrectly detected missing new-line at the end of file" msgstr "tolerera felaktigt detekterade saknade nyradstecken vid filslut" -#: builtin/apply.c:4026 +#: builtin/apply.c:4342 msgid "do not trust the line counts in the hunk headers" msgstr "lite inte på antalet linjer i styckehuvuden" -#: builtin/apply.c:4028 +#: builtin/apply.c:4344 msgid "root" msgstr "rot" -#: builtin/apply.c:4029 +#: builtin/apply.c:4345 msgid "prepend to all filenames" msgstr "lägg till i alla filnamn" -#: builtin/apply.c:4050 +#: builtin/apply.c:4367 +msgid "--3way outside a repository" +msgstr "--3way utanför arkiv" + +#: builtin/apply.c:4375 msgid "--index outside a repository" msgstr "--index utanför arkiv" -#: builtin/apply.c:4053 +#: builtin/apply.c:4378 msgid "--cached outside a repository" msgstr "--cached utanför arkiv" -#: builtin/apply.c:4069 +#: builtin/apply.c:4394 #, c-format msgid "can't open patch '%s'" msgstr "kan inte öppna patchen \"%s\"" -#: builtin/apply.c:4083 +#: builtin/apply.c:4408 #, c-format msgid "squelched %d whitespace error" msgid_plural "squelched %d whitespace errors" msgstr[0] "undertryckte %d fel i blanksteg" msgstr[1] "undertryckte %d fel i blanksteg" -#: builtin/apply.c:4089 builtin/apply.c:4099 +#: builtin/apply.c:4414 builtin/apply.c:4424 #, c-format msgid "%d line adds whitespace errors." msgid_plural "%d lines add whitespace errors." @@ -1783,7 +2053,7 @@ msgstr "kunde inte skriva grenbeskrivningsmall: %s" msgid "Failed to resolve HEAD as a valid ref." msgstr "Misslyckades slå upp HEAD som giltig referens" -#: builtin/branch.c:788 builtin/clone.c:558 +#: builtin/branch.c:788 builtin/clone.c:561 msgid "HEAD not found below refs/heads!" msgstr "HEAD hittades inte under refs/heads!" @@ -1810,99 +2080,99 @@ msgstr "Behöver ett arkiv för att skapa ett paket (bundle)." msgid "Need a repository to unbundle." msgstr "Behöver ett arkiv för att packa upp ett paket (bundle)." -#: builtin/checkout.c:113 builtin/checkout.c:146 +#: builtin/checkout.c:114 builtin/checkout.c:147 #, c-format msgid "path '%s' does not have our version" msgstr "sökvägen \"%s\" har inte vår version" -#: builtin/checkout.c:115 builtin/checkout.c:148 +#: builtin/checkout.c:116 builtin/checkout.c:149 #, c-format msgid "path '%s' does not have their version" msgstr "sökvägen \"%s\" har inte deras version" -#: builtin/checkout.c:131 +#: builtin/checkout.c:132 #, c-format msgid "path '%s' does not have all necessary versions" msgstr "sökvägen \"%s\" innehåller inte alla nödvändiga versioner" -#: builtin/checkout.c:175 +#: builtin/checkout.c:176 #, c-format msgid "path '%s' does not have necessary versions" msgstr "sökvägen \"%s\" innehåller inte nödvändiga versioner" -#: builtin/checkout.c:192 +#: builtin/checkout.c:193 #, c-format msgid "path '%s': cannot merge" msgstr "sökväg \"%s\": kan inte slå ihop" -#: builtin/checkout.c:209 +#: builtin/checkout.c:210 #, c-format msgid "Unable to add merge result for '%s'" msgstr "Kunde inte lägga till sammanslagningsresultat för \"%s\"" -#: builtin/checkout.c:234 builtin/checkout.c:392 +#: builtin/checkout.c:235 builtin/checkout.c:393 msgid "corrupt index file" msgstr "indexfilen är trasig" -#: builtin/checkout.c:264 builtin/checkout.c:271 +#: builtin/checkout.c:265 builtin/checkout.c:272 #, c-format msgid "path '%s' is unmerged" msgstr "sökvägen \"%s\" har inte slagits ihop" -#: builtin/checkout.c:302 builtin/checkout.c:498 builtin/clone.c:583 +#: builtin/checkout.c:303 builtin/checkout.c:499 builtin/clone.c:586 #: builtin/merge.c:812 msgid "unable to write new index file" msgstr "kunde inte skriva ny indexfil" -#: builtin/checkout.c:319 builtin/diff.c:302 builtin/merge.c:408 +#: builtin/checkout.c:320 builtin/diff.c:302 builtin/merge.c:408 msgid "diff_setup_done failed" msgstr "diff_setup_done misslyckades" -#: builtin/checkout.c:414 +#: builtin/checkout.c:415 msgid "you need to resolve your current index first" msgstr "du måste lösa ditt befintliga index först" -#: builtin/checkout.c:533 +#: builtin/checkout.c:534 #, c-format msgid "Can not do reflog for '%s'\n" msgstr "Kan inte skapa referenslog för \"%s\"\n" -#: builtin/checkout.c:566 +#: builtin/checkout.c:567 msgid "HEAD is now at" msgstr "HEAD är nu på" -#: builtin/checkout.c:573 +#: builtin/checkout.c:574 #, c-format msgid "Reset branch '%s'\n" msgstr "Återställ gren \"%s\"\n" -#: builtin/checkout.c:576 +#: builtin/checkout.c:577 #, c-format msgid "Already on '%s'\n" msgstr "Redan på \"%s\"\n" -#: builtin/checkout.c:580 +#: builtin/checkout.c:581 #, c-format msgid "Switched to and reset branch '%s'\n" msgstr "Växlade till och nollställde grenen \"%s\"\n" -#: builtin/checkout.c:582 +#: builtin/checkout.c:583 #, c-format msgid "Switched to a new branch '%s'\n" msgstr "Växlade till en ny gren \"%s\"\n" -#: builtin/checkout.c:584 +#: builtin/checkout.c:585 #, c-format msgid "Switched to branch '%s'\n" msgstr "Växlade till grenen \"%s\"\n" -#: builtin/checkout.c:640 +#: builtin/checkout.c:641 #, c-format msgid " ... and %d more.\n" msgstr " ... och %d till.\n" #. The singular version -#: builtin/checkout.c:646 +#: builtin/checkout.c:647 #, c-format msgid "" "Warning: you are leaving %d commit behind, not connected to\n" @@ -1925,7 +2195,7 @@ msgstr[1] "" "\n" "%s\n" -#: builtin/checkout.c:664 +#: builtin/checkout.c:665 #, c-format msgid "" "If you want to keep them by creating a new branch, this may be a good time\n" @@ -1940,71 +2210,71 @@ msgstr "" " git branch nytt_grennamn %s\n" "\n" -#: builtin/checkout.c:694 +#: builtin/checkout.c:695 msgid "internal error in revision walk" msgstr "internt fel vid genomgång av revisioner (revision walk)" -#: builtin/checkout.c:698 +#: builtin/checkout.c:699 msgid "Previous HEAD position was" msgstr "Tidigare position för HEAD var" -#: builtin/checkout.c:724 +#: builtin/checkout.c:725 builtin/checkout.c:920 msgid "You are on a branch yet to be born" msgstr "Du är på en gren som ännu inte är född" #. case (1) -#: builtin/checkout.c:855 +#: builtin/checkout.c:856 #, c-format msgid "invalid reference: %s" msgstr "felaktig referens: %s" #. case (1): want a tree -#: builtin/checkout.c:894 +#: builtin/checkout.c:895 #, c-format msgid "reference is not a tree: %s" msgstr "referensen är inte ett träd: %s" -#: builtin/checkout.c:974 +#: builtin/checkout.c:977 msgid "-B cannot be used with -b" msgstr "-B kan inte användas med -b" -#: builtin/checkout.c:983 +#: builtin/checkout.c:986 msgid "--patch is incompatible with all other options" msgstr "--patch är inkompatibel med alla andra flaggor" -#: builtin/checkout.c:986 +#: builtin/checkout.c:989 msgid "--detach cannot be used with -b/-B/--orphan" msgstr "--detcah kan inte användas med -b/-B/--orphan" -#: builtin/checkout.c:988 +#: builtin/checkout.c:991 msgid "--detach cannot be used with -t" msgstr "--detach kan inte användas med -t" -#: builtin/checkout.c:994 +#: builtin/checkout.c:997 msgid "--track needs a branch name" msgstr "--track behöver ett namn på en gren" -#: builtin/checkout.c:1001 +#: builtin/checkout.c:1004 msgid "Missing branch name; try -b" msgstr "Grennamn saknas; försök med -b" -#: builtin/checkout.c:1007 +#: builtin/checkout.c:1010 msgid "--orphan and -b|-B are mutually exclusive" msgstr "--orphan och -b|-B kan inte användas samtidigt" -#: builtin/checkout.c:1009 +#: builtin/checkout.c:1012 msgid "--orphan cannot be used with -t" msgstr "--orphan kan inte användas med -t" -#: builtin/checkout.c:1019 +#: builtin/checkout.c:1022 msgid "git checkout: -f and -m are incompatible" msgstr "git checkout: -f och -m är inkompatibla" -#: builtin/checkout.c:1053 +#: builtin/checkout.c:1056 msgid "invalid path specification" msgstr "felaktig sökvägsangivelse" -#: builtin/checkout.c:1061 +#: builtin/checkout.c:1064 #, c-format msgid "" "git checkout: updating paths is incompatible with switching branches.\n" @@ -2013,15 +2283,15 @@ msgstr "" "git checkout: uppdatera sökvägar är inkompatibelt med att växla gren.\n" "Ville du checka ut \"%s\" som inte kan lösas som en sammanslaning?" -#: builtin/checkout.c:1063 +#: builtin/checkout.c:1066 msgid "git checkout: updating paths is incompatible with switching branches." msgstr "git checkout: uppdatera sökvägar är inkompatibelt med att växla gren." -#: builtin/checkout.c:1068 +#: builtin/checkout.c:1071 msgid "git checkout: --detach does not take a path argument" msgstr "git checkout: --detach tar inte en sökväg som argument" -#: builtin/checkout.c:1071 +#: builtin/checkout.c:1074 msgid "" "git checkout: --ours/--theirs, --force and --merge are incompatible when\n" "checking out of the index." @@ -2029,11 +2299,11 @@ msgstr "" "git checkout: --ours/--theirs, --force och --merge är inkompatibla när\n" "du checkar ut från indexet." -#: builtin/checkout.c:1090 +#: builtin/checkout.c:1093 msgid "Cannot switch branch to a non-commit." msgstr "Kan inte växla gren på en icke-incheckning." -#: builtin/checkout.c:1093 +#: builtin/checkout.c:1096 msgid "--ours/--theirs is incompatible with switching branches." msgstr "--ours/--theirs är inkompatibla med att byta gren." @@ -2086,11 +2356,6 @@ msgstr "Tar inte bort %s\n" msgid "reference repository '%s' is not a local directory." msgstr "referensarkivet \"%s\" är inte en lokal katalog." -#: builtin/clone.c:302 -#, c-format -msgid "failed to open '%s'" -msgstr "misslyckades öppna \"%s\"" - #: builtin/clone.c:306 #, c-format msgid "failed to create directory '%s'" @@ -2131,79 +2396,79 @@ msgstr "misslyckades kopiera filen till \"%s\"" msgid "done.\n" msgstr "klart.\n" -#: builtin/clone.c:440 +#: builtin/clone.c:443 #, c-format msgid "Could not find remote branch %s to clone." msgstr "Kunde inte hitta fjärrgrenen %s för att klona." -#: builtin/clone.c:549 +#: builtin/clone.c:552 msgid "remote HEAD refers to nonexistent ref, unable to checkout.\n" msgstr "" "HEAD hos fjärren pekar på en obefintlig referens, kan inte checka ut.\n" -#: builtin/clone.c:639 +#: builtin/clone.c:642 msgid "Too many arguments." msgstr "För många argument." -#: builtin/clone.c:643 +#: builtin/clone.c:646 msgid "You must specify a repository to clone." msgstr "Du måste ange ett arkiv att klona." -#: builtin/clone.c:654 +#: builtin/clone.c:657 #, c-format msgid "--bare and --origin %s options are incompatible." msgstr "flaggorna --bare och --origin %s är inkompatibla." -#: builtin/clone.c:668 +#: builtin/clone.c:671 #, c-format msgid "repository '%s' does not exist" msgstr "arkivet \"%s\" finns inte" -#: builtin/clone.c:673 +#: builtin/clone.c:676 msgid "--depth is ignored in local clones; use file:// instead." msgstr "--depth ignoreras i lokala kloningar; använd file:// istället" -#: builtin/clone.c:683 +#: builtin/clone.c:686 #, c-format msgid "destination path '%s' already exists and is not an empty directory." msgstr "destinationssökvägen \"%s\" finns redan och är inte en tom katalog." -#: builtin/clone.c:693 +#: builtin/clone.c:696 #, c-format msgid "working tree '%s' already exists." msgstr "arbetsträdet \"%s\" finns redan." -#: builtin/clone.c:706 builtin/clone.c:720 +#: builtin/clone.c:709 builtin/clone.c:723 #, c-format msgid "could not create leading directories of '%s'" msgstr "kunde inte skapa inledande kataloger för \"%s\"" -#: builtin/clone.c:709 +#: builtin/clone.c:712 #, c-format msgid "could not create work tree dir '%s'." msgstr "kunde inte skapa arbetskatalogen \"%s\"" -#: builtin/clone.c:728 +#: builtin/clone.c:731 #, c-format msgid "Cloning into bare repository '%s'...\n" msgstr "Klonar till ett naket arkiv \"%s\"...\n" -#: builtin/clone.c:730 +#: builtin/clone.c:733 #, c-format msgid "Cloning into '%s'...\n" msgstr "Klonar till \"%s\"...\n" -#: builtin/clone.c:786 +#: builtin/clone.c:789 #, c-format msgid "Don't know how to clone %s" msgstr "Vet inte hur man klonar %s" -#: builtin/clone.c:835 +#: builtin/clone.c:838 #, c-format msgid "Remote branch %s not found in upstream %s" msgstr "Fjärrgrenen %s hittades inte i uppströmsarkivet %s" -#: builtin/clone.c:842 +#: builtin/clone.c:845 msgid "You appear to have cloned an empty repository." msgstr "Du verkar ha klonat ett tomt arkiv." @@ -2262,93 +2527,93 @@ msgstr "" "\n" "Annars använder du \"git reset\"\n" -#: builtin/commit.c:253 +#: builtin/commit.c:256 msgid "failed to unpack HEAD tree object" msgstr "misslyckades packa upp HEAD:s trädobjekt" -#: builtin/commit.c:295 +#: builtin/commit.c:298 msgid "unable to create temporary index" msgstr "kunde inte skapa temporär indexfil" -#: builtin/commit.c:301 +#: builtin/commit.c:304 msgid "interactive add failed" msgstr "interaktiv tilläggning misslyckades" -#: builtin/commit.c:334 builtin/commit.c:355 builtin/commit.c:405 +#: builtin/commit.c:337 builtin/commit.c:358 builtin/commit.c:408 msgid "unable to write new_index file" msgstr "kunde inte skriva filen new_index" -#: builtin/commit.c:386 +#: builtin/commit.c:389 msgid "cannot do a partial commit during a merge." msgstr "kan inte utföra en delvis incheckning under en sammanslagning." -#: builtin/commit.c:388 +#: builtin/commit.c:391 msgid "cannot do a partial commit during a cherry-pick." msgstr "kan inte utföra en delvis incheckning under en cherry-pick." -#: builtin/commit.c:398 +#: builtin/commit.c:401 msgid "cannot read the index" msgstr "kan inte läsa indexet" -#: builtin/commit.c:418 +#: builtin/commit.c:421 msgid "unable to write temporary index file" msgstr "kunde inte skriva temporär indexfil" -#: builtin/commit.c:493 builtin/commit.c:499 +#: builtin/commit.c:496 builtin/commit.c:502 #, c-format msgid "invalid commit: %s" msgstr "felaktig incheckning: %s" -#: builtin/commit.c:522 +#: builtin/commit.c:525 msgid "malformed --author parameter" msgstr "felformad \"--author\"-flagga" -#: builtin/commit.c:582 +#: builtin/commit.c:585 #, c-format msgid "Malformed ident string: '%s'" msgstr "Felaktig indragningssträng: \"%s\"" -#: builtin/commit.c:620 builtin/commit.c:653 builtin/commit.c:967 +#: builtin/commit.c:623 builtin/commit.c:656 builtin/commit.c:970 #, c-format msgid "could not lookup commit %s" msgstr "kunde inte slå upp incheckningen %s" -#: builtin/commit.c:632 builtin/shortlog.c:296 +#: builtin/commit.c:635 builtin/shortlog.c:296 #, c-format msgid "(reading log message from standard input)\n" msgstr "(läser loggmeddelande från standard in)\n" -#: builtin/commit.c:634 +#: builtin/commit.c:637 msgid "could not read log from standard input" msgstr "kunde inte läsa logg från standard in" -#: builtin/commit.c:638 +#: builtin/commit.c:641 #, c-format msgid "could not read log file '%s'" msgstr "kunde inte läsa loggfilen \"%s\"" -#: builtin/commit.c:644 +#: builtin/commit.c:647 msgid "commit has empty message" msgstr "incheckningen har ett tomt meddelande" -#: builtin/commit.c:660 +#: builtin/commit.c:663 msgid "could not read MERGE_MSG" msgstr "kunde inte läsa MERGE_MSG" -#: builtin/commit.c:664 +#: builtin/commit.c:667 msgid "could not read SQUASH_MSG" msgstr "kunde inte läsa SQUASH_MSG" -#: builtin/commit.c:668 +#: builtin/commit.c:671 #, c-format msgid "could not read '%s'" msgstr "kunde inte läsa \"%s\"" -#: builtin/commit.c:720 +#: builtin/commit.c:723 msgid "could not write commit template" msgstr "kunde inte skriva incheckningsmall" -#: builtin/commit.c:731 +#: builtin/commit.c:734 #, c-format msgid "" "\n" @@ -2363,7 +2628,7 @@ msgstr "" "\t%s\n" "och försöker igen.\n" -#: builtin/commit.c:736 +#: builtin/commit.c:739 #, c-format msgid "" "\n" @@ -2378,7 +2643,7 @@ msgstr "" "\t%s\n" "och försöker igen.\n" -#: builtin/commit.c:748 +#: builtin/commit.c:751 msgid "" "Please enter the commit message for your changes. Lines starting\n" "with '#' will be ignored, and an empty message aborts the commit.\n" @@ -2386,7 +2651,7 @@ msgstr "" "Ange incheckningsmeddelandet för dina ändringar. Rader som inleds\n" "med \"#\" kommer ignoreras, och ett tomt meddelande avbryter incheckningen.\n" -#: builtin/commit.c:753 +#: builtin/commit.c:756 msgid "" "Please enter the commit message for your changes. Lines starting\n" "with '#' will be kept; you may remove them yourself if you want to.\n" @@ -2396,159 +2661,159 @@ msgstr "" "med \"#\" kommer behållas; du kan själv ta bort dem om du vill.\n" "Ett tomt meddelande avbryter incheckningen.\n" -#: builtin/commit.c:766 +#: builtin/commit.c:769 #, c-format msgid "%sAuthor: %s" msgstr "%sFörfattare: %s" -#: builtin/commit.c:773 +#: builtin/commit.c:776 #, c-format msgid "%sCommitter: %s" msgstr "%sIncheckare: %s" -#: builtin/commit.c:793 +#: builtin/commit.c:796 msgid "Cannot read index" msgstr "Kan inte läsa indexet" -#: builtin/commit.c:830 +#: builtin/commit.c:833 msgid "Error building trees" msgstr "Fel vid byggande av träd" -#: builtin/commit.c:845 builtin/tag.c:361 +#: builtin/commit.c:848 builtin/tag.c:361 #, c-format msgid "Please supply the message using either -m or -F option.\n" msgstr "Ange meddelandet en av flaggorna -m eller -F.\n" -#: builtin/commit.c:942 +#: builtin/commit.c:945 #, c-format msgid "No existing author found with '%s'" msgstr "Hittade ingen befintlig författare med \"%s\"" -#: builtin/commit.c:957 builtin/commit.c:1157 +#: builtin/commit.c:960 builtin/commit.c:1160 #, c-format msgid "Invalid untracked files mode '%s'" msgstr "Ogiltigt läge för ospårade filer: \"%s\"" -#: builtin/commit.c:997 +#: builtin/commit.c:1000 msgid "Using both --reset-author and --author does not make sense" msgstr "Kan inte använda både --reset-author och --author" -#: builtin/commit.c:1008 +#: builtin/commit.c:1011 msgid "You have nothing to amend." msgstr "Du har inget att utöka." -#: builtin/commit.c:1011 +#: builtin/commit.c:1014 msgid "You are in the middle of a merge -- cannot amend." msgstr "Du är i mitten av en sammanslagning -- kan inte utöka." -#: builtin/commit.c:1013 +#: builtin/commit.c:1016 msgid "You are in the middle of a cherry-pick -- cannot amend." msgstr "Du är i mitten av en cherry-pick -- kan inte utöka." -#: builtin/commit.c:1016 +#: builtin/commit.c:1019 msgid "Options --squash and --fixup cannot be used together" msgstr "Flaggorna --squash och --fixup kan inte användas samtidigt" -#: builtin/commit.c:1026 +#: builtin/commit.c:1029 msgid "Only one of -c/-C/-F/--fixup can be used." msgstr "Endast en av -c/-C/-F/--fixup kan användas." -#: builtin/commit.c:1028 +#: builtin/commit.c:1031 msgid "Option -m cannot be combined with -c/-C/-F/--fixup." msgstr "Flaggan -m kan inte kombineras med -c/-C/-F/--fixup." -#: builtin/commit.c:1036 +#: builtin/commit.c:1039 msgid "--reset-author can be used only with -C, -c or --amend." msgstr "--reset-author kan endast användas med -C, -c eller --amend." -#: builtin/commit.c:1053 +#: builtin/commit.c:1056 msgid "Only one of --include/--only/--all/--interactive/--patch can be used." msgstr "" "Endast en av --include/--only/--all/--interactive/--patch kan användas." -#: builtin/commit.c:1055 +#: builtin/commit.c:1058 msgid "No paths with --include/--only does not make sense." msgstr "Du måste ange sökvägar tillsammans med --include/--only." -#: builtin/commit.c:1057 +#: builtin/commit.c:1060 msgid "Clever... amending the last one with dirty index." msgstr "Smart... utöka den senaste med smutsigt index." -#: builtin/commit.c:1059 +#: builtin/commit.c:1062 msgid "Explicit paths specified without -i nor -o; assuming --only paths..." msgstr "Explicita sökvägar angavs utan -i eller -o; antar --only sökvägar..." -#: builtin/commit.c:1069 builtin/tag.c:577 +#: builtin/commit.c:1072 builtin/tag.c:577 #, c-format msgid "Invalid cleanup mode %s" msgstr "Felaktigt städningsläge %s" -#: builtin/commit.c:1074 +#: builtin/commit.c:1077 msgid "Paths with -a does not make sense." msgstr "Kan inte ange sökvägar med -a." -#: builtin/commit.c:1257 +#: builtin/commit.c:1260 msgid "couldn't look up newly created commit" msgstr "kunde inte slå upp en precis skapad incheckning" -#: builtin/commit.c:1259 +#: builtin/commit.c:1262 msgid "could not parse newly created commit" msgstr "kunde inte tolka en precis skapad incheckning" -#: builtin/commit.c:1300 +#: builtin/commit.c:1303 msgid "detached HEAD" msgstr "frånkopplad HEAD" -#: builtin/commit.c:1302 +#: builtin/commit.c:1305 msgid " (root-commit)" msgstr " (rotincheckning)" -#: builtin/commit.c:1446 +#: builtin/commit.c:1449 msgid "could not parse HEAD commit" msgstr "kunde inte tolka HEAD:s incheckning" -#: builtin/commit.c:1484 builtin/merge.c:509 +#: builtin/commit.c:1487 builtin/merge.c:509 #, c-format msgid "could not open '%s' for reading" msgstr "kunde inte öppna \"%s\" för läsning" -#: builtin/commit.c:1491 +#: builtin/commit.c:1494 #, c-format msgid "Corrupt MERGE_HEAD file (%s)" msgstr "Trasig MERGE_HEAD-fil (%s)" -#: builtin/commit.c:1498 +#: builtin/commit.c:1501 msgid "could not read MERGE_MODE" msgstr "kunde inte läsa MERGE_MODE" -#: builtin/commit.c:1517 +#: builtin/commit.c:1520 #, c-format msgid "could not read commit message: %s" msgstr "kunde inte läsa incheckningsmeddelande: %s" -#: builtin/commit.c:1531 +#: builtin/commit.c:1534 #, c-format msgid "Aborting commit; you did not edit the message.\n" msgstr "Avbryter incheckning; meddelandet inte redigerat.\n" -#: builtin/commit.c:1536 +#: builtin/commit.c:1539 #, c-format msgid "Aborting commit due to empty commit message.\n" msgstr "Avbryter på grund av tomt incheckningsmeddelande.\n" -#: builtin/commit.c:1551 builtin/merge.c:936 builtin/merge.c:961 +#: builtin/commit.c:1554 builtin/merge.c:936 builtin/merge.c:961 msgid "failed to write commit object" msgstr "kunde inte skriva incheckningsobjekt" -#: builtin/commit.c:1572 +#: builtin/commit.c:1575 msgid "cannot lock HEAD ref" msgstr "kunde inte låsa HEAD-referens" -#: builtin/commit.c:1576 +#: builtin/commit.c:1579 msgid "cannot update HEAD ref" msgstr "kunde inte uppdatera HEAD-referens" -#: builtin/commit.c:1587 +#: builtin/commit.c:1590 msgid "" "Repository has been updated, but unable to write\n" "new_index file. Check that disk is not full or quota is\n" @@ -2922,30 +3187,30 @@ msgstr "--[no-]exclude-standard kan inte användas för spårat innehåll." msgid "both --cached and trees are given." msgstr "både --cached och träd angavs." -#: builtin/help.c:63 +#: builtin/help.c:65 #, c-format msgid "unrecognized help format '%s'" msgstr "okänt hjälpformat: %s" -#: builtin/help.c:91 +#: builtin/help.c:93 msgid "Failed to start emacsclient." msgstr "Misslyckades starta emacsclient." -#: builtin/help.c:104 +#: builtin/help.c:106 msgid "Failed to parse emacsclient version." msgstr "Kunde inte tolka emacsclient-version." -#: builtin/help.c:112 +#: builtin/help.c:114 #, c-format msgid "emacsclient version '%d' too old (< 22)." msgstr "emacsclient version \"%d\" för gammal (< 22)." -#: builtin/help.c:130 builtin/help.c:158 builtin/help.c:167 builtin/help.c:175 +#: builtin/help.c:132 builtin/help.c:160 builtin/help.c:169 builtin/help.c:177 #, c-format msgid "failed to exec '%s': %s" msgstr "exec misslyckades för \"%s\": %s" -#: builtin/help.c:215 +#: builtin/help.c:217 #, c-format msgid "" "'%s': path for unsupported man viewer.\n" @@ -2954,7 +3219,7 @@ msgstr "" "\"%s\": sökväg för man-visare som ej stöds.\n" "Använd \"man..cmd\" istället." -#: builtin/help.c:227 +#: builtin/help.c:229 #, c-format msgid "" "'%s': cmd for supported man viewer.\n" @@ -2963,34 +3228,29 @@ msgstr "" "\"%s\": kommando för man-visare som stöds.\n" "Använd \"man..path\" istället." -#: builtin/help.c:291 +#: builtin/help.c:299 msgid "The most commonly used git commands are:" msgstr "De mest använda git-kommandona är:" -#: builtin/help.c:359 +#: builtin/help.c:367 #, c-format msgid "'%s': unknown man viewer." msgstr "\"%s\": okänd man-visare." -#: builtin/help.c:376 +#: builtin/help.c:384 msgid "no man viewer handled the request" msgstr "ingen man-visare hanterade förfrågan" -#: builtin/help.c:384 +#: builtin/help.c:392 msgid "no info viewer handled the request" msgstr "ingen info-visare hanterade förfrågan" -#: builtin/help.c:395 -#, c-format -msgid "'%s': not a documentation directory." -msgstr "\"%s\": inte en dokumentationskatalog." - -#: builtin/help.c:436 builtin/help.c:443 +#: builtin/help.c:447 builtin/help.c:454 #, c-format msgid "usage: %s%s" msgstr "användning: %s%s" -#: builtin/help.c:459 +#: builtin/help.c:470 #, c-format msgid "`git %s' is aliased to `%s'" msgstr "\"git %s\" är ett alias för \"%s\"" @@ -3064,176 +3324,176 @@ msgstr "deltabasindex utanför gränsen" msgid "unknown object type %d" msgstr "okänd objekttyp %d" -#: builtin/index-pack.c:531 +#: builtin/index-pack.c:530 msgid "cannot pread pack file" msgstr "kan inte utföra \"pread\" på paketfil" -#: builtin/index-pack.c:533 +#: builtin/index-pack.c:532 #, c-format msgid "premature end of pack file, %lu byte missing" msgid_plural "premature end of pack file, %lu bytes missing" msgstr[0] "för tidigt slut på paketfilen, %lu byte saknas" msgstr[1] "för tidigt slut på paketfilen, %lu byte saknas" -#: builtin/index-pack.c:555 +#: builtin/index-pack.c:558 msgid "serious inflate inconsistency" msgstr "allvarlig inflate-inkonsekvens" -#: builtin/index-pack.c:646 builtin/index-pack.c:652 builtin/index-pack.c:675 -#: builtin/index-pack.c:709 builtin/index-pack.c:718 +#: builtin/index-pack.c:649 builtin/index-pack.c:655 builtin/index-pack.c:678 +#: builtin/index-pack.c:712 builtin/index-pack.c:721 #, c-format msgid "SHA1 COLLISION FOUND WITH %s !" msgstr "SHA1-KOLLISION UPPTÄCKT VID %s !" -#: builtin/index-pack.c:649 builtin/pack-objects.c:170 +#: builtin/index-pack.c:652 builtin/pack-objects.c:170 #: builtin/pack-objects.c:262 #, c-format msgid "unable to read %s" msgstr "kunde inte läsa %s" -#: builtin/index-pack.c:715 +#: builtin/index-pack.c:718 #, c-format msgid "cannot read existing object %s" msgstr "kan inte läsa befintligt objekt %s" -#: builtin/index-pack.c:729 +#: builtin/index-pack.c:732 #, c-format msgid "invalid blob object %s" msgstr "ogiltigt blob-objekt %s" -#: builtin/index-pack.c:744 +#: builtin/index-pack.c:747 #, c-format msgid "invalid %s" msgstr "ogiltigt %s" -#: builtin/index-pack.c:746 +#: builtin/index-pack.c:749 msgid "Error in object" msgstr "Fel i objekt" -#: builtin/index-pack.c:748 +#: builtin/index-pack.c:751 #, c-format msgid "Not all child objects of %s are reachable" msgstr "Inte alla barnobjekt för %s kan nås" -#: builtin/index-pack.c:818 builtin/index-pack.c:844 +#: builtin/index-pack.c:821 builtin/index-pack.c:847 msgid "failed to apply delta" msgstr "misslyckades tillämpa delta" -#: builtin/index-pack.c:983 +#: builtin/index-pack.c:986 msgid "Receiving objects" -msgstr "Tar bort objeckt" +msgstr "Tar bort objekt" -#: builtin/index-pack.c:983 +#: builtin/index-pack.c:986 msgid "Indexing objects" msgstr "Skapar index för objekt" -#: builtin/index-pack.c:1009 +#: builtin/index-pack.c:1012 msgid "pack is corrupted (SHA1 mismatch)" msgstr "paketet är trasigt (SHA1 stämmer inte)" -#: builtin/index-pack.c:1014 +#: builtin/index-pack.c:1017 msgid "cannot fstat packfile" msgstr "kan inte utföra \"fstat\" på paketfil" -#: builtin/index-pack.c:1017 +#: builtin/index-pack.c:1020 msgid "pack has junk at the end" msgstr "paket har skräp i slutet" -#: builtin/index-pack.c:1028 +#: builtin/index-pack.c:1031 msgid "confusion beyond insanity in parse_pack_objects()" msgstr "förvirrad bortom vanvett i parse_pack_objects()" -#: builtin/index-pack.c:1051 +#: builtin/index-pack.c:1054 msgid "Resolving deltas" msgstr "Analyserar delta" -#: builtin/index-pack.c:1102 +#: builtin/index-pack.c:1105 msgid "confusion beyond insanity" msgstr "förvirrad bortom vanvett" -#: builtin/index-pack.c:1121 +#: builtin/index-pack.c:1124 #, c-format msgid "pack has %d unresolved delta" msgid_plural "pack has %d unresolved deltas" msgstr[0] "paketet har %d oanalyserat delta" msgstr[1] "paketet har %d oanalyserade delta" -#: builtin/index-pack.c:1146 +#: builtin/index-pack.c:1149 #, c-format msgid "unable to deflate appended object (%d)" msgstr "kunde inte utföra \"deflate\" på tillagt objekt (%d)" -#: builtin/index-pack.c:1225 +#: builtin/index-pack.c:1228 #, c-format msgid "local object %s is corrupt" msgstr "lokalt objekt %s är trasigt" -#: builtin/index-pack.c:1249 +#: builtin/index-pack.c:1252 msgid "error while closing pack file" msgstr "fel vid stängning av paketfil" -#: builtin/index-pack.c:1262 +#: builtin/index-pack.c:1265 #, c-format msgid "cannot write keep file '%s'" msgstr "kan inte ta skriva \"keep\"-fil \"%s\"" -#: builtin/index-pack.c:1270 +#: builtin/index-pack.c:1273 #, c-format msgid "cannot close written keep file '%s'" msgstr "akn inte stänga skriven \"keep\"-fil \"%s\"" -#: builtin/index-pack.c:1283 +#: builtin/index-pack.c:1286 msgid "cannot store pack file" msgstr "kan inte spara paketfil" -#: builtin/index-pack.c:1294 +#: builtin/index-pack.c:1297 msgid "cannot store index file" msgstr "kan inte spara indexfil" -#: builtin/index-pack.c:1395 +#: builtin/index-pack.c:1398 #, c-format msgid "Cannot open existing pack file '%s'" msgstr "Kan inte öppna befintlig paketfil \"%s\"" -#: builtin/index-pack.c:1397 +#: builtin/index-pack.c:1400 #, c-format msgid "Cannot open existing pack idx file for '%s'" msgstr "Kan inte öppna befintligt paket-idx-fil för \"%s\"" -#: builtin/index-pack.c:1444 +#: builtin/index-pack.c:1447 #, c-format msgid "non delta: %d object" msgid_plural "non delta: %d objects" msgstr[0] "icke-delta: %d objekt" msgstr[1] "icke-delta: %d objekt" -#: builtin/index-pack.c:1451 +#: builtin/index-pack.c:1454 #, c-format msgid "chain length = %d: %lu object" msgid_plural "chain length = %d: %lu objects" msgstr[0] "kedjelängd = %d: %lu objekt" msgstr[1] "kedjelängd = %d: %lu objekt" -#: builtin/index-pack.c:1478 +#: builtin/index-pack.c:1481 msgid "Cannot come back to cwd" msgstr "Kan inte gå tillbaka till arbetskatalogen (cwd)" -#: builtin/index-pack.c:1522 builtin/index-pack.c:1525 -#: builtin/index-pack.c:1537 builtin/index-pack.c:1541 +#: builtin/index-pack.c:1525 builtin/index-pack.c:1528 +#: builtin/index-pack.c:1540 builtin/index-pack.c:1544 #, c-format msgid "bad %s" msgstr "felaktig %s" -#: builtin/index-pack.c:1555 +#: builtin/index-pack.c:1558 msgid "--fix-thin cannot be used without --stdin" msgstr "--fix-thin kan inte användas med --stdin" -#: builtin/index-pack.c:1559 builtin/index-pack.c:1569 +#: builtin/index-pack.c:1562 builtin/index-pack.c:1572 #, c-format msgid "packfile name '%s' does not end with '.pack'" msgstr "paketfilnamnet \"%s\" slutar inte med \".pack\"" -#: builtin/index-pack.c:1578 +#: builtin/index-pack.c:1581 msgid "--verify with no packfile name given" msgstr "--verify angavs utan paketfilnamn" @@ -3307,22 +3567,22 @@ msgstr "kopierade inte mallar från felaktig formatversion %d från \"%s\"" msgid "insane git directory %s" msgstr "tokig git-katalog %s" -#: builtin/init-db.c:322 builtin/init-db.c:325 +#: builtin/init-db.c:323 builtin/init-db.c:326 #, c-format msgid "%s already exists" msgstr "%s finns redan" -#: builtin/init-db.c:354 +#: builtin/init-db.c:355 #, c-format msgid "unable to handle file type %d" msgstr "kan inte hantera filtyp %d" -#: builtin/init-db.c:357 +#: builtin/init-db.c:358 #, c-format msgid "unable to move %s to %s" msgstr "kan inte flytta %s till %s" -#: builtin/init-db.c:362 +#: builtin/init-db.c:363 #, c-format msgid "Could not create git link %s" msgstr "Kunde inte skapa gitlänk %s" @@ -3332,38 +3592,38 @@ msgstr "Kunde inte skapa gitlänk %s" #. * existing" or "Initialized empty", the second " shared" or #. * "", and the last '%s%s' is the verbatim directory name. #. -#: builtin/init-db.c:419 +#: builtin/init-db.c:420 #, c-format msgid "%s%s Git repository in %s%s\n" msgstr "%s%s Git-arkiv i %s%s\n" -#: builtin/init-db.c:420 +#: builtin/init-db.c:421 msgid "Reinitialized existing" msgstr "Ominitierade befintligt" -#: builtin/init-db.c:420 +#: builtin/init-db.c:421 msgid "Initialized empty" msgstr "Initierade tomt" -#: builtin/init-db.c:421 +#: builtin/init-db.c:422 msgid " shared" msgstr " delat" -#: builtin/init-db.c:440 +#: builtin/init-db.c:441 msgid "cannot tell cwd" msgstr "kan inte läsa aktuell katalog (cwd)" -#: builtin/init-db.c:521 builtin/init-db.c:528 +#: builtin/init-db.c:522 builtin/init-db.c:529 #, c-format msgid "cannot mkdir %s" msgstr "kan inte skapa katalogen (mkdir) %s" -#: builtin/init-db.c:532 +#: builtin/init-db.c:533 #, c-format msgid "cannot chdir to %s" msgstr "kan inte byta katalog (chdir) till %s" -#: builtin/init-db.c:554 +#: builtin/init-db.c:555 #, c-format msgid "" "%s (or --work-tree=) not allowed without specifying %s (or --git-" @@ -3372,11 +3632,11 @@ msgstr "" "%s (eller --work-tree=) inte tillåtet utan att ange %s (eller --git-" "dir=)" -#: builtin/init-db.c:578 +#: builtin/init-db.c:579 msgid "Cannot access current working directory" msgstr "Kan inte komma åt aktuell arbetskatalog" -#: builtin/init-db.c:585 +#: builtin/init-db.c:586 #, c-format msgid "Cannot access work tree '%s'" msgstr "Kan inte komma åt arbetskatalogen \"%s\"" @@ -3386,95 +3646,95 @@ msgstr "Kan inte komma åt arbetskatalogen \"%s\"" msgid "Final output: %d %s\n" msgstr "Slututdata: %d %s\n" -#: builtin/log.c:402 builtin/log.c:490 +#: builtin/log.c:403 builtin/log.c:494 #, c-format msgid "Could not read object %s" msgstr "Kunde inte läsa objektet %s" -#: builtin/log.c:514 +#: builtin/log.c:518 #, c-format msgid "Unknown type: %d" msgstr "Okänd typ: %d" -#: builtin/log.c:603 +#: builtin/log.c:608 msgid "format.headers without value" msgstr "format.headers utan värde" -#: builtin/log.c:677 +#: builtin/log.c:682 msgid "name of output directory is too long" msgstr "namnet på utdatakatalogen är för långt" -#: builtin/log.c:688 +#: builtin/log.c:693 #, c-format msgid "Cannot open patch file %s" msgstr "Kan inte öppna patchfilen %s" -#: builtin/log.c:702 +#: builtin/log.c:707 msgid "Need exactly one range." msgstr "Behöver precis ett intervall." -#: builtin/log.c:710 +#: builtin/log.c:715 msgid "Not a range." msgstr "Inte ett intervall." -#: builtin/log.c:787 +#: builtin/log.c:792 msgid "Cover letter needs email format" msgstr "Omslagsbrevet behöver e-postformat" -#: builtin/log.c:860 +#: builtin/log.c:865 #, c-format msgid "insane in-reply-to: %s" msgstr "tokigt in-reply-to: %s" -#: builtin/log.c:933 +#: builtin/log.c:938 msgid "Two output directories?" msgstr "Två utdatakataloger?" -#: builtin/log.c:1154 +#: builtin/log.c:1160 #, c-format msgid "bogus committer info %s" msgstr "felaktig incheckarinformation %s" -#: builtin/log.c:1199 +#: builtin/log.c:1205 msgid "-n and -k are mutually exclusive." msgstr "-n och -k kan inte användas samtidigt." -#: builtin/log.c:1201 +#: builtin/log.c:1207 msgid "--subject-prefix and -k are mutually exclusive." msgstr "--subject-prefix och -k kan inte användas samtidigt." -#: builtin/log.c:1209 +#: builtin/log.c:1215 msgid "--name-only does not make sense" msgstr "kan inte använda --name-only" -#: builtin/log.c:1211 +#: builtin/log.c:1217 msgid "--name-status does not make sense" msgstr "kan inte använda --name-status" -#: builtin/log.c:1213 +#: builtin/log.c:1219 msgid "--check does not make sense" msgstr "kan inte använda --check" -#: builtin/log.c:1236 +#: builtin/log.c:1242 msgid "standard output, or directory, which one?" msgstr "standard ut, eller katalog, vilken skall det vara?" -#: builtin/log.c:1238 +#: builtin/log.c:1244 #, c-format msgid "Could not create directory '%s'" msgstr "Kunde inte skapa katalogen \"%s\"" -#: builtin/log.c:1391 +#: builtin/log.c:1397 msgid "Failed to create output files" msgstr "Misslyckades skapa utdatafiler" -#: builtin/log.c:1495 +#: builtin/log.c:1501 #, c-format msgid "" "Could not find a tracked remote branch, please specify manually.\n" msgstr "Kunde inte hitta en spårad fjärrgren, ange manuellt.\n" -#: builtin/log.c:1511 builtin/log.c:1513 builtin/log.c:1525 +#: builtin/log.c:1517 builtin/log.c:1519 builtin/log.c:1531 #, c-format msgid "Unknown commit %s" msgstr "Okänd incheckning %s" @@ -3555,10 +3815,6 @@ msgstr "git write-tree misslyckades skriva ett träd" msgid "failed to read the cache" msgstr "misslyckads läsa cachen" -#: builtin/merge.c:697 -msgid "Unable to write index." -msgstr "Kunde inte skriva indexet." - #: builtin/merge.c:710 msgid "Not handling anything other than two heads merge." msgstr "Hanterar inte något annat än en sammanslagning av två huvuden." @@ -4590,31 +4846,31 @@ msgstr "Oköade ändringar efter återställning:" msgid "Cannot do a %s reset in the middle of a merge." msgstr "Kan inte utföra en %s återställning mitt i en sammanslagning." -#: builtin/reset.c:297 +#: builtin/reset.c:303 #, c-format msgid "Could not parse object '%s'." msgstr "Kan inte tolka objektet \"%s\"" -#: builtin/reset.c:302 +#: builtin/reset.c:308 msgid "--patch is incompatible with --{hard,mixed,soft}" msgstr "--patch är inkompatibel med --{hard,mixed,soft}" -#: builtin/reset.c:311 +#: builtin/reset.c:317 msgid "--mixed with paths is deprecated; use 'git reset -- ' instead." msgstr "" "--mixed rekommenderas inte med sökvägar; använd \"git reset -- \"." -#: builtin/reset.c:313 +#: builtin/reset.c:319 #, c-format msgid "Cannot do %s reset with paths." msgstr "Kan inte göra %s återställning med sökvägar." -#: builtin/reset.c:325 +#: builtin/reset.c:331 #, c-format msgid "%s reset is not allowed in a bare repository" msgstr "%s återställning tillåts inte i ett naket arkiv" -#: builtin/reset.c:341 +#: builtin/reset.c:347 #, c-format msgid "Could not reset index file to revision '%s'." msgstr "Kunde inte återställa indexfilen till versionen \"%s\"." @@ -4936,7 +5192,7 @@ msgstr "Visa status för arbetskatalogen" #: common-cmds.h:28 msgid "Create, list, delete or verify a tag object signed with GPG" -msgstr "Skapa, visa, ta bort eller verifiera ett taggobjekt signerat med GPG" +msgstr "Skapa, visa, ta bort eller verifiera GPG-signerat taggobjekt" #: git-am.sh:50 msgid "You need to set your committer info first" @@ -4953,9 +5209,9 @@ msgstr "" #: git-am.sh:105 #, sh-format msgid "" -"When you have resolved this problem run \"$cmdline --resolved\".\n" -"If you would prefer to skip this patch, instead run \"$cmdline --skip\".\n" -"To restore the original branch and stop patching run \"$cmdline --abort\"." +"When you have resolved this problem, run \"$cmdline --resolved\".\n" +"If you prefer to skip this patch, run \"$cmdline --skip\" instead.\n" +"To restore the original branch and stop patching, run \"$cmdline --abort\"." msgstr "" "När du har löst problemet kör du \"$cmdline --resolved\".\n" "Om du vill hoppa över patchen kör du istället \"$cmdline --skip\".\n" @@ -4971,6 +5227,10 @@ msgstr "" "Arkivet saknar objekt som behövs för att falla tillbaka på 3-" "vägssammanslagning." +#: git-am.sh:139 +msgid "Using index info to reconstruct a base tree..." +msgstr "Använder indexinfo för att åteskapa ett basträd..." + #: git-am.sh:154 msgid "" "Did you hand edit your patch?\n" @@ -4984,42 +5244,50 @@ msgid "Falling back to patching base and 3-way merge..." msgstr "" "Faller tillbaka på att pacha grundversionen och trevägssammanslagning..." -#: git-am.sh:275 +#: git-am.sh:179 +msgid "Failed to merge in the changes." +msgstr "Misslyckads slå ihop ändringarna." + +#: git-am.sh:274 msgid "Only one StGIT patch series can be applied at once" msgstr "Endast en StGIT-patchserie kan tillämpas åt gången" -#: git-am.sh:362 +#: git-am.sh:361 #, sh-format msgid "Patch format $patch_format is not supported." msgstr "Patchformatet $patch_format stöds inte." -#: git-am.sh:364 +#: git-am.sh:363 msgid "Patch format detection failed." msgstr "Misslyckades detektera patchformat." -#: git-am.sh:418 -msgid "-d option is no longer supported. Do not use." -msgstr "Flaggan -d stöds inte lägre. Använd inte." +#: git-am.sh:389 +msgid "" +"The -b/--binary option has been a no-op for long time, and\n" +"it will be removed. Please do not use it anymore." +msgstr "" +"Flaggan -b/--binary har varit utan funktion länge, och\n" +"kommer tas bort. Vi ber dig att inte använda den längre." -#: git-am.sh:481 +#: git-am.sh:477 #, sh-format msgid "previous rebase directory $dotest still exists but mbox given." msgstr "tidigare rebase-katalog $dotest finns fortfarande, men mbox angavs." -#: git-am.sh:486 +#: git-am.sh:482 msgid "Please make up your mind. --skip or --abort?" msgstr "Bestäm dig. --skip eller --abort?" -#: git-am.sh:513 +#: git-am.sh:509 msgid "Resolve operation not in progress, we are not resuming." msgstr "Lösningsoperation pågår inte, vi återupptar inte." -#: git-am.sh:579 +#: git-am.sh:575 #, sh-format msgid "Dirty index: cannot apply patches (dirty: $files)" msgstr "Smutsigt index: kan inte tillämpa patchar (smutsiga: $files)" -#: git-am.sh:671 +#: git-am.sh:679 #, sh-format msgid "" "Patch is empty. Was it split wrong?\n" @@ -5030,32 +5298,32 @@ msgstr "" "Om du vill hoppa över patchen kör du istället \"$cmdline --skip\".\n" "För att återställa originalgrenen och avbryta kör du \"$cmdline --abort\"." -#: git-am.sh:708 +#: git-am.sh:706 msgid "Patch does not have a valid e-mail address." msgstr "Patchen har inte någon giltig e-postadress." -#: git-am.sh:755 +#: git-am.sh:753 msgid "cannot be interactive without stdin connected to a terminal." msgstr "" "kan inte vara interaktiv om standard in inte är ansluten till en terminal." -#: git-am.sh:759 +#: git-am.sh:757 msgid "Commit Body is:" msgstr "Incheckningskroppen är:" #. TRANSLATORS: Make sure to include [y], [n], [e], [v] and [a] #. in your translation. The program will only accept English #. input at this point. -#: git-am.sh:766 +#: git-am.sh:764 msgid "Apply? [y]es/[n]o/[e]dit/[v]iew patch/[a]ccept all " msgstr "Tillämpa? Y=ja/N=nej/E=redigera/V=visa patch/A=godta alla " -#: git-am.sh:802 +#: git-am.sh:800 #, sh-format msgid "Applying: $FIRSTLINE" msgstr "Tillämpar: $FIRSTLINE" -#: git-am.sh:823 +#: git-am.sh:821 msgid "" "No changes - did you forget to use 'git add'?\n" "If there is nothing left to stage, chances are that something else\n" @@ -5065,7 +5333,7 @@ msgstr "" "Om det inte är något kvar att köa kan det hända att något annat redan\n" "introducerat samma ändringar; kanske du bör hoppa över patchen." -#: git-am.sh:831 +#: git-am.sh:829 msgid "" "You still have unmerged paths in your index\n" "did you forget to use 'git add'?" @@ -5073,16 +5341,16 @@ msgstr "" "Du har fortfarande sökvägar som inte slagits samman i ditt index\n" "glömde du använda \"git add\"?" -#: git-am.sh:847 +#: git-am.sh:845 msgid "No changes -- Patch already applied." msgstr "Inga ändringar -- Patchen har redan tillämpats." -#: git-am.sh:857 +#: git-am.sh:855 #, sh-format msgid "Patch failed at $msgnum $FIRSTLINE" msgstr "Patchen misslyckades vid $msgnum $FIRSTLINE" -#: git-am.sh:873 +#: git-am.sh:876 msgid "applying to an empty history" msgstr "tillämpar på en tom historik" @@ -5285,6 +5553,126 @@ msgstr "Kan inte slå ihop flera grenar i ett tomt huvud." msgid "Cannot rebase onto multiple branches" msgstr "Kan inte utföra en \"rebase\" ovanpå flera grenar" +#: git-rebase.sh:52 +msgid "" +"When you have resolved this problem, run \"git rebase --continue\".\n" +"If you prefer to skip this patch, run \"git rebase --skip\" instead.\n" +"To check out the original branch and stop rebasing, run \"git rebase --abort" +"\"." +msgstr "" +"När du har löst problemet kör du \"git rebase --continue\".\n" +"Om du vill hoppa över patchen kör du istället \"git rebase --skip\".\n" +"För att återställa originalgrenen och avbryta kör du \"git rebase --abort\"." + +#: git-rebase.sh:159 +msgid "The pre-rebase hook refused to rebase." +msgstr "Kroken pre-rebase vägrade ombaseringen." + +#: git-rebase.sh:164 +msgid "It looks like git-am is in progress. Cannot rebase." +msgstr "Det verkar som en git-am körs. Kan inte ombasera." + +#: git-rebase.sh:295 +msgid "The --exec option must be used with the --interactive option" +msgstr "Flaggan --exec måste användas tillsammans med flaggan --interactive" + +#: git-rebase.sh:300 +msgid "No rebase in progress?" +msgstr "Ingen ombasering pågår?" + +#: git-rebase.sh:313 +msgid "Cannot read HEAD" +msgstr "Kan inte läsa HEAD" + +#: git-rebase.sh:316 +msgid "" +"You must edit all merge conflicts and then\n" +"mark them as resolved using git add" +msgstr "" +"Du måste redigera alla sammanslagningskonflikter och\n" +"därefter markera dem som lösta med git add" + +#: git-rebase.sh:334 +#, sh-format +msgid "Could not move back to $head_name" +msgstr "Kunde inte flytta tillbaka till $head_name" + +#: git-rebase.sh:350 +#, sh-format +msgid "" +"It seems that there is already a $state_dir_base directory, and\n" +"I wonder if you are in the middle of another rebase. If that is the\n" +"case, please try\n" +"\t$cmd_live_rebase\n" +"If that is not the case, please\n" +"\t$cmd_clear_stale_rebase\n" +"and run me again. I am stopping in case you still have something\n" +"valuable there." +msgstr "" +"Det verkar som katalogen $state_dir_base redan existerar, och\n" +"jag undrar om du redan är mitt i en annan ombasering. Om så är\n" +"fallet, försök\n" +"\t$cmd_live_rebase\n" +"Om så inte är fallet, kör\n" +"\t$cmd_clear_stale_rebase\n" +"och kör programmet igen. Jag avslutar ifall du fortfarande har\n" +"något av värde där." + +#: git-rebase.sh:395 +#, sh-format +msgid "invalid upstream $upstream_name" +msgstr "ogiltig uppström $upstream_name" + +#: git-rebase.sh:419 +#, sh-format +msgid "$onto_name: there are more than one merge bases" +msgstr "$onto_name: mer än en sammanslagningsbas finns" + +#: git-rebase.sh:422 git-rebase.sh:426 +#, sh-format +msgid "$onto_name: there is no merge base" +msgstr "$onto_name: ingen sammanslagningsbas finns" + +#: git-rebase.sh:431 +#, sh-format +msgid "Does not point to a valid commit: $onto_name" +msgstr "Peka på en giltig incheckning: $onto_name" + +#: git-rebase.sh:454 +#, sh-format +msgid "fatal: no such branch: $branch_name" +msgstr "ödesdigert: ingen sådan gren: $branch_name" + +#: git-rebase.sh:474 +msgid "Please commit or stash them." +msgstr "Checka in eller använd \"stash\" på dem." + +#: git-rebase.sh:492 +#, sh-format +msgid "Current branch $branch_name is up to date." +msgstr "Aktuell gren $branch_name är à jour." + +#: git-rebase.sh:495 +#, sh-format +msgid "Current branch $branch_name is up to date, rebase forced." +msgstr "Aktuell gren $branch_name är à jour, ombasering framtvingad." + +#: git-rebase.sh:506 +#, sh-format +msgid "Changes from $mb to $onto:" +msgstr "Ändringar från $mb till $onto:" + +#. Detach HEAD and reset the tree +#: git-rebase.sh:515 +msgid "First, rewinding head to replay your work on top of it..." +msgstr "" +"Först, spolar tillbaka huvudet för att spela av ditt arbete ovanpå det..." + +#: git-rebase.sh:523 +#, sh-format +msgid "Fast-forwarded $branch_name to $onto_name." +msgstr "Snabbspolade $branch_name till $onto_name." + #: git-stash.sh:51 msgid "git stash clear with parameters is unimplemented" msgstr "\"git stash clear\" med parametrar har inte implementerats" @@ -5425,27 +5813,27 @@ msgid "No submodule mapping found in .gitmodules for path '$sm_path'" msgstr "" "Hittade ingen undermodulmappning i .gitmodules för sökvägen \"$sm_path\"" -#: git-submodule.sh:186 +#: git-submodule.sh:189 #, sh-format msgid "Clone of '$url' into submodule path '$sm_path' failed" msgstr "Misslyckades klona \"$url\" till undermodulsökvägen \"$sm_path\"" -#: git-submodule.sh:196 +#: git-submodule.sh:201 #, sh-format msgid "Gitdir '$a' is part of the submodule path '$b' or vice versa" msgstr "Gitkatalog \"$a\" ingår i underkatalogsökvägen \"$b\" eller omvänt" -#: git-submodule.sh:285 +#: git-submodule.sh:290 #, sh-format msgid "repo URL: '$repo' must be absolute or begin with ./|../" msgstr "arkiv-URL: \"$repo\" måste vara absolut eller börja med ./|../" -#: git-submodule.sh:302 +#: git-submodule.sh:307 #, sh-format msgid "'$sm_path' already exists in the index" msgstr "\"$sm_path\" finns redan i indexet" -#: git-submodule.sh:306 +#: git-submodule.sh:311 #, sh-format msgid "" "The following path is ignored by one of your .gitignore files:\n" @@ -5456,64 +5844,64 @@ msgstr "" "$sm_path\n" "Använd -f om du verkligen vill lägga till den" -#: git-submodule.sh:317 +#: git-submodule.sh:322 #, sh-format msgid "Adding existing repo at '$sm_path' to the index" msgstr "Lägger till befintligt arkiv i \"$sm_path\" i indexet" -#: git-submodule.sh:319 +#: git-submodule.sh:324 #, sh-format msgid "'$sm_path' already exists and is not a valid git repo" msgstr "\"$sm_path\" finns redan och är inte ett giltigt git-arkiv" -#: git-submodule.sh:333 +#: git-submodule.sh:338 #, sh-format msgid "Unable to checkout submodule '$sm_path'" msgstr "Kan inte checka ut undermodulen \"$sm_path\"" -#: git-submodule.sh:338 +#: git-submodule.sh:343 #, sh-format msgid "Failed to add submodule '$sm_path'" msgstr "Misslyckades lägga till undermodulen \"$sm_path\"" -#: git-submodule.sh:343 +#: git-submodule.sh:348 #, sh-format msgid "Failed to register submodule '$sm_path'" msgstr "Misslyckades registrera undermodulen \"$sm_path\"" -#: git-submodule.sh:385 +#: git-submodule.sh:390 #, sh-format msgid "Entering '$prefix$sm_path'" msgstr "Går in i \"$prefix$sm_path\"" -#: git-submodule.sh:399 +#: git-submodule.sh:404 #, sh-format msgid "Stopping at '$sm_path'; script returned non-zero status." msgstr "" "Stoppar på \"$sm_path\"; skriptet returnerade en status skild från noll." -#: git-submodule.sh:442 +#: git-submodule.sh:447 #, sh-format msgid "No url found for submodule path '$sm_path' in .gitmodules" msgstr "Hittade ingen url för undermodulsökvägen \"$sm_path\" i .gitmodules" -#: git-submodule.sh:451 +#: git-submodule.sh:456 #, sh-format msgid "Failed to register url for submodule path '$sm_path'" msgstr "Misslyckades registrera url för underkatalogsökväg \"$sm_path\"" -#: git-submodule.sh:453 +#: git-submodule.sh:458 #, sh-format msgid "Submodule '$name' ($url) registered for path '$sm_path'" msgstr "Undermodulen \"$name\" ($url) registrerad för sökvägen \"$sm_path\"" -#: git-submodule.sh:461 +#: git-submodule.sh:466 #, sh-format msgid "Failed to register update mode for submodule path '$sm_path'" msgstr "" "Misslyckades registrera uppdateringsläge för undermodulsökväg \"$sm_path\"" -#: git-submodule.sh:560 +#: git-submodule.sh:565 #, sh-format msgid "" "Submodule path '$sm_path' not initialized\n" @@ -5522,97 +5910,102 @@ msgstr "" "Undermodulen \"$sm_path\" har inte initierats\n" "Kanske du vill köra \"update --init\"?" -#: git-submodule.sh:573 +#: git-submodule.sh:578 #, sh-format msgid "Unable to find current revision in submodule path '$sm_path'" msgstr "Kan inte hitta aktuell revision i undermodulsökväg \"$sm_path\"" -#: git-submodule.sh:592 +#: git-submodule.sh:597 #, sh-format msgid "Unable to fetch in submodule path '$sm_path'" msgstr "Kan inte hämta i undermodulsökväg \"$sm_path\"" -#: git-submodule.sh:606 +#: git-submodule.sh:611 #, sh-format msgid "Unable to rebase '$sha1' in submodule path '$sm_path'" msgstr "Kan inte ombasera \"$sha1\" i undermodulsökväg \"$sm_path\"" -#: git-submodule.sh:607 +#: git-submodule.sh:612 #, sh-format msgid "Submodule path '$sm_path': rebased into '$sha1'" msgstr "Undermodulsökvägen \"$sm_path\": ombaserade in i \"$sha1\"" -#: git-submodule.sh:612 +#: git-submodule.sh:617 #, sh-format msgid "Unable to merge '$sha1' in submodule path '$sm_path'" msgstr "Kan inte slå ihop \"$sha1\" i undermodulsökvägen \"$sm_path\"" -#: git-submodule.sh:613 +#: git-submodule.sh:618 #, sh-format msgid "Submodule path '$sm_path': merged in '$sha1'" msgstr "Undermodulsökvägen \"$sm_path\": sammanslagen i \"$sha1\"" -#: git-submodule.sh:618 +#: git-submodule.sh:623 #, sh-format msgid "Unable to checkout '$sha1' in submodule path '$sm_path'" msgstr "Kan inte checka ut \"$sha1\" i undermodulsökvägen \"$sm_path\"" -#: git-submodule.sh:619 +#: git-submodule.sh:624 #, sh-format msgid "Submodule path '$sm_path': checked out '$sha1'" msgstr "Undermodulsökvägen \"$sm_path\": checkade ut \"$sha1\"" -#: git-submodule.sh:641 git-submodule.sh:964 +#: git-submodule.sh:646 git-submodule.sh:969 #, sh-format msgid "Failed to recurse into submodule path '$sm_path'" msgstr "Misslyckades rekursera in i undermodulsökvägen \"$sm_path\"" -#: git-submodule.sh:749 -msgid "--cached cannot be used with --files" -msgstr "--cached kan inte användas med --files" +#: git-submodule.sh:754 +msgid "The --cached option cannot be used with the --files option" +msgstr "Flaggan --cached kan inte användas med flaggan --files" #. unexpected type -#: git-submodule.sh:789 +#: git-submodule.sh:794 #, sh-format msgid "unexpected mode $mod_dst" msgstr "oväntat läge $mod_dst" -#: git-submodule.sh:807 +#: git-submodule.sh:812 #, sh-format msgid " Warn: $name doesn't contain commit $sha1_src" msgstr " Varning: $name innehåller inte incheckning $sha1_src" -#: git-submodule.sh:810 +#: git-submodule.sh:815 #, sh-format msgid " Warn: $name doesn't contain commit $sha1_dst" msgstr " Varning: $name innehåller inte incheckning $sha1_dst" -#: git-submodule.sh:813 +#: git-submodule.sh:818 #, sh-format msgid " Warn: $name doesn't contain commits $sha1_src and $sha1_dst" msgstr " Varning: $name innehåller inte incheckningar $sha1_src och $sha1_dst" -#: git-submodule.sh:838 +#: git-submodule.sh:843 msgid "blob" msgstr "blob" -#: git-submodule.sh:839 -msgid "submodule" -msgstr "undermodul" - -#: git-submodule.sh:876 +#: git-submodule.sh:881 msgid "# Submodules changed but not updated:" msgstr "# Undermoduler ändrade men inte uppdaterade:" -#: git-submodule.sh:878 +#: git-submodule.sh:883 msgid "# Submodule changes to be committed:" msgstr "# Undermodulers ändringar att checka in:" -#: git-submodule.sh:1022 +#: git-submodule.sh:1027 #, sh-format msgid "Synchronizing submodule url for '$name'" msgstr "Synkroniserar undermodul-url för \"$name\"" +#~ msgid "%s: has been deleted/renamed" +#~ msgstr "%s: har tagits bort/ändrat namn" + +#~ msgid "'%s': not a documentation directory." +#~ msgstr "\"%s\": inte en dokumentationskatalog." + +#~ msgid "-d option is no longer supported. Do not use." +#~ msgstr "Flaggan -d stöds inte lägre. Använd inte." + #~ msgid "cherry-pick" #~ msgstr "cherry-pick" diff --git a/po/vi.po b/po/vi.po index e411088902..f2c77ec33f 100644 --- a/po/vi.po +++ b/po/vi.po @@ -5,10 +5,10 @@ # msgid "" msgstr "" -"Project-Id-Version: git-1.7.12.rc0.91.g338ecb7\n" +"Project-Id-Version: git-1.7.12-rc1-18-ge0453\n" "Report-Msgid-Bugs-To: Git Mailing List \n" -"POT-Creation-Date: 2012-08-02 09:26+0800\n" -"PO-Revision-Date: 2012-08-03 14:05+0700\n" +"POT-Creation-Date: 2012-08-06 23:47+0800\n" +"PO-Revision-Date: 2012-08-07 07:11+0700\n" "Last-Translator: Trần Ngọc Quân \n" "Language-Team: Vietnamese \n" "MIME-Version: 1.0\n" @@ -595,21 +595,23 @@ msgstr "Đường dẫn chưa được xử lý??? %s" msgid "Merging:" msgstr "Đang trộn:" -#: merge-recursive.c:1918 +#: merge-recursive.c:1920 #, c-format -msgid "found %u common ancestor(s):" -msgstr "tìm thấy %u tổ tiên chung:" +msgid "found %u common ancestor:" +msgid_plural "found %u common ancestors:" +msgstr[0] "tìm thấy %u tổ tiên chung:" +msgstr[1] "tìm thấy %u tổ tiên chung:" -#: merge-recursive.c:1954 +#: merge-recursive.c:1957 msgid "merge returned no commit" msgstr "hòa trộn không trả về lần chuyển giao (commit) nào" -#: merge-recursive.c:2011 +#: merge-recursive.c:2014 #, c-format msgid "Could not parse object '%s'" msgstr "Không thể phân tích đối tượng '%s'" -#: merge-recursive.c:2023 +#: merge-recursive.c:2026 #: builtin/merge.c:697 msgid "Unable to write index." msgstr "Không thể ghi bảng mục lục" diff --git a/po/zh_CN.po b/po/zh_CN.po index 6547c0acb4..bc04236e47 100644 --- a/po/zh_CN.po +++ b/po/zh_CN.po @@ -12,8 +12,8 @@ msgid "" msgstr "" "Project-Id-Version: Git\n" "Report-Msgid-Bugs-To: Git Mailing List \n" -"POT-Creation-Date: 2012-08-02 09:26+0800\n" -"PO-Revision-Date: 2012-08-05 07:08+0800\n" +"POT-Creation-Date: 2012-08-06 23:47+0800\n" +"PO-Revision-Date: 2012-08-07 01:07+0800\n" "Last-Translator: Jiang Xin \n" "Language-Team: GitHub \n" "Language: zh_CN\n" @@ -594,21 +594,23 @@ msgstr "未处理的路径??? %s" msgid "Merging:" msgstr "合并:" -#: merge-recursive.c:1918 +#: merge-recursive.c:1920 #, c-format -msgid "found %u common ancestor(s):" -msgstr "发现 %u 个共同祖先:" +msgid "found %u common ancestor:" +msgid_plural "found %u common ancestors:" +msgstr[0] "发现 %u 个共同祖先:" +msgstr[1] "发现 %u 个共同祖先:" -#: merge-recursive.c:1954 +#: merge-recursive.c:1957 msgid "merge returned no commit" msgstr "合并未返回提交" -#: merge-recursive.c:2011 +#: merge-recursive.c:2014 #, c-format msgid "Could not parse object '%s'" msgstr "不能解析对象 '%s'" -#: merge-recursive.c:2023 builtin/merge.c:697 +#: merge-recursive.c:2026 builtin/merge.c:697 msgid "Unable to write index." msgstr "不能写入索引。" diff --git a/read-cache.c b/read-cache.c index 2f8159fb16..d2be78ea95 100644 --- a/read-cache.c +++ b/read-cache.c @@ -1800,6 +1800,8 @@ int write_index(struct index_state *istate, int newfd) continue; if (!ce_uptodate(ce) && is_racy_timestamp(istate, ce)) ce_smudge_racily_clean_entry(ce); + if (is_null_sha1(ce->sha1)) + return error("cache entry has null sha1: %s", ce->name); if (ce_write_entry(&c, newfd, ce, previous_name) < 0) return -1; } diff --git a/revision.c b/revision.c index 9e8f47a25d..04c7de87d0 100644 --- a/revision.c +++ b/revision.c @@ -345,6 +345,7 @@ static int tree_difference = REV_TREE_SAME; static void file_add_remove(struct diff_options *options, int addremove, unsigned mode, const unsigned char *sha1, + int sha1_valid, const char *fullpath, unsigned dirty_submodule) { int diff = addremove == '+' ? REV_TREE_NEW : REV_TREE_OLD; @@ -358,6 +359,7 @@ static void file_change(struct diff_options *options, unsigned old_mode, unsigned new_mode, const unsigned char *old_sha1, const unsigned char *new_sha1, + int old_sha1_valid, int new_sha1_valid, const char *fullpath, unsigned old_dirty_submodule, unsigned new_dirty_submodule) { diff --git a/setup.c b/setup.c index 9139beefc7..3a1b2fd455 100644 --- a/setup.c +++ b/setup.c @@ -79,7 +79,7 @@ static void NORETURN die_verify_filename(const char *prefix, { if (!diagnose_misspelt_rev) die("%s: no such path in the working tree.\n" - "Use '-- ...' to specify paths that do not exist locally.", + "Use 'git -- ...' to specify paths that do not exist locally.", arg); /* * Saying "'(icase)foo' does not exist in the index" when the @@ -92,7 +92,8 @@ static void NORETURN die_verify_filename(const char *prefix, /* ... or fall back the most general message. */ die("ambiguous argument '%s': unknown revision or path not in the working tree.\n" - "Use '--' to separate paths from revisions", arg); + "Use '--' to separate paths from revisions, like this:\n" + "'git [...] -- [...]'", arg); } @@ -141,7 +142,8 @@ void verify_non_filename(const char *prefix, const char *arg) if (!check_filename(prefix, arg)) return; die("ambiguous argument '%s': both revision and filename\n" - "Use '--' to separate filenames from revisions", arg); + "Use '--' to separate paths from revisions, like this:\n" + "'git [...] -- [...]'", arg); } /* diff --git a/t/perf/perf-lib.sh b/t/perf/perf-lib.sh index 5580c22812..a1361e530c 100644 --- a/t/perf/perf-lib.sh +++ b/t/perf/perf-lib.sh @@ -163,7 +163,7 @@ test_perf () { else echo "perf $test_count - $1:" fi - for i in $(seq 1 $GIT_PERF_REPEAT_COUNT); do + for i in $(test_seq 1 $GIT_PERF_REPEAT_COUNT); do say >&3 "running: $2" if test_run_perf_ "$2" then diff --git a/t/t1450-fsck.sh b/t/t1450-fsck.sh index 5b79c51b8c..bf7a2cd6fb 100755 --- a/t/t1450-fsck.sh +++ b/t/t1450-fsck.sh @@ -213,4 +213,30 @@ test_expect_success 'rev-list --verify-objects with bad sha1' ' grep -q "error: sha1 mismatch 63ffffffffffffffffffffffffffffffffffffff" out ' +_bz='\0' +_bz5="$_bz$_bz$_bz$_bz$_bz" +_bz20="$_bz5$_bz5$_bz5$_bz5" + +test_expect_success 'fsck notices blob entry pointing to null sha1' ' + (git init null-blob && + cd null-blob && + sha=$(printf "100644 file$_bz$_bz20" | + git hash-object -w --stdin -t tree) && + git fsck 2>out && + cat out && + grep "warning.*null sha1" out + ) +' + +test_expect_success 'fsck notices submodule entry pointing to null sha1' ' + (git init null-commit && + cd null-commit && + sha=$(printf "160000 submodule$_bz$_bz20" | + git hash-object -w --stdin -t tree) && + git fsck 2>out && + cat out && + grep "warning.*null sha1" out + ) +' + test_done diff --git a/t/t2107-update-index-basic.sh b/t/t2107-update-index-basic.sh index 809fafe208..0dbbb00d74 100755 --- a/t/t2107-update-index-basic.sh +++ b/t/t2107-update-index-basic.sh @@ -29,4 +29,23 @@ test_expect_success 'update-index -h with corrupt index' ' grep "[Uu]sage: git update-index" broken/usage ' +test_expect_success '--cacheinfo does not accept blob null sha1' ' + echo content >file && + git add file && + git rev-parse :file >expect && + test_must_fail git update-index --cacheinfo 100644 $_z40 file && + git rev-parse :file >actual && + test_cmp expect actual +' + +test_expect_success '--cacheinfo does not accept gitlink null sha1' ' + git init submodule && + (cd submodule && test_commit foo) && + git add submodule && + git rev-parse :submodule >expect && + test_must_fail git update-index --cacheinfo 160000 $_z40 submodule && + git rev-parse :submodule >actual && + test_cmp expect actual +' + test_done diff --git a/t/t4054-diff-bogus-tree.sh b/t/t4054-diff-bogus-tree.sh new file mode 100755 index 0000000000..0843c87890 --- /dev/null +++ b/t/t4054-diff-bogus-tree.sh @@ -0,0 +1,83 @@ +#!/bin/sh + +test_description='test diff with a bogus tree containing the null sha1' +. ./test-lib.sh + +empty_tree=4b825dc642cb6eb9a060e54bf8d69288fbee4904 + +test_expect_success 'create bogus tree' ' + bogus_tree=$( + printf "100644 fooQQQQQQQQQQQQQQQQQQQQQ" | + q_to_nul | + git hash-object -w --stdin -t tree + ) +' + +test_expect_success 'create tree with matching file' ' + echo bar >foo && + git add foo && + good_tree=$(git write-tree) + blob=$(git rev-parse :foo) +' + +test_expect_success 'raw diff shows null sha1 (addition)' ' + echo ":000000 100644 $_z40 $_z40 A foo" >expect && + git diff-tree $empty_tree $bogus_tree >actual && + test_cmp expect actual +' + +test_expect_success 'raw diff shows null sha1 (removal)' ' + echo ":100644 000000 $_z40 $_z40 D foo" >expect && + git diff-tree $bogus_tree $empty_tree >actual && + test_cmp expect actual +' + +test_expect_success 'raw diff shows null sha1 (modification)' ' + echo ":100644 100644 $blob $_z40 M foo" >expect && + git diff-tree $good_tree $bogus_tree >actual && + test_cmp expect actual +' + +test_expect_success 'raw diff shows null sha1 (other direction)' ' + echo ":100644 100644 $_z40 $blob M foo" >expect && + git diff-tree $bogus_tree $good_tree >actual && + test_cmp expect actual +' + +test_expect_success 'raw diff shows null sha1 (reverse)' ' + echo ":100644 100644 $_z40 $blob M foo" >expect && + git diff-tree -R $good_tree $bogus_tree >actual && + test_cmp expect actual +' + +test_expect_success 'raw diff shows null sha1 (index)' ' + echo ":100644 100644 $_z40 $blob M foo" >expect && + git diff-index $bogus_tree >actual && + test_cmp expect actual +' + +test_expect_success 'patch fails due to bogus sha1 (addition)' ' + test_must_fail git diff-tree -p $empty_tree $bogus_tree +' + +test_expect_success 'patch fails due to bogus sha1 (removal)' ' + test_must_fail git diff-tree -p $bogus_tree $empty_tree +' + +test_expect_success 'patch fails due to bogus sha1 (modification)' ' + test_must_fail git diff-tree -p $good_tree $bogus_tree +' + +test_expect_success 'patch fails due to bogus sha1 (other direction)' ' + test_must_fail git diff-tree -p $bogus_tree $good_tree +' + +test_expect_success 'patch fails due to bogus sha1 (reverse)' ' + test_must_fail git diff-tree -R -p $good_tree $bogus_tree +' + +test_expect_success 'patch fails due to bogus sha1 (index)' ' + test_must_fail git diff-index -p $bogus_tree +' + +test_done diff --git a/t/t5400-send-pack.sh b/t/t5400-send-pack.sh index 0eace37a03..250c720c14 100755 --- a/t/t5400-send-pack.sh +++ b/t/t5400-send-pack.sh @@ -145,6 +145,41 @@ test_expect_success 'push --all excludes remote-tracking hierarchy' ' ) ' +test_expect_success 'receive-pack runs auto-gc in remote repo' ' + rm -rf parent child && + git init parent && + ( + # Setup a repo with 2 packs + cd parent && + echo "Some text" >file.txt && + git add . && + git commit -m "Initial commit" && + git repack -adl && + echo "Some more text" >>file.txt && + git commit -a -m "Second commit" && + git repack + ) && + cp -a parent child && + ( + # Set the child to auto-pack if more than one pack exists + cd child && + git config gc.autopacklimit 1 && + git branch test_auto_gc && + # And create a file that follows the temporary object naming + # convention for the auto-gc to remove + : >.git/objects/tmp_test_object && + test-chmtime =-1209601 .git/objects/tmp_test_object + ) && + ( + cd parent && + echo "Even more text" >>file.txt && + git commit -a -m "Third commit" && + git send-pack ../child HEAD:refs/heads/test_auto_gc >output 2>&1 && + grep "Auto packing the repository for optimum performance." output + ) && + test ! -e child/.git/objects/tmp_test_object +' + rewound_push_setup() { rm -rf parent child && mkdir parent && diff --git a/t/t5551-http-fetch.sh b/t/t5551-http-fetch.sh index fadf2f258e..91eaf53d1d 100755 --- a/t/t5551-http-fetch.sh +++ b/t/t5551-http-fetch.sh @@ -114,7 +114,7 @@ test -n "$GIT_TEST_LONG" && test_set_prereq EXPENSIVE test_expect_success EXPENSIVE 'create 50,000 tags in the repo' ' ( cd "$HTTPD_DOCUMENT_ROOT_PATH/repo.git" && - for i in `seq 50000` + for i in `test_seq 50000` do echo "commit refs/heads/too-many-refs" echo "mark :$i" diff --git a/t/t9001-send-email.sh b/t/t9001-send-email.sh index 8c12c65c72..035122808b 100755 --- a/t/t9001-send-email.sh +++ b/t/t9001-send-email.sh @@ -841,6 +841,19 @@ test_expect_success $PREREQ '--compose adds MIME for utf8 subject' ' grep "^Subject: =?UTF-8?q?utf8-s=C3=BCbj=C3=ABct?=" msgtxt1 ' +test_expect_success $PREREQ 'utf8 author is correctly passed on' ' + clean_fake_sendmail && + test_commit weird_author && + test_when_finished "git reset --hard HEAD^" && + git commit --amend --author "Füñný Nâmé " && + git format-patch --stdout -1 >funny_name.patch && + git send-email --from="Example " \ + --to=nobody@example.com \ + --smtp-server="$(pwd)/fake.sendmail" \ + funny_name.patch && + grep "^From: Füñný Nâmé " msgtxt1 +' + test_expect_success $PREREQ 'detects ambiguous reference/file conflict' ' echo master > master && git add master && diff --git a/t/t9163-git-svn-reset-clears-caches.sh b/t/t9163-git-svn-reset-clears-caches.sh new file mode 100755 index 0000000000..cd4c662ba2 --- /dev/null +++ b/t/t9163-git-svn-reset-clears-caches.sh @@ -0,0 +1,78 @@ +#!/bin/sh +# +# Copyright (c) 2012 Peter Baumann +# + +test_description='git svn reset clears memoized caches' +. ./lib-git-svn.sh + +svn_ver="$(svn --version --quiet)" +case $svn_ver in +0.* | 1.[0-4].*) + skip_all="skipping git-svn test - SVN too old ($svn_ver)" + test_done + ;; +esac + +# ... a - b - m <- trunk +# \ / +# ... c <- branch1 +# +# SVN Commits not interesting for this test are abbreviated with "..." +# +test_expect_success 'initialize source svn repo' ' + svn_cmd mkdir -m "create trunk" "$svnrepo"/trunk && + svn_cmd mkdir -m "create branches" "$svnrepo/branches" && + svn_cmd co "$svnrepo"/trunk "$SVN_TREE" && + ( + cd "$SVN_TREE" && + touch foo && + svn_cmd add foo && + svn_cmd commit -m "a" && + svn_cmd cp -m branch "$svnrepo"/trunk "$svnrepo"/branches/branch1 && + svn_cmd switch "$svnrepo"/branches/branch1 && + touch bar && + svn_cmd add bar && + svn_cmd commit -m b && + svn_cmd switch "$svnrepo"/trunk && + touch baz && + svn_cmd add baz && + svn_cmd commit -m c && + svn_cmd up && + svn_cmd merge "$svnrepo"/branches/branch1 && + svn_cmd commit -m "m" + ) && + rm -rf "$SVN_TREE" +' + +test_expect_success 'fetch to merge-base (a)' ' + git svn init -s "$svnrepo" && + git svn fetch --revision BASE:3 +' + +# git svn rebase looses the merge commit +# +# ... a - b - m <- trunk +# \ +# ... c +# +test_expect_success 'rebase looses SVN merge (m)' ' + git svn rebase && + git svn fetch && + test 1 = $(git cat-file -p master|grep parent|wc -l) +' + +# git svn fetch creates correct history with merge commit +# +# ... a - b - m <- trunk +# \ / +# ... c <- branch1 +# +test_expect_success 'reset and fetch gets the SVN merge (m) correctly' ' + git svn reset -r 3 && + git reset --hard trunk && + git svn fetch && + test 2 = $(git cat-file -p trunk|grep parent|wc -l) +' + +test_done diff --git a/t/t9164-git-svn-dcommit-concrrent.sh b/t/t9164-git-svn-dcommit-concrrent.sh new file mode 100755 index 0000000000..aac2ddadf2 --- /dev/null +++ b/t/t9164-git-svn-dcommit-concrrent.sh @@ -0,0 +1,216 @@ +#!/bin/sh +# +# Copyright (c) 2012 Robert Luberda +# + +test_description='concurrent git svn dcommit' +. ./lib-git-svn.sh + + + +test_expect_success 'setup svn repository' ' + svn_cmd checkout "$svnrepo" work.svn && + ( + cd work.svn && + echo >file && echo > auto_updated_file + svn_cmd add file auto_updated_file && + svn_cmd commit -m "initial commit" + ) && + svn_cmd checkout "$svnrepo" work-auto-commits.svn +' +N=0 +next_N() +{ + N=$(( $N + 1 )) +} + +# Setup SVN repository hooks to emulate SVN failures or concurrent commits +# The function adds +# either pre-commit hook, which causes SVN commit given in second argument +# to fail +# or post-commit hook, which creates a new commit (a new line added to +# auto_updated_file) after given SVN commit +# The first argument contains a type of the hook +# The second argument contains a number (not SVN revision) of commit +# the hook should be applied for (each time the hook is run, the given +# number is decreased by one until it gets 0, in which case the hook +# will execute its real action) +setup_hook() +{ + hook_type="$1" # "pre-commit" or "post-commit" + skip_revs="$2" + [ "$hook_type" = "pre-commit" ] || + [ "$hook_type" = "post-commit" ] || + { echo "ERROR: invalid argument ($hook_type)" \ + "passed to setup_hook" >&2 ; return 1; } + echo "cnt=$skip_revs" > "$hook_type-counter" + rm -f "$rawsvnrepo/hooks/"*-commit # drop previous hooks + hook="$rawsvnrepo/hooks/$hook_type" + cat > "$hook" <<- 'EOF1' + #!/bin/sh + set -e + cd "$1/.." # "$1" is repository location + exec >> svn-hook.log 2>&1 + hook="$(basename "$0")" + echo "*** Executing $hook $@" + set -x + . ./$hook-counter + cnt="$(($cnt - 1))" + echo "cnt=$cnt" > ./$hook-counter + [ "$cnt" = "0" ] || exit 0 +EOF1 + if [ "$hook_type" = "pre-commit" ]; then + echo "echo 'commit disallowed' >&2; exit 1" >> "$hook" + else + echo "PATH=\"$PATH\"; export PATH" >> $hook + echo "svnconf=\"$svnconf\"" >> $hook + cat >> "$hook" <<- 'EOF2' + cd work-auto-commits.svn + svn up --config-dir "$svnconf" + echo "$$" >> auto_updated_file + svn commit --config-dir "$svnconf" \ + -m "auto-committing concurrent change" + exit 0 +EOF2 + fi + chmod 755 "$hook" +} + +check_contents() +{ + gitdir="$1" + (cd ../work.svn && svn_cmd up) && + test_cmp file ../work.svn/file && + test_cmp auto_updated_file ../work.svn/auto_updated_file +} + +test_expect_success 'check if post-commit hook creates a concurrent commit' ' + setup_hook post-commit 1 && + ( + cd work.svn && + cp auto_updated_file au_file_saved && + echo 1 >> file && + svn_cmd commit -m "changing file" && + svn_cmd up && + test_must_fail test_cmp auto_updated_file au_file_saved + ) +' + +test_expect_success 'check if pre-commit hook fails' ' + setup_hook pre-commit 2 && + ( + cd work.svn && + echo 2 >> file && + svn_cmd commit -m "changing file once again" && + echo 3 >> file && + test_must_fail svn_cmd commit -m "this commit should fail" && + svn_cmd revert file + ) +' + +test_expect_success 'dcommit error handling' ' + setup_hook pre-commit 2 && + next_N && git svn clone "$svnrepo" work$N.git && + ( + cd work$N.git && + echo 1 >> file && git commit -am "commit change $N.1" && + echo 2 >> file && git commit -am "commit change $N.2" && + echo 3 >> file && git commit -am "commit change $N.3" && + # should fail to dcommit 2nd and 3rd change + # but still should leave the repository in reasonable state + test_must_fail git svn dcommit && + git update-index --refresh && + git show HEAD~2 | grep -q git-svn-id && + ! git show HEAD~1 | grep -q git-svn-id && + ! git show HEAD | grep -q git-svn-id + ) +' + +test_expect_success 'dcommit concurrent change in non-changed file' ' + setup_hook post-commit 2 && + next_N && git svn clone "$svnrepo" work$N.git && + ( + cd work$N.git && + echo 1 >> file && git commit -am "commit change $N.1" && + echo 2 >> file && git commit -am "commit change $N.2" && + echo 3 >> file && git commit -am "commit change $N.3" && + # should rebase and leave the repository in reasonable state + git svn dcommit && + git update-index --refresh && + check_contents && + git show HEAD~3 | grep -q git-svn-id && + git show HEAD~2 | grep -q git-svn-id && + git show HEAD~1 | grep -q auto-committing && + git show HEAD | grep -q git-svn-id + ) +' + +# An utility function used in the following test +delete_first_line() +{ + file="$1" && + sed 1d < "$file" > "${file}.tmp" && + rm "$file" && + mv "${file}.tmp" "$file" +} + +test_expect_success 'dcommit concurrent non-conflicting change' ' + setup_hook post-commit 2 && + next_N && git svn clone "$svnrepo" work$N.git && + ( + cd work$N.git && + cat file >> auto_updated_file && + git commit -am "commit change $N.1" && + delete_first_line auto_updated_file && + git commit -am "commit change $N.2" && + delete_first_line auto_updated_file && + git commit -am "commit change $N.3" && + # should rebase and leave the repository in reasonable state + git svn dcommit && + git update-index --refresh && + check_contents && + git show HEAD~3 | grep -q git-svn-id && + git show HEAD~2 | grep -q git-svn-id && + git show HEAD~1 | grep -q auto-committing && + git show HEAD | grep -q git-svn-id + ) +' + +test_expect_success 'dcommit --no-rebase concurrent non-conflicting change' ' + setup_hook post-commit 2 && + next_N && git svn clone "$svnrepo" work$N.git && + ( + cd work$N.git && + cat file >> auto_updated_file && + git commit -am "commit change $N.1" && + delete_first_line auto_updated_file && + git commit -am "commit change $N.2" && + delete_first_line auto_updated_file && + git commit -am "commit change $N.3" && + # should fail as rebase is needed + test_must_fail git svn dcommit --no-rebase && + # but should leave HEAD unchanged + git update-index --refresh && + ! git show HEAD~2 | grep -q git-svn-id && + ! git show HEAD~1 | grep -q git-svn-id && + ! git show HEAD | grep -q git-svn-id + ) +' + +test_expect_success 'dcommit fails on concurrent conflicting change' ' + setup_hook post-commit 1 && + next_N && git svn clone "$svnrepo" work$N.git && + ( + cd work$N.git && + echo a >> file && + git commit -am "commit change $N.1" && + echo b >> auto_updated_file && + git commit -am "commit change $N.2" && + echo c >> auto_updated_file && + git commit -am "commit change $N.3" && + test_must_fail git svn dcommit && # rebase should fail + test_must_fail git update-index --refresh + ) +' + +test_done diff --git a/t/test-lib-functions.sh b/t/test-lib-functions.sh index 80daaca780..9096398b18 100644 --- a/t/test-lib-functions.sh +++ b/t/test-lib-functions.sh @@ -530,6 +530,27 @@ test_cmp() { $GIT_TEST_CMP "$@" } +# Print a sequence of numbers or letters in increasing order. This is +# similar to GNU seq(1), but the latter might not be available +# everywhere (and does not do letters). It may be used like: +# +# for i in `test_seq 100`; do +# for j in `test_seq 10 20`; do +# for k in `test_seq a z`; do +# echo $i-$j-$k +# done +# done +# done + +test_seq () { + case $# in + 1) set 1 "$@" ;; + 2) ;; + *) error "bug in the test script: not 1 or 2 parameters to test_seq" ;; + esac + "$PERL_PATH" -le 'print for $ARGV[0]..$ARGV[1]' -- "$@" +} + # This function can be used to schedule some commands to be run # unconditionally at the end of the test to restore sanity: # diff --git a/tree-diff.c b/tree-diff.c index 28ad6db9ff..7e5483366e 100644 --- a/tree-diff.c +++ b/tree-diff.c @@ -49,12 +49,12 @@ static int compare_tree_entry(struct tree_desc *t1, struct tree_desc *t2, if (DIFF_OPT_TST(opt, RECURSIVE) && S_ISDIR(mode1)) { if (DIFF_OPT_TST(opt, TREE_IN_RECURSIVE)) { opt->change(opt, mode1, mode2, - sha1, sha2, base->buf, 0, 0); + sha1, sha2, 1, 1, base->buf, 0, 0); } strbuf_addch(base, '/'); diff_tree_sha1(sha1, sha2, base->buf, opt); } else { - opt->change(opt, mode1, mode2, sha1, sha2, base->buf, 0, 0); + opt->change(opt, mode1, mode2, sha1, sha2, 1, 1, base->buf, 0, 0); } strbuf_setlen(base, old_baselen); return 0; @@ -100,7 +100,7 @@ static void show_entry(struct diff_options *opt, const char *prefix, die("corrupt tree sha %s", sha1_to_hex(sha1)); if (DIFF_OPT_TST(opt, TREE_IN_RECURSIVE)) - opt->add_remove(opt, *prefix, mode, sha1, base->buf, 0); + opt->add_remove(opt, *prefix, mode, sha1, 1, base->buf, 0); strbuf_addch(base, '/'); @@ -108,7 +108,7 @@ static void show_entry(struct diff_options *opt, const char *prefix, show_tree(opt, prefix, &inner, base); free(tree); } else - opt->add_remove(opt, prefix[0], mode, sha1, base->buf, 0); + opt->add_remove(opt, prefix[0], mode, sha1, 1, base->buf, 0); strbuf_setlen(base, old_baselen); }