Add Linkfile and Copyfile support to Manifest FS.

Change-Id: Iee24760742ffb3b5546c9b400c9fc5d314528733
3 files changed
tree: ce83953ba182e968d0d4dd2aa3257b6300addbe3
  1. cache/
  2. cmd/
  3. fs/
  4. gitiles/
  5. manifest/
  6. .gitignore
  7. CONTRIBUTING
  8. LICENSE
  9. README.md
README.md

This is a FUSE filesystem that provides light-weight, read-only checkouts of Android.

How to use

To start,

go install github.com/google/gitfs/cmd/gitfs-{multifs,expand-manifest}
gitfs-expand-manifest --gitiles https://android.googlesource.com/ \
   > /tmp/m.xml
mkdir /tmp/mnt
gitfs-multifs -cache /tmp/cache -gitiles https://android.googlesource.com/  /tmp/mnt &

then, in another terminal, execute

ln -s /tmp/m.xml /tmp/mnt/config/ws

To create a workspace “ws” corresponding to the manifest in m.xml.

Configuring

The FUSE file system clones repositories on-demand. You can avoid cloning altogether for repositories you know you don't need. This is configured through a JSON file.

For example, if you work on Android, and build on a Linux machine, you will never need the Darwin related prebuilts. You can avoid a costly clone for those by doing:

{"Repo": ".*darwin.*", "Clone": false}

Similarly, the build system system will read files (typically called ‘*.mk’) across the entire tree. When any .mk file is opened, this should not trigger a clone. This is achieved with the following entry

{"File": ".*mk$", "Clone": false}

Together, the following config.json file is a good start for working on android:

[{"Repo": ".*darwin.*", "Clone": false},
 {"File": ".*mk$", "Clone": true}]

DISCLAIMER

This is not an official Google product.