From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=0.2 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED autolearn=no autolearn_force=no version=3.4.4 Received: (qmail 24998 invoked from network); 24 Sep 2022 13:39:55 -0000 Received: from 9front.inri.net (168.235.81.73) by inbox.vuxu.org with ESMTPUTF8; 24 Sep 2022 13:39:55 -0000 Received: from wopr.sciops.net ([216.126.196.60]) by 9front; Sat Sep 24 09:37:38 -0400 2022 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sciops.net; s=20210706; t=1664026565; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VL233J8KEoOqu85bPJ5ygEirGdI43pkdpRki40N2Uc4=; b=2aLqvSJSc2k4l7P9pFiAJo9q7L1/jQZM/GBlgnwxzsQ6lIXcMud/Y/DjhRw075YWbHUZ7Z crZ1lmTMUSswVib1o2F0pWAkS0ks1yeQS1O/e6wk9uW9c3G99PvP/1wBwPYDaHpxod0aQv 2+pLRmAOV0lAhoB6zuHFp6JDSp/AkFU= Received: by wopr.sciops.net (OpenSMTPD) with ESMTPSA id 7d5aa41e (TLSv1.2:ECDHE-RSA-CHACHA20-POLY1305:256:NO) for <9front@9front.org>; Sat, 24 Sep 2022 06:36:04 -0700 (PDT) Message-ID: Date: Sat, 24 Sep 2022 15:37:33 +0200 From: qwx@sciops.net To: 9front@9front.org MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit List-ID: <9front.9front.org> List-Help: X-Glyph: ➈ X-Bullshit: basic dependency polling injection locator Subject: [9front] git/import: fix handling relative paths Reply-To: 9front@9front.org Precedence: bulk Hello, This fixes git/import with relative file names not from the git root: ; bind -bc /dist/plan9front / ; cd /usr/seymour ; git/import butz ... tries to open /butz rather than /usr/seymour/butz. Comments? Thanks, qwx diff e81e1b80842b6d25eb5ab9dc8bc86f37ec2f5316 uncommitted --- a/sys/src/cmd/git/import +++ b/sys/src/cmd/git/import @@ -110,7 +110,7 @@ patches=(/fd/0) if(! ~ $#* 0) - patches=$* + patches=`{cleanname -d $gitrel $*} for(p in $patches){ # upas serves the decoded header and body separately, # so we cat them together when applying a upas message.