编辑:我添加了一些我认为不必要的信息,但事实并非如此.我有两个分支,A和B.在A中进行三次提交后更改了file.c我想将它们挑选到B中,还有一个在A~1中更改的file.h
> git cherry-pick A~2
Success
> git cherry-pick A~1
error: could not apply 81e0723...
hint: after resolving the conflicts, mark the corrected paths
hint: with 'git add <paths>' or 'git rm <paths>'
hint: and commit the result with 'git commit'
> git status
You are currently cherry-picking commit 81e0723.
Unmerged paths:
(use "git add <file>..." to mark resolution)
both modified: some/unrelated/file.txt
both modified: file.c
Run Code Online (Sandbox Code Playgroud)
现在,在查看某些/不相关的/ file.txt时,它包含对中间某处的file.h的更改.所以这看起来像是git中的一个bug.所以我现在将手动撤消一些/不相关/ file.txt的更改并将它们添加到file.h.
这是用 Gimp 制作的黑色 1x1 PNG 的十六进制转储,并以最少的信息导出:
89 50 4E 47 0D 0A 1A 0A 00 00 00 0D 49 48 44 52
00 00 00 01 00 00 00 01 08 02 00 00 00 90 77 53
DE 00 00 00 0C 49 44 41 54 08 D7 63 60 60 60 00
00 00 04 00 01 27 34 27 0A 00 00 00 00 49 45 4E
44 AE 42 60 82
Run Code Online (Sandbox Code Playgroud)
现在,在阅读规范后,我非常确定其中大多数的含义,除了 IHDR 和 …
我想在我的参数解析器中添加一个名为'print'的参数
arg_parser.add_argument('--print', action='store_true', help="print stuff")
args = arg_parser.parse_args(sys.argv[1:])
if args.print:
print "stuff"
Run Code Online (Sandbox Code Playgroud)
产量:
if args.print:
^
SyntaxError: invalid syntax
Run Code Online (Sandbox Code Playgroud) argparse ×1
arguments ×1
c ×1
c++ ×1
cherry-pick ×1
file-format ×1
format ×1
git ×1
keyword ×1
msdn ×1
png ×1
python ×1
python-2.7 ×1