-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 On 08/13/2015 06:29 PM, wireless wrote: > On 08/13/2015 05:28 PM, Duncan wrote: >> wireless posted on Thu, 13 Aug 2015 08:33:13 -0500 as excerpted: >> >>> On 08/12/2015 09:52 PM, Mike Frysinger wrote: >>>> On 12 Aug 2015 18:27, Brian Dolbec wrote: >>>>> 2) There is another alternate location that you can define >>>>> files to ignore locally without having to commit them to >>>>> .gitignore. Consider .gitignore a global setting. There is >>>>> another setting inside .git/info/exclude which is a local >>>>> config file that will persist and not be affected by >>>>> pulls. >>>> >>>> as i stated, there's no reason for these paths to ever be >>>> committed. conversely, some people (not unreasonably so) will >>>> place files in there that have historically had known >>>> meanings. adding these to the global gitignore is simply the >>>> right thing to do and negatively impacts no one. >>> >>> As a gentoo user now coding again, I find the need to have >>> things "logically organized" really helps in my efforts. Like >>> most others, I get codes from a variety of places and try to >>> follow the 'logical gentoo organization'. I use >>> /usr/local/portage extensively for ebuilds that I develop. >>> There is also /opt/ which seems to collect up a variety of >>> ebuilds > >> Confused... >> >> What do /opt and /usr/local/portage have to do with the gentoo >> repo's .gitignore, which should only need ignore settings for >> locations inside the main tree, /usr/portage by default? A >> .gitignore listing for /usr/portage/local and >> /usr/portage/distfiles, etc, makes sense, since that's inside the >> default tree location. But /opt and /usr/local/portage aren't >> inside that default location and are thus about as apropos to >> that as the price of tea on Mars, aren't they? > > <snip> /distfiles/ /local/ /packages/ <end/snip> > > Other postings in this thread mention /var/ and /usr/.... My bad, I > thought those official directories that were up for discussion on > gitignore relevancy? > >> /usr/portage/local was the original location for the user's own >> personal ebuild space - an "overlay" if you will. >> /usr/portage/distfiles and /usr/portage/packages are there >> because that's where ports has put them for decades, and no-one >> has gotten around to changing it in portage yet. FreeBSD defines >> the use of /usr very differently to what Linux users are used >> to. >> >> Those dirs really should be in /var/portage, and the user's >> overlay has no business being under main tree itself > > > Ok, so why is net-analyzer/jffnms found in /usr/portage/distfiles > yet it is installed in /opt/ ? If jffnms was (properly) installed > like other net-analyzer packages, would it not be in the portage > tree? There is no reason for it to remain in /opt/, that I'm aware > of. But jffnms could benefit form gitignore as other packages do, > regardless of where it is installed.
If I may take a stab at this: /usr/portage/distfiles is simply the files Portage needs to fetch in order to extract them, build, and install the package. If ./distfiles/ is in .gitignore, then nobody can accidentally commit a package's source tarball or other related file. /opt/ is just the installation location for the live system that it's being installed on. The Portage tree (known forward as the Gentoo repository) is the collection of ebuilds that allow a Gentoo system to build the software. It's historically been in /usr/portage/, and installs to a variety of locations, be it /bin, /sbin, /usr/bin, /usr/sbin, /lib, and so on. Without reading the ebuild, jffnms likely has special properties or is built with specific technologies that indicate its files belong in /opt. Given that the Gentoo repository by default resides in /usr/portage, a .gitignore file can only apply to paths *under* that particular path. So it would cover ./local and ./distfiles, but not /opt, as /opt is outside the /usr/portage location and not under Git control. Was I able to explain that sufficiently? > > > Looking at the documentation for gitignore it would seem that the > benefits of using gitignore on those /opt/ packages could be > useful; so would it not be up to the particular package maintainer > to make that decision? Regardless of where non-devs develop > packages for gentoo, using gitignore might be useful during the > development of the packages, particularly if it is destine for the > portage tree (eventually). > > Apologies in advance if I have missed some key points already > established by the gentoo dev community.... I'm certainly no whiz > with git*. /opt is simply the chosen place for certain programs to be installed based on how they are structured, their licensing, or the way similar packages get handled. Users can use the INSTALL_MASK variable in /etc/make.conf to exclude any paths from having files installed, but if things break they get to keep the pieces. > > > > James > tldr .gitignore just applies to the Gentoo repository, not an entire Gentoo system. - -- Daniel Campbell - Gentoo Developer OpenPGP Key: 0x1EA055D6 @ hkp://keys.gnupg.net fpr: AE03 9064 AE00 053C 270C 1DE4 6F7A 9091 1EA0 55D6 -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCAAGBQJVzbMQAAoJEAEkDpRQOeFwfKAQAKA++hN2iwQ3B/H3DwnxOnLr MP8rtWKaqaT+ZRMhf719++zGzQa+NSpTrriUH78RuecOxZRutTU8QtBIWdspF9el xsppfpaQFCy00w05XhzkS9yqKQs1pzJu0V8991pX4FhPQAbcZxJfxUw6FG6tXgJl 7+DatNg3Fl2EcojGnbKpX9BJg9Vs4iFZeynkcY3cGiuXeVYQlSYO1z8K6dw6aMIy ScbRz0ixvJGT1SZiFZzz7VRrIpAZGr3SCHieH3Tu3wR6Bg17ki/4eSmNEgtrUj1D HLFc+RdZKOis4kmi1V6Ex0x04HplRVQXgn/aX5ob8oBXZDj9eoCT0kDvigFpiBiD ykKS80PKZ5DHkZmI3A7NYdLTuFhLoL9Zc08cQHC1dDgU1FzqK5A21MJv2TDnfc/A 30U7uyz1KMIUJWKeTRZ3T7kfPRzCmVWAkvSlRpetNfOpiSAutWbcPNyALnsPH2xu yOJ0zDvj5IbP/yRhJOi7VwJw03rmCju+AViWMmEy/BAAP8S0eSM9XH3zxgsSs2W2 vdxeDnPpMOt87Nj0mGSaZaVH/ivXvxrfCKgOrc3vdTUxTOSwntN3VGs7jhDyanlq 6qSc6yOuN0EWvG4w0S6Pb05ZQ3CdyyOfJ4jOefEkUU2vQ2TyW3n93EK2yqfplgd8 oKNcRvB3CeRlM/phybIa =j/xk -----END PGP SIGNATURE-----