#778512 mr: "unknown repository type" if config file is a symlink

#778512#5
Date:
2015-02-16 02:35:09 UTC
From:
To:
Dear Maintainer,

   * What led up to the situation?

I would like to use multiple mrconfig files, so I created ~/.mrconfig-alt.
I created it as a symbolic link, like all my manually-curated dotfiles.

   * What exactly did you do (or not do) that was effective (or
     ineffective)?

In a clone of https://github.com/joeyh/myrepos/:

% mr -c ~/.mrconfig-alt register

   * What was the outcome of this action?

% mr -c ~/.mrconfig-alt register
mr register: unknown repository type
zsh: exit 255

   * What outcome did you expect instead?

I expected registration to succeed.  It succeeds if I delete the symbolic
link and re-create it as a normal file.

   * Additional information:

One workaround would be to replace the symbolic link by a hard link.

Simply passing the realpath of the symbolic link as the argument to the -c
option changes the meaning of the command in a manner that causes mr to fail
to find repositories,¹ so it's not a drop-in workaround.

The absolute path of the _target_ of the symlink is in ~/.mrtrust, and without
it there mr complains (as expected).  Having the absolute path of the symlink
itself in ~/.mrtrust makes no difference.

Possibly related: 'mr -c ~/.mrconfig-alt list' displays repositories listed in
either ~/.mrconfig or ~/.mrconfig-alt, instead of only repositories listed in
the latter.  This might be a separate problem.

Please let me know if I could provide additional information.

Thanks,

Daniel


¹ Changing '-c foobar' to '-c "$(realpath foobar)"' causes mr to interpret
relative paths in the ini section headers as relative to
`dirname(realpath(symlink))' rather than as relative to `dirname(symlink)'.

#778512#10
Date:
2024-06-26 03:28:50 UTC
From:
To:
Hi,

Nothing seems to have happened to this initiative in a long while. I
wonder if some sort of a hackathon would push it along?

I'm personally waiting for ftp.fi.debian.org to start pointing at
debian.web.trex.fi at long last...