Pretty much every single new portfile submission I look at appears to have been made with hard tabs set at 8 width. However, I (and many others) use 4-width tabs, so these portfiles look very ugly in our editors. I would ask that all new Portfile submissions be done with 4-space soft tabs instead. Using spaces means all editors will present the Portfile the same way. Every single modern editor (including emacs and vim) has the capability of doing 4-space soft tabs, so please use it. Thanks, Kevin Ballard -- Kevin Ballard http://kevin.sb.org eridius@macports.org http://www.tildesoft.com
Le 07-03-14 à 19:19, Kevin Ballard a écrit :
Pretty much every single new portfile submission I look at appears to have been made with hard tabs set at 8 width. However, I (and many others) use 4-width tabs, so these portfiles look very ugly in our editors.
I would ask that all new Portfile submissions be done with 4-space soft tabs instead. Using spaces means all editors will present the Portfile the same way. Every single modern editor (including emacs and vim) has the capability of doing 4-space soft tabs, so please use it.
While it is not a bad idea to write it on the list, it should be included in some Portfile guide. Maybe not too far from the svn properties ... yves
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Mar 14, 2007, at 4:53 PM, Yves de Champlain wrote:
While it is not a bad idea to write it on the list, it should be included in some Portfile guide. Maybe not too far from the svn properties ...
Not that I want to tamp down a good flame war before it starts, but should this be redirected to the -devel list? In my limited experience, it seemed to work to use tabs and let their width be set in the editor. my .exrc has these options set: set number set tabstop=3 set sw=16 set ai set showmatch - -- Paul Beard contact info: www.paulbeard.org/paulbeard.vcf pictures: http://www.flickr.com/photos/pdb206/ Are you trying to win an argument or solve a problem? -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (Darwin) iD8DBQFF+JL4fHLPwpj1/JQRAnLUAKCyBYh5TVIeYWmySn8byH5mnZcrcwCgtccg 3VopHMFqIMQw/I+GgM/cZaQ= =4Tyq -----END PGP SIGNATURE-----
On 2007-03-14 19:19:20 -0400, Kevin Ballard wrote:
I would ask that all new Portfile submissions be done with 4-space soft tabs instead. Using spaces means all editors will present the Portfile the same way. Every single modern editor (including emacs and vim) has the capability of doing 4-space soft tabs, so please use it.
BTW, does anyone have .emacs code for that? -- Vincent Lefèvre <vincent@vinc17.org> - Web: <http://www.vinc17.org/> 100% accessible validated (X)HTML - Blog: <http://www.vinc17.org/blog/> Work: CR INRIA - computer arithmetic / Arenaire project (LIP, ENS-Lyon)
On Mar 14, 2007, at 19:27, Paul Beard wrote:
On Mar 14, 2007, at 4:53 PM, Yves de Champlain wrote:
While it is not a bad idea to write it on the list, it should be included in some Portfile guide. Maybe not too far from the svn properties
What we should do is this: - Inform both mailing lists that we want to excise all tab (ASCII 09) characters from all Portfiles. - Advise all port maintainers to fix their Portfiles to comply with this directive, using the expand program, using 4- or 8-space-width tabs, as per their original intention for the Portfile, so that columns line up correctly. - Advise port maintainers that we prefer 4-space-width indentation. - After some period of time, to allow port maintainers to do this, we run a batch process of all remaining tab-containing Portfiles to convert tabs to 4 (or 8, whatever seems like the best fit)-space- width tabs. - Install a pre-commit hook that prevents commits of Portfiles that contain tabs, printing a message showing the user how to entab and detab their files using the expand and unexpand programs. I can write this hook script. I don't think there's even any reason to document this in the wiki or anywhere else, since someone who already uses spaces will not notice, and anyone who uses tabs will be prevented from doing so, and instructed at that time how to easily convert their Portfile so that it is acceptable.
Not that I want to tamp down a good flame war before it starts, but should this be redirected to the -devel list?
In my limited experience, it seemed to work to use tabs and let their width be set in the editor.
Well, the discussion took place on the macports-devel list last month, at some length: http://lists.macosforge.org/pipermail/macports-dev/2007-February/ 000517.html There were not that many participants. I tried to put up a fight in favor of keeping hard tabs, but I was the only one. :-) Upon further consideration, I don't think I really care that much one way or another, and I do recognize that a whole class of spacing issues we currently have in Portfiles would not occur if we did not use tabs. So, let's take 'em out!
my .exrc has these options set: set number set tabstop=3 set sw=16 set ai set showmatch
-- To reply to the mailing list, please use your mailer's Reply To All function
On Mar 15, 2007, at 3:12 AM, Ryan Schmidt wrote:
There were not that many participants. I tried to put up a fight in favor of keeping hard tabs, but I was the only one. :-) Upon further consideration, I don't think I really care that much one way or another, and I do recognize that a whole class of spacing issues we currently have in Portfiles would not occur if we did not use tabs. So, let's take 'em out!
The old rule was that Porfiles should be internally consistent. That was it - and I don't think it's so bad to let portfile authors handle things however they want as long as the result isn't totally unreadable for everything else. So, my vote would be for continuing the old policy and not getting all whitespace-crazy on everything (it makes sense to have one whitespace convention for base/ code, though). -- Daniel J. Luke +========================================================+ | *---------------- dluke@geeklair.net ----------------* | | *-------------- http://www.geeklair.net -------------* | +========================================================+ | Opinions expressed are mine and do not necessarily | | reflect the opinions of my employer. | +========================================================+
On 2007-03-15 10:15:58 -0400, Daniel J. Luke wrote:
The old rule was that Porfiles should be internally consistent.
That was it - and I don't think it's so bad to let portfile authors handle things however they want as long as the result isn't totally unreadable for everything else.
But this makes writing Portfile patches (with the author's style) more complex. -- Vincent Lefèvre <vincent@vinc17.org> - Web: <http://www.vinc17.org/> 100% accessible validated (X)HTML - Blog: <http://www.vinc17.org/blog/> Work: CR INRIA - computer arithmetic / Arenaire project (LIP, ENS-Lyon)
On Mar 15, 2007, at 3:12 AM, Ryan Schmidt wrote:
There were not that many participants. I tried to put up a fight in favor of keeping hard tabs, but I was the only one. :-) Upon further consideration, I don't think I really care that much one way or another, and I do recognize that a whole class of spacing issues we currently have in Portfiles would not occur if we did not use tabs. So, let's take 'em out!
The old rule was that Porfiles should be internally consistent.
That was it - and I don't think it's so bad to let portfile authors handle things however they want as long as the result isn't totally unreadable for everything else.
So, my vote would be for continuing the old policy and not getting all whitespace-crazy on everything (it makes sense to have one whitespace convention for base/ code, though).
I concur. Paul
On Mar 15, 2007, at 10:33 AM, Vincent Lefevre wrote:
On 2007-03-15 10:15:58 -0400, Daniel J. Luke wrote:
The old rule was that Porfiles should be internally consistent.
That was it - and I don't think it's so bad to let portfile authors handle things however they want as long as the result isn't totally unreadable for everything else.
But this makes writing Portfile patches (with the author's style) more complex.
Exactly... Its a real pain as a patch-maker to figure out when this is happening, because my natural (soft)tabstop is 4 and Portfiles using \t and ' ' appear exactly the same... Other times I have to try tabstops between 3 and 10 until things line up to guess what the author used. If we continue to let maintainers pick their own tabstop and soft vs hard setting, can we update the Portfile style guide to include a modeline comment? (or can expand/unexpand guess this for me somehow?) Thanks, Eric
On Mar 15, 2007, at 7:41 AM, Paul Guyot wrote:
On Mar 15, 2007, at 3:12 AM, Ryan Schmidt wrote:
There were not that many participants. I tried to put up a fight in favor of keeping hard tabs, but I was the only one. :-) Upon further consideration, I don't think I really care that much one way or another, and I do recognize that a whole class of spacing issues we currently have in Portfiles would not occur if we did not use tabs. So, let's take 'em out!
The old rule was that Porfiles should be internally consistent.
That was it - and I don't think it's so bad to let portfile authors handle things however they want as long as the result isn't totally unreadable for everything else.
So, my vote would be for continuing the old policy and not getting all whitespace-crazy on everything (it makes sense to have one whitespace convention for base/ code, though).
I concur.
I agree with Paul. The less we dictate the better, except where it's critical. James
(ref: http://www.bikeshed.com/) I love little discussions like this because: A) The people involved generally feel very strongly about the issue in question and get offended when you point out that, in the greater scheme of things, 6 billion other people could genuinely give a damn about the issue at all. B) They eat time and energy far better devoted to issues that some meaningful fraction of that 6 billion people actually do care about, thus deferring the need to grapple with problems that are actually hard to solve. However: C) Given the fundamental truth of propositions (A) and (B) (which even the most passionate participants are aware of, if only subconsciously), the discussion generally dies unsettled until some reasonable amount of time passes and it can be "reasonably" revived again, only to go through the cycle anew. Therefore, I would like to respectfully suggest that we jump straight to (C) and simply decide that this has already run its course early and move on before everyone's mailbox fills up with bikeshed paint. :-) - Jordan On Mar 15, 2007, at 7:41 AM, Paul Guyot wrote:
On Mar 15, 2007, at 3:12 AM, Ryan Schmidt wrote:
There were not that many participants. I tried to put up a fight in favor of keeping hard tabs, but I was the only one. :-) Upon further consideration, I don't think I really care that much one way or another, and I do recognize that a whole class of spacing issues we currently have in Portfiles would not occur if we did not use tabs. So, let's take 'em out!
The old rule was that Porfiles should be internally consistent.
That was it - and I don't think it's so bad to let portfile authors handle things however they want as long as the result isn't totally unreadable for everything else.
So, my vote would be for continuing the old policy and not getting all whitespace-crazy on everything (it makes sense to have one whitespace convention for base/ code, though).
I concur.
Paul
_______________________________________________ macports-users mailing list macports-users@lists.macosforge.org http://lists.macosforge.org/mailman/listinfo/macports-users
On Thu, Mar 15, 2007 at 10:15:58AM -0400, Daniel J. Luke wrote:
On Mar 15, 2007, at 3:12 AM, Ryan Schmidt wrote:
There were not that many participants. I tried to put up a fight in favor of keeping hard tabs, but I was the only one. :-) Upon further consideration, I don't think I really care that much one way or another, and I do recognize that a whole class of spacing issues we currently have in Portfiles would not occur if we did not use tabs. So, let's take 'em out!
The old rule was that Porfiles should be internally consistent.
That was it - and I don't think it's so bad to let portfile authors handle things however they want as long as the result isn't totally unreadable for everything else.
So, my vote would be for continuing the old policy and not getting all whitespace-crazy on everything (it makes sense to have one whitespace convention for base/ code, though).
Indeed. I think dictating spacing will be a headache for current and potential maintainers and result in fewer people joining in. Adding a suggestion in the Portfile maintenance doc about documenting the tab/space width used would help others figure out what the spacing is w/o having to try a variety of possibilities, should they need to adjust a Portfile at some time. -eric
On 2007-03-16 17:18:07 +0000, Eric Hall wrote:
Indeed. I think dictating spacing will be a headache for current and potential maintainers and result in fewer people joining in. Adding a suggestion in the Portfile maintenance doc about documenting the tab/space width used would help others figure out what the spacing is w/o having to try a variety of possibilities, should they need to adjust a Portfile at some time.
and code for various text editors so that the spacing style is automatically set up when opening the file. -- Vincent Lefèvre <vincent@vinc17.org> - Web: <http://www.vinc17.org/> 100% accessible validated (X)HTML - Blog: <http://www.vinc17.org/blog/> Work: CR INRIA - computer arithmetic / Arenaire project (LIP, ENS-Lyon)
participants (11)
-
Daniel J. Luke
-
Eric Cronin
-
Eric Hall
-
James Berry
-
Jordan K. Hubbard
-
Kevin Ballard
-
Paul Beard
-
Paul Guyot
-
Ryan Schmidt
-
Vincent Lefevre
-
Yves de Champlain