Date: Tue, 30 Apr 2013 13:46:07 -0400 From: Eitan Adler <lists@eitanadler.com> To: Baptiste Daroussin <bapt@freebsd.org> Cc: ports@freebsd.org Subject: Re: [BRAINSTORM] shebang fixing framework Message-ID: <CAF6rxg=_UhYoKJxccZO9sy9-O3ZgMXHd71zxPEP4MPNLMiJR4w@mail.gmail.com> In-Reply-To: <20130430174130.GQ3577@ithaqua.etoilebsd.net> References: <20130430103821.GJ3577@ithaqua.etoilebsd.net> <CAF6rxgn_hYd=HTBPm_53UgKd1dGt-ChNZQUoi7-CViZJNtFeGw@mail.gmail.com> <20130430173500.GP3577@ithaqua.etoilebsd.net> <CAF6rxgk2SUVhtfEAuxZU2JdfDi6p25m7vOxe494Rupnh6NDzJw@mail.gmail.com> <20130430174130.GQ3577@ithaqua.etoilebsd.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On 30 April 2013 13:41, Baptiste Daroussin <bapt@freebsd.org> wrote: > On Tue, Apr 30, 2013 at 01:38:03PM -0400, Eitan Adler wrote: >> On 30 April 2013 13:35, Baptiste Daroussin <bapt@freebsd.org> wrote: >> > All of this will be damn slow operations, we want to keep this as fast as >> > possible, even if per-ports it seems quite fast, when you are about the build >> > the whole ports tree few seconds there and there will become hours >> >> Yes, that is why I ended with "I guess it isn't too bad.", although I >> guess it wasn't clear I meant needing lang_FILES. >> >> I'd prefer shebangfix_FILES and have all the language fixes apply >> without needing to specify which one. > > most of the case you will know what file needs what shebang, so why trying all > possible case when you can get it directly? If applied as a regex it doesn't really matter. I'm thinking it will look something like sed -e regex_for_perl \ -e regex_for_python \ -e regex_for_php \ ${shebangfix_FILES} or some variant thereof now that I think about it a bit more it may even be faster than forking once per language. -- Eitan Adler
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAF6rxg=_UhYoKJxccZO9sy9-O3ZgMXHd71zxPEP4MPNLMiJR4w>