From owner-freebsd-current@freebsd.org Fri Apr 9 23:46:42 2021 Return-Path: Delivered-To: freebsd-current@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id BA8905C2DFF for ; Fri, 9 Apr 2021 23:46:42 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qt1-x82d.google.com (mail-qt1-x82d.google.com [IPv6:2607:f8b0:4864:20::82d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4FHFCQ0X9kz4mmw for ; Fri, 9 Apr 2021 23:46:41 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qt1-x82d.google.com with SMTP id 1so5594859qtb.0 for ; Fri, 09 Apr 2021 16:46:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=DOdIqwMbKnfcmfz/qgnmmNxk18XfUgeHuwb7cEQ3Lmc=; b=JSUo72Zdg4ghhv+1qri4/miAFbQgpkky21d29DOGJ4OtAd4ou33iQtYRjdR3rBc9l4 UGWIXrrx/svSEbCxAny/PlbaX0X7ZHd7Ft6O/oU8Qs8DrB5804D/nVW+rdTaWYMBVqY9 31D2Sv2UKL/L2k3/ENZUyJ4HLvV6GiVedN/Dxada0GEb7uRVZiSI3TOQJcEILMMnFld1 uWgFsYn1pDE3H1qfulQAxCoxubrButnlaX55+B8aEUyljyjixuw1brL0qVedGSOea15h S4VRgyhGj83x8+H66JMIvqfHFaLDKP9nBvN5Qgm3cHYfptnWW84Uj63wJNIB6h12ioc5 NzlQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=DOdIqwMbKnfcmfz/qgnmmNxk18XfUgeHuwb7cEQ3Lmc=; b=GLBxssKnbBYfmbQR/4g9kUx6lg7FI19NGi6pF8ZASXlnq2ZzyeoqLSWP6QfVIbC6nQ JEjO4N4IDFUlfVZpm2B2nydtmIgcPpbBLXKLqF/w6PT1SJApBK+mS4IV42HhzOkgNeBO 2qur25cXQRZhCTCnm719U09PQgQ6/HbPEyf3X2r8+usdPDtqfoWSuuZgvk73rwnieWKL ky4NnoDkx3aCDigyF7V6VYOPxMRDMiivb+cMWvXCbdSXu6zJZERsuHU6MLUos03Ne0lW uCWyh+s7/RLCEo5RhiwGgHorUlgsvTAyMY6oO5a4uCyT7c8nEBwQfHyqLB9GrxjgklnM qf4g== X-Gm-Message-State: AOAM531q2sRdwpF2rKhmgfSK6yWGhKW4Ylez8NnW3ow3I0Fbw5npnmZ5 oEtspvo3yuYPRclbuJMD4urJSfGRpsAeUJ6+tBY37g== X-Google-Smtp-Source: ABdhPJxF9auI+SUe+riex6s6wined6YjVkJ2mr4w24vGEK9uwM4u1BPBJWnitGZ3mfW0AMCzyokFGzrM5id2QDU/fcs= X-Received: by 2002:a05:622a:1c5:: with SMTP id t5mr14539530qtw.49.1618012001033; Fri, 09 Apr 2021 16:46:41 -0700 (PDT) MIME-Version: 1.0 References: <20210228023827.f68e6136d688c0a37206c883@3dresearch.com> <20210228120313.cdb53cab429a38fdf9817d0d@3dresearch.com> <20210301020830.5466d368867bdbc11b0b7648@3dresearch.com> <00517bca-fc1b-fcea-50a2-6469ff922092@gmail.com> In-Reply-To: From: Warner Losh Date: Fri, 9 Apr 2021 17:46:30 -0600 Message-ID: Subject: Re: FreeBSD mini-Git Primer To: Kevin Oberman Cc: Graham Perrin , "freebsd-questions@freebsd.org" , FreeBSD CURRENT X-Rspamd-Queue-Id: 4FHFCQ0X9kz4mmw X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=bsdimp-com.20150623.gappssmtp.com header.s=20150623 header.b=JSUo72Zd; dmarc=none; spf=none (mx1.freebsd.org: domain of wlosh@bsdimp.com has no SPF policy when checking 2607:f8b0:4864:20::82d) smtp.mailfrom=wlosh@bsdimp.com X-Spamd-Result: default: False [-3.00 / 15.00]; TO_DN_EQ_ADDR_SOME(0.00)[]; TO_DN_SOME(0.00)[]; DKIM_TRACE(0.00)[bsdimp-com.20150623.gappssmtp.com:+]; NEURAL_HAM_SHORT(-1.00)[-1.000]; FREEMAIL_TO(0.00)[gmail.com]; FORGED_SENDER(0.30)[imp@bsdimp.com,wlosh@bsdimp.com]; MIME_TRACE(0.00)[0:+,1:+,2:~]; RBL_DBL_DONT_QUERY_IPS(0.00)[2607:f8b0:4864:20::82d:from]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; FROM_NEQ_ENVFROM(0.00)[imp@bsdimp.com,wlosh@bsdimp.com]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; R_DKIM_ALLOW(-0.20)[bsdimp-com.20150623.gappssmtp.com:s=20150623]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[4]; NEURAL_HAM_LONG(-1.00)[-1.000]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-current@freebsd.org]; DMARC_NA(0.00)[bsdimp.com]; SPAMHAUS_ZRD(0.00)[2607:f8b0:4864:20::82d:from:127.0.2.255]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::82d:from]; R_SPF_NA(0.00)[no SPF record]; FREEMAIL_CC(0.00)[gmail.com,freebsd.org]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-current]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.34 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 09 Apr 2021 23:46:42 -0000 On Fri, Apr 9, 2021 at 5:16 PM Kevin Oberman wrote: > The updated mini-Git Primer is now included in the Developer's Handbook. > See Chapter 5. I have sent a number of suggestions for some non-technical > changes to Warner, but have not heard back yet. Perhaps he didn't care fo= r > them. > Hmmm, I can't seem to find them in my inbox. Perhaps you could resend them to me? > As I am a real novice who has had to destroy my clone of the sources and > start over twice, I find it unlikely that i will be of significant use on > the technical side for a while. Git is philosophically very different fro= m > RCS/CVS/SVN and the different mindset is taking me a while to fully grasp= . > I will say that specifying a hash that is in main but not part of the > branch you are working on is probably a rather poor idea. I probably coul= d > have easily fixed it, but I had no luck in finding the right incantation > and eventually blew /usr/src away and started over. (How do you fix a > detached clone?) > I can offer advice on that: just checkout main. when you checkout a specific version, you'll get a detached head. One that's fine to use, but not good to commit to. Though, I'd have to see the exact error message to know for sure. > I also find net/gitup a marvelous tool for replacing portsnap. In several > ways, it is clearly superior and I look forward to seeing it in the base.= I > mean, what is simpler than: > # gitup -c ports (just once to create the initial clone) > #gitup ports (to update, perhaps in periodic(8)) > Of course, you do need to edit gitup.conf to select the preferred branch > and repo site, but it's pretty obvious. > I believe we're getting quite close to importing gitup into the base even. There's a rather widely deployed base for portsnap since it's in a lot of people's crontabs, though, so there's an effort afoot to see if there's some way to continue it pulling from git. Warner > On Thu, Apr 8, 2021 at 1:14 AM Graham Perrin > wrote: > >> On 02/03/2021 06:33, Graham Perrin wrote: >> >> Re: Git, shallow clone hashes, commit counts and system/security updates >> >> > On 02/03/2021 05:42, Kevin Oberman wrote: >> > >> > Re: Panic after updating from source >> > >> >> On Mon, Mar 1, 2021 at 6:31 PM Michael Sierchio >> >> wrote: >> >> >> >>> =E2=80=A6 >> >> >> >> You need to be aware that the shallow clone hash will not include the >> >> commit count which will be used in future security updates to make it >> >> easy >> >> to check whether your system needs to be updated or not. A full clone >> >> does >> >> require more space, but I was surprised at how little extra space it >> >> requires. Warner is updating his git mini-guide to point out this >> >> issue. >> >> If you run STABLE, it's a really significant concern. You can convert >> >> the >> >> shallow clone to a full one with "git fetch --unshallow". This will >> take >> >> some time to run. >> >> -- >> >> Kevin Oberman, Part time kid herder and retired Network Engineer >> >> E-mail: rkoberman@gmail.com >> >> PGP Fingerprint: D03FB98AFA78E3B78C1694B318AB39EF1B055683 >> >> _______________________________________________ >> >> freebsd-questions@freebsd.org mailing list >> >> https://lists.freebsd.org/mailman/listinfo/freebsd-questions >> > >> > =E2=80=A6 Thank you, Kevin and Warner. >> > >> >> I see the FreeBSD mini-Git Primer in the November/December 2020 edition >> of the FreeBSD Journal >> >> >> (and the review copy that was publicised in September 2020). >> >> For news of a future edition, if any, should I simply watch >> ? >> >> Thanks >> >> (I have another question about deep and shallow =E2=80=A6 I'll post sepa= rately >> to freebsd-questions =E2=80=A6) >> >>