On Tue, Sep 10, 2019 at 05:58:53PM +0100, Raf Czlonka wrote:
> On Tue, Sep 10, 2019 at 05:53:34PM BST, Todd C. Miller wrote:
> > On Tue, 10 Sep 2019 16:56:42 +0100, Raf Czlonka wrote:
> >
> > > How about ditching dirname(1)?
> >
> > dirname(1) handles files in the root directory as well as files
On Tue, Sep 10, 2019 at 05:58:53PM +0100, Raf Czlonka wrote:
> On Tue, Sep 10, 2019 at 05:53:34PM BST, Todd C. Miller wrote:
> > On Tue, 10 Sep 2019 16:56:42 +0100, Raf Czlonka wrote:
> >
> > > How about ditching dirname(1)?
> >
> > dirname(1) handles files in the root directory as well as files
On Tue, Sep 10, 2019 at 09:10:57AM -0600, Todd C. Miller wrote:
>
> Let's just skip that check when fcodes is "-".
>
I'am fine with it too.
ok semarie@
>
> Index: usr.bin/locate/locate/updatedb.sh
> ===
> RCS file: /cvs/src/usr.b
On Tue, Sep 10, 2019 at 09:10:57AM -0600, Todd C. Miller wrote:
> Let's just skip that check when fcodes is "-".
OK kn
On Tue, Sep 10, 2019 at 05:58:53PM +0100, Raf Czlonka wrote:
> FYI, what prompted me to use shell instead of dirname(1) is the
> recent removal of basename(1)[0] but it seems like the latter doesn't
> suffer from similar edge cases :^)
Correct, because we can expect dirname(1) to be sure when weekl
On Tue, Sep 10, 2019 at 11:51:09AM -0400, Kurt Mosiejczuk wrote:
> On Tue, Sep 10, 2019 at 09:10:57AM -0600, Todd C. Miller wrote:
>
> However, it looks like all that logic in weekly is unnecessary.
> It is largely a duplicate of what is alkready in updatedb.sh.
> updatedb.sh already traps more s
On Tue, Sep 10, 2019 at 05:53:34PM BST, Todd C. Miller wrote:
> On Tue, 10 Sep 2019 16:56:42 +0100, Raf Czlonka wrote:
>
> > How about ditching dirname(1)?
>
> dirname(1) handles files in the root directory as well as files
> with no directory correctly, your diff does not.
>
> E.g.
>
> FCODES=
On Tue, 10 Sep 2019 16:56:42 +0100, Raf Czlonka wrote:
> How about ditching dirname(1)?
dirname(1) handles files in the root directory as well as files
with no directory correctly, your diff does not.
E.g.
FCODES=/foo
${FCODES%/*} -> ""
dirname $FCODES -> "/"
FCODES=bar
${FCODES%/*} -> ""
dirn
On Tue, Sep 10, 2019 at 05:22:33PM +0100, Raf Czlonka wrote:
> > > As per below, only dirname(1), not the logic! :^)
> > > ${FCODES%/*} instead of $( dirname "${FCODES}" )
> > Is that portable outside of ksh? We had taken the non-ksh specific
> > route before to keep it portable. I see our sh(1)
On Tue, Sep 10, 2019 at 12:13:31PM -0400, Kurt Mosiejczuk wrote:
> On Tue, Sep 10, 2019 at 05:03:54PM +0100, Raf Czlonka wrote:
> > On Tue, Sep 10, 2019 at 04:58:19PM BST, Kurt Mosiejczuk wrote:
> > > On Tue, Sep 10, 2019 at 04:56:42PM +0100, Raf Czlonka wrote:
>
> > > > How about ditching dirname
On Tue, Sep 10, 2019 at 05:13:31PM BST, Kurt Mosiejczuk wrote:
> On Tue, Sep 10, 2019 at 05:03:54PM +0100, Raf Czlonka wrote:
> > On Tue, Sep 10, 2019 at 04:58:19PM BST, Kurt Mosiejczuk wrote:
> > > On Tue, Sep 10, 2019 at 04:56:42PM +0100, Raf Czlonka wrote:
>
> > > > How about ditching dirname(1
On Tue, Sep 10, 2019 at 05:03:54PM +0100, Raf Czlonka wrote:
> On Tue, Sep 10, 2019 at 04:58:19PM BST, Kurt Mosiejczuk wrote:
> > On Tue, Sep 10, 2019 at 04:56:42PM +0100, Raf Czlonka wrote:
> > > How about ditching dirname(1)?
> > File may not exist yet, in which case -w will be false, even if w
On Tue, Sep 10, 2019 at 04:58:19PM BST, Kurt Mosiejczuk wrote:
> On Tue, Sep 10, 2019 at 04:56:42PM +0100, Raf Czlonka wrote:
>
> > How about ditching dirname(1)?
>
> File may not exist yet, in which case -w will be false, even if we
> have permissions to create it.
As per below, only dirname(1)
On Tue, Sep 10, 2019 at 04:56:42PM +0100, Raf Czlonka wrote:
> How about ditching dirname(1)?
File may not exist yet, in which case -w will be false, even if we
have permissions to create it.
--Kurt
> Index: usr.bin/locate/locate/updatedb.sh
> ===
On Tue, Sep 10, 2019 at 04:10:57PM BST, Todd C. Miller wrote:
> On Tue, 10 Sep 2019 09:42:16 +0200, Sebastien Marie wrote:
>
> > the use of '-' is documented has a valid option, and weekly(8) uses it
> > in order to run locate.updatedb(8) has 'nobody' and have the output in
> > tempfile under /var
On Tue, Sep 10, 2019 at 09:10:57AM -0600, Todd C. Miller wrote:
> On Tue, 10 Sep 2019 09:42:16 +0200, Sebastien Marie wrote:
> > the use of '-' is documented has a valid option, and weekly(8) uses it
> > in order to run locate.updatedb(8) has 'nobody' and have the output in
> > tempfile under /var
On Tue, 10 Sep 2019 09:42:16 +0200, Sebastien Marie wrote:
> the use of '-' is documented has a valid option, and weekly(8) uses it
> in order to run locate.updatedb(8) has 'nobody' and have the output in
> tempfile under /var/db (place writable only by root).
>
> with the change, as weekly(8) run
Hi,
Last change on locate.updatedb(8) ensures that the file passed via --fcodes
option is in a writeable directory, and error out if it isn't. but it
doesn't allow anymore '-' (output on stdout).
the use of '-' is documented has a valid option, and weekly(8) uses it
in order to run locate.updated
18 matches
Mail list logo