File: git-am

package info (click to toggle)
yash 2.60-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 6,152 kB
  • sloc: ansic: 34,578; makefile: 851; sh: 808; sed: 16
file content (78 lines) | stat: -rw-r--r-- 3,343 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
# (C) 2011-2025 magicant

# Completion script for the "git-am" command.
# Supports Git 2.48.1.

function completion/git-am {
        WORDS=(git am "${WORDS[2,-1]}")
        command -f completion//reexecute
}

function completion/git::am:arg {

        OPTIONS=( #>#
        "--allow-empty; create empty commit for message without patch"
        "--abort; abort patching and restore the original branch"
        "--committer-date-is-author-date; use author date for committer date"
        "r --continue --resolved; commit the current index and continue patching"
        "--empty:; specify how to handle messages without a patch"
        "S:: --gpg-sign::; sign commits using GPG"
        "--ignore-date; use committer date for author date"
        "i --interactive"
        "k --keep; use the mail subject intact as the commit message"
        "--keep-cr; don't remove carriage returns at the end of lines"
        "--keep-non-patch; keep bracketed words in subject except [PATCH]"
        "m --message-id; add message-id to commit message"
        "--no-3way; don't try 3-way merge on conflict"
        "--no-gpg-sign; don't sign commits using GPG"
        "--no-keep-cr; remove carriage returns at the end of lines"
        "--no-message-id; don't add message-id to commit message"
        "--no-scissors; cancels the --scissors OPTIONS"
        "--no-utf8; don't convert character encoding"
        "v --no-verify; bypass pre-applypatch and applypatch-msg hooks"
        "--patch-format:; specify patch format"
        "--quoted-cr:; specify how to handle CR in quoted email"
        "q --quiet; print error messages only"
        "--quit; abort patching and keep HEAD and index as is"
        "--resolvemsg:"  # not for command line use
        "--retry; re-apply last conflicting patch"
        "c --scissors; remove lines before a scissors line"
        "--show-current-patch::; show message on conflict"
        "s --signoff; add a \"signed-off-by\" line to the message"
        "--skip; skip the current patch (when restarting an aborted patch)"
        "u --utf8; re-encode the log message into UTF-8"
        ) #<#
        if command -vf completion/git::apply:getopt >/dev/null 2>&1 ||
                        . -AL completion/git-apply; then
                command -f completion/git::apply:getopt am
        fi

        command -f completion//parseoptions
        case $ARGOPT in
                (-)
                        command -f completion//completeoptions
                        ;;
                ('')
                        complete -P "$PREFIX" -f
                        ;;
                (--empty)
                        command -f completion/git::--empty:arg
                        ;;
                (--patch-format)
                        complete -P "$PREFIX" mbox mboxrd stgit stgit-series hg
                        ;;
                (S|--gpg-sign)
                        command -f completion/git::--gpg-sign:arg
                        ;;
                (*)
                        if command -vf completion/git::apply:compopt >/dev/null 2>&1 ||
                                        . -AL completion/git-apply; then
                                command -f completion/git::apply:compopt
                        fi
                        ;;
        esac

}


# vim: set ft=sh ts=8 sts=8 sw=8 et: