"GOT", but the "O" is a cute, smiling pufferfish. Index | Thread | Search

From:
Omar Polo <op@omarpolo.com>
Subject:
Re: got patch: file has unexpected status
To:
Christian Weisgerber <naddy@mips.inka.de>
Cc:
gameoftrees@openbsd.org
Date:
Tue, 19 Apr 2022 16:41:21 +0200

Download raw body.

Thread
Christian Weisgerber <naddy@mips.inka.de> wrote:
> I thought Matthieu's "UPDATE: xterm 372" diff on the tech@openbsd.org
> list would be an ideal candidate to apply with "got patch" to a
> checkout of OpenBSD's xenocara tree.
> 
> Manually, the diff would apply just fine:
> 
> $ cd xenocara/app/xterm
> $ patch -C -s -p0 <~/xterm.patch
> $ echo $?
> 0
> 
> However, got patch produces a cavalcade of errors:

Oh, yes, it's known, apologies.  got_patch uses
got_worktree_resolve_path (see lib/worktree.c:/^patch_check_path) which
doesn't play nice with $PWD.  It interprets the paths as, for example,
$worktree/COPYING instead of $worktree/app/xterm/COPYING.

This, and the partial checkout, are the (only?) big omission in the
current patch implementation.

(i have some wip stuff to get around those two limitations, but i was
waiting for the -R stuff to get committed first.  i'll resume the work
on them this week anyway.)

TL;DR: until i fix the path handling, got patch expects patches with
full paths, as generated by `got diff' or `git/cvs diff' from the root
of the repository.

