Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow the specification of user and access permissions #8

Open
dspinellis opened this issue Jan 28, 2018 · 7 comments
Open

Allow the specification of user and access permissions #8

dspinellis opened this issue Jan 28, 2018 · 7 comments

Comments

@dspinellis
Copy link
Contributor

Currently one needs to be root in order to access the repository.

@vitsalis
Copy link
Member

What do you mean? On an Ubuntu machine I can create and access a mount directory without using the sudo command.

@dspinellis
Copy link
Contributor Author

[dds@snf-800019 ~]$ src/RepoFS/src/repofs.py src/RepoFS mnt
Examining repository.  Please wait..
Ready! Repository mounted in 0:00:00.086920
Repository src/RepoFS is now visible at mnt
fuse: failed to exec fusermount: No such file or directory
Traceback (most recent call last):
  File "src/RepoFS/src/repofs.py", line 455, in <module>
    main()
  File "src/RepoFS/src/repofs.py", line 452, in main
    FUSE(repo, args.mount, nothreads=True, foreground=True)
  File "/usr/local/lib/python2.7/dist-packages/fuse.py", line 480, in __init__
    raise RuntimeError(err)
RuntimeError: 1

@vitsalis
Copy link
Member

vitsalis commented Mar 1, 2018

This error is produced because on the _first_year method of gitoper.py, head_branch contains "branch.master.remote\nbranch.setup.remote\n". This happens because on that specific repository there exist two branches.

This issue can be fixed by only keeping one branch inside the head_branch variable (maybe the first one). But, how will we choose which one to keep? I suggest that we use master if more than one branches exist in the repository.

@dspinellis
Copy link
Contributor Author

Not sure why there is a problem with multiple branches. Most repos have multiple brnaches, right? We can use master if available as you suggest, printing a warning and providing an option to select the branch.

@vitsalis
Copy link
Member

vitsalis commented Mar 1, 2018

The issue arrises because we treat head_branch as if it contains only one branch. We already select master if head_branch is equal to None.

@dspinellis
Copy link
Contributor Author

Why do we need to select a branch? (Maybe it's better to discuss this over Skype; call me if you want.)

dspinellis added a commit that referenced this issue Mar 1, 2018
This fixes a problem in repos that lack a head branch.
PR: #8
@vitsalis
Copy link
Member

vitsalis commented Mar 22, 2018

I've changed the default access mode to be the same as the repository's mode in 7a344f2. The next step is to add a command line argument to specify access rights manually.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants