gitfs is a FUSE file system that fully integrates with git - Version controlled file system

Overview

gitfs Build Status Coverage Status PyPI

Welcome to GitFS

gitfs is a FUSE file system that fully integrates with git. You can mount a remote repository's branch locally, and any subsequent changes made to the files will be automatically committed to the remote.

gitfs was developed by the awesome engineering team at Presslabs, a Managed WordPress Hosting provider.

What's its purpose?

gitfs was designed to bring the full powers of git to everyone, no matter how little they know about versioning. A user can mount any repository and all their changes will be automatically converted into commits. gitfs will also expose the history of the branch you're currently working on by simulating snapshots of every commit.

gitfs is useful in places where you want to keep track of all your files, but at the same time you don't have the possibility of organizing everything into commits yourself. A FUSE filesystem for git repositories, with local cache.

Installing

We provide packages for the major Ubuntu releases and MacOS, but you can find community packages for most of popular Linux distributions. If you want to build packages for a distribution, or you already did, please contact us and we'll list it here.

Ubuntu 18.04+

sudo add-apt-repository ppa:presslabs/gitfs
sudo apt-get update
sudo apt-get install gitfs

MacOS

brew install gitfs

Pip

We also publish a package to PyPI, which can be installed via pip using the following commmand:

pip install gitfs

Usage

You can mount a remote or local repository easly, just by providing the repository to clone and a directory used to mount.

gitfs http://your.com/repository.git /mount/directory

The entire filesystem can be tweaked when mounting it, using a set of options.

gitfs [email protected]:user/repo.git /mypath -o
repo_path=/tmp/path,branch=dev,log=-,debug=true,foreground=true,fetch_timeout=0.1,merge_timeout=0.1...

For an entire list of options, you can check the arguments page.

Features

  • Automatically commits changes: create, delete, update files and their metadata
  • Browse through working index and commit history
  • Merges with upstream by automatically accepting local changes
  • Caching commits reduces the memory footprint and speeds up navigation
  • Reduces the number of pushes by batching commits

Development

You can find more documentation on gitfs homepage.

Contributing

Development of gitfs happens at http://github.com/presslabs/gitfs.

Issues are tracked at http://github.com/presslabs/gitfs/issues.

The Python package can be found at https://pypi.python.org/pypi/gitfs/.

You are highly encouraged to contribute with code, tests, documentation or just sharing experience.

Please see CONTRIBUTING.md.

License

This project is licensed under Apache 2.0 license. Read the LICENSE file in the top distribution directory for the full license text.

Comments
  • Can't install on OS X 10.11

    Can't install on OS X 10.11

    I'm having issues installing gitfs on OS X 10.11

    Logs: https://gist.github.com/kaendfinger/4275d68ac2bf1817492b

    Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

    opened by azenla 16
  • Port to python3 [$20]

    Port to python3 [$20]

    Gitfs was written using only Python 2 code, but now, as the things in Python 3 evolves and are very stable, we need to port our Python 2 code to Python 3 compatible code.

    Did you help close this issue? Go claim the $20 bounty on Bountysource.

    bounty 
    opened by vtemian 7
  • Fix installation issues due to outdated deps

    Fix installation issues due to outdated deps

    This fixes pip installation and the associated installation issues:

    • https://github.com/PressLabs/gitfs/issues/273
    • https://github.com/PressLabs/gitfs/issues/271
    • https://github.com/PressLabs/gitfs/issues/268
    • https://github.com/PressLabs/gitfs/issues/267
    opened by nikvdp 5
  • [mac os x sierra] raven==5.27.0 distribution was not found and is required by gitfs

    [mac os x sierra] raven==5.27.0 distribution was not found and is required by gitfs

    $ brew --version
    Homebrew 1.2.4
    Homebrew/homebrew-core (git revision ff3c; last commit 2017-07-06)
    $ uname -mrs
    Darwin 16.6.0 x86_64
    $ brew cask install osxfuse
    # success
    $ brew install gitfs
    # success
    $ gitfs http://52.64.121.123/issues.git issues
    Traceback (most recent call last):
      File "/usr/local/bin/gitfs", line 6, in <module>
        from pkg_resources import load_entry_point
      File "/usr/local/Cellar/gitfs/0.4.5.1/libexec/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3036, in <module>
        @_call_aside
      File "/usr/local/Cellar/gitfs/0.4.5.1/libexec/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3020, in _call_aside
        f(*args, **kwargs)
      File "/usr/local/Cellar/gitfs/0.4.5.1/libexec/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3049, in _initialize_master_working_set
        working_set = WorkingSet._build_master()
      File "/usr/local/Cellar/gitfs/0.4.5.1/libexec/lib/python2.7/site-packages/pkg_resources/__init__.py", line 654, in _build_master
        ws.require(__requires__)
      File "/usr/local/Cellar/gitfs/0.4.5.1/libexec/lib/python2.7/site-packages/pkg_resources/__init__.py", line 968, in require
        needed = self.resolve(parse_requirements(requirements))
      File "/usr/local/Cellar/gitfs/0.4.5.1/libexec/lib/python2.7/site-packages/pkg_resources/__init__.py", line 854, in resolve
        raise DistributionNotFound(req, requirers)
    pkg_resources.DistributionNotFound: The 'raven==5.27.0' distribution was not found and is required by gitfs
    
    opened by khoan 5
  • pygit2 version needs to be bumped

    pygit2 version needs to be bumped

    pygit2 0.26.0 adds support for libgit2 0.26.0, so the version in requirements.txt should be bumped so that gitfs doesn't conflict with the latest libgit2.

    Cf. https://github.com/Homebrew/homebrew-core/pull/14731

    As a side note, fusepy 2.0.4 is also available now.

    opened by ilovezfs 4
  • Port to python3

    Port to python3

    OK, Python 3.4 support works fine. It would be cool to have it test for Python 2.7 as well at some point. Are you planning to support Python 2 long term?

    opened by justuswilhelm 4
  • Installation error: Command

    Installation error: Command "python setup.py egg_info" failed with error code 1

    Encountering this installation error on macOS Sierra:

    Stians-Mac-mini:~ stian$ brew install homebrew/fuse/gitfs
    ==> Installing gitfs from homebrew/fuse
    ==> Using the sandbox
    ==> Downloading https://github.com/PressLabs/gitfs/archive/0.4.5.1.tar.gz
    Already downloaded: /Users/stian/Library/Caches/Homebrew/gitfs-0.4.5.1.tar.gz
    ==> Downloading https://files.pythonhosted.org/packages/5c/79/5dae7494b9f5ed061cff9a8ab8d6e1f02db352f3facf907d9eb614fb80e9/virtualenv-15.0.2.tar.gz
    Already downloaded: /Users/stian/Library/Caches/Homebrew/gitfs--homebrew-virtualenv-15.0.2.tar.gz
    ==> python -c import setuptools... --no-user-cfg install --prefix=/tmp/gitfs--homebrew-virtualenv-20170105-62989-mbq7ql/target --single-version-externally-managed --record=installed.txt
    ==> python -s /tmp/gitfs--homebrew-virtualenv-20170105-62989-mbq7ql/target/bin/virtualenv -p python /usr/local/Cellar/gitfs/0.4.5.1/libexec
    ==> Downloading https://files.pythonhosted.org/packages/86/8c/70aea8215c6ab990f2d91e7ec171787a41b7fbc83df32a067ba5d7f3324f/atomiclong-0.1.1.tar.gz
    Already downloaded: /Users/stian/Library/Caches/Homebrew/gitfs--atomiclong-0.1.1.tar.gz
    ==> /usr/local/Cellar/gitfs/0.4.5.1/libexec/bin/pip install -v --no-deps --no-binary :all: --ignore-installed /private/tmp/gitfs--atomiclong-20170105-62989-1ngho46/atomiclong-0.1.1
    Last 15 lines from /Users/stian/Library/Logs/Homebrew/gitfs/03.pip:
      File "/usr/local/Cellar/gitfs/0.4.5.1/libexec/lib/python2.7/site-packages/pip/commands/install.py", line 335, in run
        wb.build(autobuilding=True)
      File "/usr/local/Cellar/gitfs/0.4.5.1/libexec/lib/python2.7/site-packages/pip/wheel.py", line 749, in build
        self.requirement_set.prepare_files(self.finder)
      File "/usr/local/Cellar/gitfs/0.4.5.1/libexec/lib/python2.7/site-packages/pip/req/req_set.py", line 380, in prepare_files
        ignore_dependencies=self.ignore_dependencies))
      File "/usr/local/Cellar/gitfs/0.4.5.1/libexec/lib/python2.7/site-packages/pip/req/req_set.py", line 634, in _prepare_file
        abstract_dist.prep_for_dist()
      File "/usr/local/Cellar/gitfs/0.4.5.1/libexec/lib/python2.7/site-packages/pip/req/req_set.py", line 129, in prep_for_dist
        self.req_to_install.run_egg_info()
      File "/usr/local/Cellar/gitfs/0.4.5.1/libexec/lib/python2.7/site-packages/pip/req/req_install.py", line 439, in run_egg_info
        command_desc='python setup.py egg_info')
      File "/usr/local/Cellar/gitfs/0.4.5.1/libexec/lib/python2.7/site-packages/pip/utils/__init__.py", line 707, in call_subprocess
        % (command_desc, proc.returncode, cwd))
    InstallationError: Command "python setup.py egg_info" failed with error code 1 in /private/tmp/pip-zmQCsP-build/
    
    READ THIS: https://git.io/brew-troubleshooting
    
    Stians-Mac-mini:~ stian$ 
    
    opened by stianhoiland 3
  • SyncWorker fails silently

    SyncWorker fails silently

    Sometimes, under suspect circumstances, SyncWorker will fail and no synchronization will be done.

    Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

    opened by vtemian 3
  • Misaligned code bug

    Misaligned code bug

    Hi guys,

    I was just checking out the source code, coming from BountySource. I noticed on lines 446 - 462, the code is not indented. They are referencing first_commit and second_commit which are only defined within the loop.

    Let me know if this is correct and I'll fire away a PR.

    ~ Daniel

    opened by daniellockyer 3
  • Bugs bounty [$10]

    Bugs bounty [$10]

    We want to make gitfs as stable as possible, so we are in search for bugs. We'll add a bounty on bountysource.com for each discovered bug.

    There is a $10 open bounty on this issue. Add to the bounty at Bountysource.

    bounty easy 
    opened by vtemian 3
  • Log exception messages on failures

    Log exception messages on failures

    For example when a fetch fails, it only logs Fetch failed without a reason. We should log exceptions with log.exception(message). This would make debugging errors much more easy.

    This I found to be the case only on FetchWorker.

    bug 
    opened by calind 3
  • Can't install

    Can't install

    Hi, doesn't install in newer ubuntu with the commands you give.

    installing with brew, running gives this error.

    Traceback (most recent call last): File "/home/linuxbrew/.linuxbrew/bin/gitfs", line 33, in sys.exit(load_entry_point('gitfs==0.5.1', 'console_scripts', 'gitfs')()) File "/home/linuxbrew/.linuxbrew/Cellar/gitfs/0.5.2_9/libexec/lib/python3.9/site-packages/gitfs/init.py", line 19, in mount from gitfs.mounter import start_fuse File "/home/linuxbrew/.linuxbrew/Cellar/gitfs/0.5.2_9/libexec/lib/python3.9/site-packages/gitfs/mounter.py", line 22, in from pygit2.remote import RemoteCallbacks ImportError: cannot import name 'RemoteCallbacks' from 'pygit2.remote' (/home/linuxbrew/.linuxbrew/Cellar/gitfs/0.5.2_9/libexec/lib/python3.9/site-packages/pygit2/remote.py)

    opened by nkh 0
  • Python atomiclong seems to be discontinued

    Python atomiclong seems to be discontinued

    I was just looking through the dependencies and noticed that the atomiclong dependency (requirements.txt) seems to be discontinued with the developer saying not to use it. I'm not sure if this recommendation is because they wish to no longer maintain it or if there are underlying issues, does anyone have any input or awareness involving this?

    opened by Doom4535 0
  • Python 3.10: MutableMapping has moved to collections.abc

    Python 3.10: MutableMapping has moved to collections.abc

    https://docs.python.org/3/whatsnew/3.10.html#removed bullet eight...

    • Remove deprecated aliases to Collections Abstract Base Classes from the collections module. (Contributed by Victor Stinner in bpo-37324.)

    Related to Homebrew/homebrew-core#90923

    opened by cclauss 1
Releases(0.5.2)
Owner
Presslabs
Smart Managed WordPress Hosting
Presslabs
Here is some Python code that allows you to read in SVG files and approximate their paths using a Fourier series.

Here is some Python code that allows you to read in SVG files and approximate their paths using a Fourier series. The Fourier series can be animated and visualized, the function can be output as a tw

Alexander 12 Jan 01, 2023
Object-oriented file system path manipulation

path (aka path pie, formerly path.py) implements path objects as first-class entities, allowing common operations on files to be invoked on those path

Jason R. Coombs 1k Dec 28, 2022
A JupyterLab extension that allows opening files and directories with external desktop applications.

A JupyterLab extension that allows opening files and directories with external desktop applications.

martinRenou 0 Oct 14, 2021
Sheet Data Image/PDF-to-CSV Converter

Sheet Data Image/PDF-to-CSV Converter

Quy Truong 5 Nov 22, 2021
Python library and shell utilities to monitor filesystem events.

Watchdog Python API and shell utilities to monitor file system events. Works on 3.6+. If you want to use Python 2.6, you should stick with watchdog

Yesudeep Mangalapilly 5.6k Jan 04, 2023
gitfs is a FUSE file system that fully integrates with git - Version controlled file system

gitfs is a FUSE file system that fully integrates with git. You can mount a remote repository's branch locally, and any subsequent changes made to the files will be automatically committed to the rem

Presslabs 2.3k Jan 08, 2023
A simple file sharing tool written in python

Share it A simple file sharing tool written in python Installation If you are using Windows os you can directly Run .exe file -- download If you are

Sachit Yadav 7 Dec 16, 2022
fast change directory with python and ruby

fcdir fast change directory with python and ruby run run python script , chose drirectoy and change your directory need you need python and ruby deskt

XCO 2 Jun 20, 2022
Uncompress DEFLATE streams in pure Python

stream-inflate Uncompress DEFLATE streams in pure Python. Installation pip install stream-inflate Usage from stream_inflate import stream_inflate impo

Michal Charemza 7 Oct 13, 2022
This project is a set of programs that I use to create a README.md file.

🤖 codex-readme 📜 codex-readme What is it? This project is a set of programs that I use to create a README.md file. How does it work? It reads progra

Tom Dörr 224 Jan 07, 2023
This program can help you to move and rename many files at once

This program can help you to rename and save many files in a folder in seconds, but don't give the same name to files, it can delete both files.

João Assalim 1 Oct 10, 2022
FUSE filesystem Python scripts for Nintendo console files

ninfs (formerly fuse-3ds) is a FUSE program to extract data from Nintendo game consoles. It works by presenting a virtual filesystem with the contents of your games, NAND, or SD card contents, and yo

Ian Burgwin 343 Jan 02, 2023
QSynthesis is a Python3 API to perform I/O based program synthesis of bitvector expressions.

QSynthesis is a Python3 API to perform I/O based program synthesis of bitvector expressions. It aims at facilitating code deobfuscation. The algorithm is greybox approach combining both a blackbox I/

Quarkslab 103 Dec 30, 2022
A simple bulk file renamer, written in python.

Python File Editor A simple bulk file renamer, written in python. There are two functions, the bulk rename and the bulk file extention change. Bulk Fi

Sam Bloomfield 2 Dec 22, 2021
Various converters to convert value sets from CSV to JSON, etc.

ValueSet Converters Tools for converting value sets in different formats. Such as converting extensional value sets in CSV format to JSON format able

Health Open Terminology Ecosystem 4 Sep 08, 2022
useful files for the Freenove Big Hexapod

FreenoveBigHexapod useful files for the Freenove Big Hexapod HexaDogPos is a utility for converting the Freenove xyz co-ordinate system to servo angle

Alex 2 May 28, 2022
Lumar - Smart File Creator

Lumar is a free tool for creating and managing files. With Lumar you can quickly create any type of file, add a file content and file size. With Lumar you can also find out if Photoshop or other imag

Paul - FloatDesign 3 Dec 10, 2021
This is a file deletion program that asks you for an extension of a file (.mp3, .pdf, .docx, etc.) to delete all of the files in a dir that have that extension.

FileBulk This is a file deletion program that asks you for an extension of a file (.mp3, .pdf, .docx, etc.) to delete all of the files in a dir that h

Enoc Mena 1 Jun 26, 2022
PyDeleter - delete a specifically formatted file in a directory or delete all other files

PyDeleter If you want to delete a specifically formatted file in a directory or delete all other files, PyDeleter does it for you. How to use? 1- Down

Amirabbas Motamedi 1 Jan 30, 2022
Publicly Open Amazon AWS S3 Bucket Viewer

S3Viewer Publicly open storage viewer (Amazon S3 Bucket, Azure Blob, FTP server, HTTP Index Of/) s3viewer is a free tool for security researchers that

Sharon Brizinov 377 Dec 02, 2022