From nobody Wed May 1 18:00:23 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) client-ip=205.139.110.61; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1576089926; cv=none; d=zohomail.com; s=zohoarc; b=JH2+n3/ZYD4tP4Hdi2+kj7s74qubTs8kgO+3/flWtb+Qdhq0oUkQWRcyw0BGsDMxbu12K1miaScWOvHNf46aA5Xehr6Wzjk6WrqlVyCEC8pK6pb7CzmgrcFFJkCB0nnw6mepkUJIDQRKV1F9kGyuaAD1fJzyK1i7FWfOxtcyDK4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1576089926; h=Content-Type:Content-Transfer-Encoding:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=Ws1Nb7FO91F8NN9roIrrz5S1nlFP/80iNqGJ+j328RI=; b=D7rHCG3mZWFPYGrvP34P4wnCBNKAIZaijWWdNQC7G6/qx6rzmyro14eUModm+tGC4LUuWZq7zDO4D/UrVBJjjySJ0dzfRf3N4DFZLQNyGsq19+2udygDLqG+ma4kS03iqTG5PxpemSzm1ES0kPGKAnC1tGPP09H4SMqEh5DwVC4= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-2.mimecast.com [205.139.110.61]) by mx.zohomail.com with SMTPS id 1576089926731616.6732291190972; Wed, 11 Dec 2019 10:45:26 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-100-CO7K4TBpNnKH_yQWYNRadg-1; Wed, 11 Dec 2019 13:45:23 -0500 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 8B7A18024CF; Wed, 11 Dec 2019 18:45:15 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 6080E60BF3; Wed, 11 Dec 2019 18:45:14 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id D3C8C62CF5; Wed, 11 Dec 2019 18:45:12 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id xBBIjBRn005992 for ; Wed, 11 Dec 2019 13:45:11 -0500 Received: by smtp.corp.redhat.com (Postfix) id DCAF119481; Wed, 11 Dec 2019 18:45:11 +0000 (UTC) Received: from localhost.localdomain.com (ovpn-112-62.ams2.redhat.com [10.36.112.62]) by smtp.corp.redhat.com (Postfix) with ESMTP id EC39119C6A; Wed, 11 Dec 2019 18:45:07 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1576089925; h=from:from:sender:sender: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:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=Ws1Nb7FO91F8NN9roIrrz5S1nlFP/80iNqGJ+j328RI=; b=OODvP480Aqa4ZT6Mur015QNMJuaRfl/wyXXr45zkEnje+MM+oOqWWpg6gz/uQwBUyweEbq 3I2RS10IkNf2ZX0ICIRXGniNBCepNUJekdB5FvQHzorcWg6qasJPaqsoBaSjc07vVUegzo wVPk4kAewhd75n5qJ79yFqKqrc8UACM= From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= To: libvir-list@redhat.com Date: Wed, 11 Dec 2019 18:45:04 +0000 Message-Id: <20191211184504.1828156-1-berrange@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH] docs: ensure outputfile is deleted if rst2html/rst2man fail X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-MC-Unique: CO7K4TBpNnKH_yQWYNRadg-1 X-Mimecast-Spam-Score: 0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) This avoids leaving a zero length or partially generated output file on errors. Signed-off-by: Daniel P. Berrang=C3=A9 --- docs/Makefile.am | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/Makefile.am b/docs/Makefile.am index eb8de80b9c..9a1f7a6117 100644 --- a/docs/Makefile.am +++ b/docs/Makefile.am @@ -259,21 +259,21 @@ man8_MANS =3D $(manpages8_rst:%.rst=3D%.8) grep -v '^\.\. contents::' < $< | \ sed -e 's|SYSCONFDIR|$(sysconfdir)|g' \ -e 's|RUNSTATEDIR|$(runstatedir)|g' | \ - $(RST2MAN) > $@ + $(RST2MAN) > $@ || { rm $@ && exit 1; } =20 %.7: %.rst $(AM_V_GEN)$(MKDIR_P) `dirname $@` && \ grep -v '^\.\. contents::' < $< | \ sed -e 's|SYSCONFDIR|$(sysconfdir)|g' \ -e 's|RUNSTATEDIR|$(runstatedir)|g' | \ - $(RST2MAN) > $@ + $(RST2MAN) > $@ || { rm $@ && exit 1; } =20 %.8: %.rst $(AM_V_GEN)$(MKDIR_P) `dirname $@` && \ grep -v '^\.\. contents::' < $< | \ sed -e 's|SYSCONFDIR|$(sysconfdir)|g' \ -e 's|RUNSTATEDIR|$(runstatedir)|g' | \ - $(RST2MAN) > $@ + $(RST2MAN) > $@ || { rm $@ && exit 1; } =20 manpages/virkeycode-%.rst: $(top_srcdir)/src/keycodemapdb/data/keymaps.csv= \ $(top_srcdir)/src/keycodemapdb/tools/keymap-gen Makefile.am @@ -414,11 +414,11 @@ manpages/%.html.in: manpages/%.rst grep -v '^:Manual ' < $< | \ sed -e 's|SYSCONFDIR|$(sysconfdir)|g' \ -e 's|RUNSTATEDIR|$(runstatedir)|g' | \ - $(RST2HTML) > $@ + $(RST2HTML) > $@ || { rm $@ && exit 1; } =20 %.html.in: %.rst $(AM_V_GEN)$(MKDIR_P) `dirname $@` && \ - $(RST2HTML) $< > $@ + $(RST2HTML) $< > $@ || { rm $@ && exit 1; } =20 %.html.tmp: %.html.in site.xsl subsite.xsl page.xsl \ $(acl_generated) --=20 2.23.0 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list