I like to comment in my package files, especially the keywords one. For instance about why packages are (requires to be) keyworded. Furthermore, there is quite often a couple of dependent packages that need to be keyworded as well. To keep things in good overview I therefore often indent the dependencies - like this: # I like to have the latest firefox! www-client/mozilla-firefox net-libs/xulrunner This works alright. That is, portage seems to ignore whitespace before atoms, however the following does not work: # I like to have the latest firefox! www-client/mozilla-firefox net-libs/xulrunner # nss & nspr should be able to be removed (minor downgrade) dev-libs/nss dev-libs/nspr It gives an "--- Invalid atom in /etc/portage/package.keywords: #" message. That is, portage does not recognize comments with leading whitespaces. However, I do believe the ability to do the above actually increases readability significantly, which is crucial for the ability to clean out bloated keywords files. My suggestion then is: Since "true" inline or "end-line" comments like this: # I like to have the latest firefox! www-client/mozilla-firefox net-libs/xulrunner dev-libs/nss # this should be able to be removed dev-libs/nspr # and this too! seems to be far from ever being implementet (considering all comments about it in portage man page), the implementation of still being restricted to all line comments, but with leading whitespace would be nice. Allowing "end of line" comments as well would of course be even better though :-) just my two cents... Reproducible: Always
Support for inline comments is in git: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=3ad5122a80f741119b48cb7f0f5107e64e2e3b11 http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=39a2714f4a745ea3ba8e6c3e3cb0c01847ea413d I don't see a reason not to go ahead and add support for leading whitespace before comments too.
Ooops, found this old bug still open, appears fixed! Both inline comments and leading white space seems to be ok now, good!