From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 62BF4138769 for ; Wed, 30 Jan 2013 13:24:24 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id CF311E05C1; Wed, 30 Jan 2013 13:24:20 +0000 (UTC) Received: from mail-ie0-f176.google.com (mail-ie0-f176.google.com [209.85.223.176]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id E5087E05B1 for ; Wed, 30 Jan 2013 13:24:19 +0000 (UTC) Received: by mail-ie0-f176.google.com with SMTP id 13so1238152iea.35 for ; Wed, 30 Jan 2013 05:24:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:reply-to:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:content-type :content-transfer-encoding; bh=sqN6WTEn51mMVlMSo5eGyfHuojNJSnPd5U3+UzuQtKo=; b=yyitnjSyQOpQmN1v9fbsVX7UzuVXCQGCIjCNGFr8MUCfFdDCxcKG0SxVP2iUc0RSwu MoivO/Ja99vkK7Qx36pK86bVUslx6Npt397Ltmsg5dzYV4u7fgcxx+AlSwqKtutAfLxZ d/jO7MoQyRSFFFDB1tqI/b0ij/otgrfX+61ORkPKg5PPyDpln0xg7f1iwO3fjjpyE/or qP1A76SQbu80A+v9Eebp7+9IhaVfb0agx/nEHDzlBqLeGx5Tzh6ir0iW/UmlA9rl28qR 0RJxgHfuzf+4VrnepfMu7rJ38qdTS53+709dhSnuru8Nc/AdTg6PdpEiQFMkgpC4ieKP 3l3A== Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@lists.gentoo.org Reply-to: gentoo-dev@lists.gentoo.org MIME-Version: 1.0 X-Received: by 10.50.189.193 with SMTP id gk1mr3714435igc.87.1359552259238; Wed, 30 Jan 2013 05:24:19 -0800 (PST) Sender: yngwin@gmail.com Received: by 10.64.52.166 with HTTP; Wed, 30 Jan 2013 05:24:19 -0800 (PST) In-Reply-To: <1359496046.2927.55.camel@belkin4> References: <1359295221.2927.24.camel@belkin4> <201301271305.54346.vapier@gentoo.org> <1359310887.2927.39.camel@belkin4> <201301272337.06614.vapier@gentoo.org> <1359401406.2927.49.camel@belkin4> <1359496046.2927.55.camel@belkin4> Date: Wed, 30 Jan 2013 21:24:19 +0800 X-Google-Sender-Auth: Ad2SDoB6Onk27i6PhfK308LB-Yg Message-ID: Subject: Re: readme.gentoo.eclass: use echo -e instead of plain echo (Was: Re: [gentoo-dev] readme.gentoo.eclass: Add a DISABLE_AUTOFORMATTING variable= From: Ben de Groot To: gentoo-dev@lists.gentoo.org Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Archives-Salt: f22510ba-6bd0-41bb-be98-dce5540dd6dd X-Archives-Hash: f94939e0366d695f518f5e8a7277cad6 On 30 January 2013 05:47, Pacho Ramos wrote: > El mar, 29-01-2013 a las 14:03 +0800, Ben de Groot escribi=C3=B3: >> On 29 January 2013 03:30, Pacho Ramos wrote: >> > El lun, 28-01-2013 a las 14:37 +0800, Ben de Groot escribi=C3=B3: >> >> I've started using this eclass, but with README files, not the variab= le, >> >> because this is currently the only way I can make sure it honours my >> >> formatting. >> >> >> > >> > Couldn't it be covered if "echo -e" was used (even with fmt) and you, >> > then, control formatting with some of the sequences it allows (they ar= e >> > shown in its man page)? >> >> No. The eclass should assume that DOC_CONTENTS is already correctly >> formatted. If you must, you can add a convenience function for people >> who do want reformatting, but this should NOT be the default. Please >> don't make this eclass harder to use than it needs to be. >> > > I can add a variable (and probably will), but would prefer to keep it > formatting messages by default, otherwise, how will you set DOC_CONTENTS > variable inside a pkg phase (instead of global scope) without adding > tabs to it? You can of course add it, but it will be read as something > like: > src_prepare() { > DOC_CONTENTS=3D"blablabla > blablabla" > # Rest of src_prepare stuff > } I still prefer the eclass not to mess with formatting by default. You can do what you want by src_prepare() { DOC_CONTENTS=3D"blabla indented content" # other stuff } src_install() { default readme.gentoo_reformat } > Also, autoformatting will help to prevent every package setting messages > with different lines length (in some cases really long lines that I > finally reported some bugs in the past to get them fitting in "standard" > 80 characters per line). Sometimes long lines are what is required. If not, then filing a bug is the friendly solution. --=20 Cheers, Ben | yngwin Gentoo developer Gentoo Qt project lead, Gentoo Wiki admin