> (BTW, I captured those with script(1) since the interspersed messages
> to stdout and stderr are badly out of sync if they don't go to a tty.)
> 
> $ got patch ~/xterm.patch
> #  COPYING
> got: app/xterm/COPYING: file has unexpected status
> #  MANIFEST
> got: app/xterm/MANIFEST: file has unexpected status
> #  NEWS
> got: app/xterm/NEWS: file has unexpected status
> #  THANKS
> got: app/xterm/THANKS: file has unexpected status
> #  Tekproc.c
> got: app/xterm/Tekproc.c: file has unexpected status
> #  VTPrsTbl.c
> got: app/xterm/VTPrsTbl.c: file has unexpected status
> #  VTparse.def
> got: app/xterm/VTparse.def: file has unexpected status
> #  button.c
> got: app/xterm/button.c: file has unexpected status
> #  charproc.c
> got: app/xterm/charproc.c: file has unexpected status
> #  ctlseqs.ms
> got: app/xterm/ctlseqs.ms: file has unexpected status
> #  ctlseqs.txt
> got: app/xterm/ctlseqs.txt: file has unexpected status
> #  cursor.c
> got: app/xterm/cursor.c: file has unexpected status
> #  fontutils.c
> got: app/xterm/fontutils.c: file has unexpected status
> #  graphics.c
> got: app/xterm/graphics.c: file has unexpected status
> #  graphics.h
> got: app/xterm/graphics.h: file has unexpected status
> #  graphics_regis.c
> got: app/xterm/graphics_regis.c: file has unexpected status
> #  graphics_sixel.c
> got: app/xterm/graphics_sixel.c: file has unexpected status
> #  linedata.c
> got: app/xterm/linedata.c: file has unexpected status
> #  main.c
> got: app/xterm/main.c: file has unexpected status
> #  main.h
> got: app/xterm/main.h: file has unexpected status
> #  misc.c
> got: app/xterm/misc.c: file has unexpected status
> #  plink.sh
> got: app/xterm/plink.sh: file has unexpected status
> #  ptyx.h
> got: app/xterm/ptyx.h: file has unexpected status
> #  resize.c
> got: app/xterm/resize.c: file has unexpected status
> #  run-tic.sh
> got: app/xterm/run-tic.sh: file has unexpected status
> #  screen.c
> got: app/xterm/screen.c: file has unexpected status
> #  scrollback.c
> got: app/xterm/scrollback.c: file has unexpected status
> #  scrollbar.c
> got: app/xterm/scrollbar.c: file has unexpected status
> #  terminfo
> got: app/xterm/terminfo: file has unexpected status
> #  trace.c
> got: app/xterm/trace.c: file has unexpected status
> #  trace.h
> got: app/xterm/trace.h: file has unexpected status
> #  util.c
> got: app/xterm/util.c: file has unexpected status
> #  version.h
> got: app/xterm/version.h: file has unexpected status
> #  wcwidth.c
> got: app/xterm/wcwidth.c: file has unexpected status
> #  xterm.appdata.xml
> got: app/xterm/xterm.appdata.xml: file has unexpected status
> #  xterm.h
> got: app/xterm/xterm.h: file has unexpected status
> #  xterm.log.html
> got: app/xterm/xterm.log.html: file has unexpected status
> #  xterm.man
> got: app/xterm/xterm.man: file has unexpected status
> #  xtermcfg.h
> got: app/xterm/xtermcfg.h: file has unexpected status
> #  xtermcfg.hin
> got: app/xterm/xtermcfg.hin: file has unexpected status
> #  icons/make-xpms
> got: /home/naddy/tmp/xenocara/app/xterm/icons/make-xpms: No such file or directory
> #  package/xterm.spec
> got: app/xterm/package/xterm.spec: file has unexpected status
> #  package/debian/changelog
> got: app/xterm/package/debian/changelog: file has unexpected status
> #  package/debian/copyright
> got: app/xterm/package/debian/copyright: file has unexpected status
> #  package/debian/rules
> got: app/xterm/package/debian/rules: file has unexpected status
> #  package/freebsd/Makefile
> got: app/xterm/package/freebsd/Makefile: file has unexpected status
> #  package/pkgsrc/Makefile
> got: app/xterm/package/pkgsrc/Makefile: file has unexpected status
> #  vttests/16colors.sh
> got: app/xterm/vttests/16colors.sh: file has unexpected status
> #  vttests/8colors.sh
> got: app/xterm/vttests/8colors.sh: file has unexpected status
> #  vttests/acolors.sh
> got: app/xterm/vttests/acolors.sh: file has unexpected status
> #  vttests/acs.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/acs.pl: No such file or directory
> #  vttests/altchars.sh
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/altchars.sh: No such file or directory
> #  vttests/blink.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/blink.pl: No such file or directory
> #  vttests/bold-italics.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/bold-italics.pl: No such file or directory
> #  vttests/bounce.sh
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/bounce.sh: No such file or directory
> #  vttests/ctlpix.sh
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/ctlpix.sh: No such file or directory
> #  vttests/cursor.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/cursor.pl: No such file or directory
> #  vttests/decsed.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/decsed.pl: No such file or directory
> #  vttests/dl.sh
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/dl.sh: No such file or directory
> #  vttests/doublechars.sh
> got: app/xterm/vttests/doublechars.sh: file has unexpected status
> #  vttests/dynamic.sh
> got: app/xterm/vttests/dynamic.sh: file has unexpected status
> #  vttests/dynamic2.sh
> got: app/xterm/vttests/dynamic2.sh: file has unexpected status
> #  vttests/erase.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/erase.pl: No such file or directory
> #  vttests/fonts.sh
> got: app/xterm/vttests/fonts.sh: file has unexpected status
> #  vttests/halves.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/halves.pl: No such file or directory
> #  vttests/il.sh
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/il.sh: No such file or directory
> #  vttests/insdelln.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/insdelln.pl: No such file or directory
> #  vttests/iso2022.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/iso2022.pl: No such file or directory
> #  vttests/lrmm-scroll.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/lrmm-scroll.pl: No such file or directory
> #  vttests/nrcs.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/nrcs.pl: No such file or directory
> #  vttests/other-sgr.sh
> got: app/xterm/vttests/other-sgr.sh: file has unexpected status
> #  vttests/palettes.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/palettes.pl: No such file or directory
> #  vttests/pointer-shapes.sh
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/pointer-shapes.sh: No such file or directory
> #  vttests/print-vt-chars.pl
> got: app/xterm/vttests/print-vt-chars.pl: file has unexpected status
> #  vttests/query-status.pl
> got: app/xterm/vttests/query-status.pl: file has unexpected status
> #  vttests/resize.sh
> got: app/xterm/vttests/resize.sh: file has unexpected status
> #  vttests/scroll.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/scroll.pl: No such file or directory
> #  vttests/setpos.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/setpos.pl: No such file or directory
> #  vttests/tab0.sh
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/tab0.sh: No such file or directory
> #  vttests/title.sh
> got: app/xterm/vttests/title.sh: file has unexpected status
> #  vttests/titlestack.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/titlestack.pl: No such file or directory
> #  vttests/unascii.sh
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/unascii.sh: No such file or directory
> #  vttests/under-latin.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/under-latin.pl: No such file or directory
> #  vttests/utf8.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/utf8.pl: No such file or directory
> #  vttests/version.sh
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/version.sh: No such file or directory
> #  vttests/vt52chars.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/vt52chars.pl: No such file or directory
> #  vttests/wrap.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/wrap.pl: No such file or directory
> #  vttests/xorblink.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/xorblink.pl: No such file or directory
> #  vttests/xtra-scroll.pl
> got: /home/naddy/tmp/xenocara/app/xterm/vttests/xtra-scroll.pl: No such file or directory
> got: patch failed to apply
> 
> 
> What's up with that?