Date: Sun, 3 Sep 2023 15:28:35 +0200 From: Ede Wolf <listac@nebelschwaden.de> To: questions@freebsd.org Subject: Re: cut off last lines of a document Message-ID: <5d2d90d1-b842-4a84-846b-dd0c56cd47b4@nebelschwaden.de> In-Reply-To: <20230903150612.c88185f3.freebsd@edvax.de> References: <57be5495-97f8-4f22-9ae2-cd9712596e64@nebelschwaden.de> <de480aeb-3f8c-4be2-8162-6d9f033f201a@nebelschwaden.de> <v2srpri7wvagrqjuw4jdrucdmy7aifgmlwl32ibtv3zc3ves7m@zl4vf4yeom7f> <ba983eee-b0bf-4bd9-a6ee-acf46f467229@nebelschwaden.de> <20230903150612.c88185f3.freebsd@edvax.de>
next in thread | previous in thread | raw e-mail | index | archive | help
Am 03.09.23 um 15:06 schrieb Polytropon: > On Sun, 3 Sep 2023 10:05:46 +0200, Ede Wolf wrote: >> Am 02.09.23 um 05:37 schrieb lain.: >>> On 2023年09月01日 11:37, the silly Ede Wolf claimed to have said: >>>> as it again is specific to FreeBSD, so if there is a >>>> more universal solution, that would be preferred. Even though this of course >>>> is a FreeBSD mailing list. >>> >>> I should point out that FreeBSD coreutils are not GNU coreutils, so >>> there are going to be differences. >>> And there are 1000s of different versions of coreutils available, >>> because they're so easy to re-create, and each one of them work >>> differently. >>> >> >> I am aware of this, that is why I am so thankfull for the sed and awk >> solutions provided here. Those are a little bit more handy than a perl >> script :) >> >> Of course there are differences between those tools as well, but so far >> those seem to have a common playground - the awk as well as sed examples >> so far are working for gnu as well as [Free|Net]BSD. Not even required >> to add the --posix flag to gnu sed. > > If I may: > > Everything depends. > > If your goal is maximum portability, you absolutely need to > stay away from GNU extensions. So if your script needs to run > on various Linux and UNIX (!) systems, only using the most > common tools in their most simple versions is the way to go. Maye there is a misunderstanding on my side, but that is exactly what I've asked for and what kindly has been provided to me?
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?5d2d90d1-b842-4a84-846b-dd0c56cd47b4>