Skip to content

Commands only work in project root #52

Description

@gchronis

If you try to run git secure-fetch in a subdirectory of a git repo,you enter into a dreaded infinite loop:

Committing inital entries to RSL branch.
<---- GPG signature required.
fatal: Unable to read current working directory: No such file or directory
Pushing the rsl ... 
rsl push failed !!
fatal: Unable to read current working directory: No such file or directory
fatal: Unable to read current working directory: No such file or directory
Intializing the rsl ...
fatal: Unable to read current working directory: No such file or directory
fatal: Unable to read current working directory: No such file or directory
dd: failed to open '1': No such file or directory
fatal: Unable to read current working directory: No such file or directory
Committing inital entries to RSL branch.
<---- GPG signature required.
fatal: Unable to read current working directory: No such file or directory
Pushing the rsl ... 
rsl push failed !!
fatal: Unable to read current working directory: No such file or directory
fatal: Unable to read current working directory: No such file or directory
Intializing the rsl ...
fatal: Unable to read current working directory: No such file or directory
fatal: Unable to read current working directory: No such file or directory
dd: failed to open '1': No such file or directory
fatal: Unable to read current working directory: No such file or directory
Committing inital entries to RSL branch.
<---- GPG signature required.
fatal: Unable to read current working directory: No such file or directory
Pushing the rsl ... 
rsl push failed !!
fatal: Unable to read current working directory: No such file or directory
fatal: Unable to read current working directory: No such file or directory
Intializing the rsl ...
fatal: Unable to read current working directory: No such file or directory
fatal: Unable to read current working directory: No such file or directory
dd: failed to open '1': No such file or directory
fatal: Unable to read current working directory: No such file or directory
Committing inital entries to RSL branch.
<---- GPG signature required.

You can imagine where it goes from there.

The commands try to read and write files in the directory above, and gets confused when they do not exist in the current directory.

Solutions to this problem include the easy way:

  • Move to the root directory to do the rsl file manipulation and then move back down when done, to leave the repo in the initial state. OR be consistent about reading and writing to paths that are relative to to the project root or absolute paths, rather than relative to the cwd

and the right way

  • don't use files to record/represent the RSL. Use git objects, notes, or commits instead.

If the right way involves a major rehaul of the scripts, we may want to do the easy fix in the interim.

NB: only secure-fetch, secure-pull, and secure-push need to be updated, as the other commands don't alter the rsl directly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions