diff options
Diffstat (limited to 'filesystems/gitfs')
-rw-r--r-- | filesystems/gitfs/Makefile | 45 | ||||
-rw-r--r-- | filesystems/gitfs/distinfo | 3 | ||||
-rw-r--r-- | filesystems/gitfs/files/patch-gitfs_utils_args.py | 36 | ||||
-rw-r--r-- | filesystems/gitfs/pkg-descr | 3 |
4 files changed, 87 insertions, 0 deletions
diff --git a/filesystems/gitfs/Makefile b/filesystems/gitfs/Makefile new file mode 100644 index 000000000000..d943f6188d14 --- /dev/null +++ b/filesystems/gitfs/Makefile @@ -0,0 +1,45 @@ +PORTNAME= gitfs +DISTVERSION= 0.5.2 +PORTREVISION= 2 +CATEGORIES= filesystems devel +PKGNAMEPREFIX= fusefs- + +MAINTAINER= ports@FreeBSD.org +COMMENT= Version controlled file system +WWW= https://www.presslabs.com/code/gitfs/ + +LICENSE= APACHE20 +LICENSE_FILE= ${WRKSRC}/LICENSE + +DEPRECATED= Abandonware, last release on 2019 +EXPIRATION_DATE=2024-12-31 + +RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}atomiclong>=0.1.1:devel/py-atomiclong@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}cffi>=1.12.3:devel/py-cffi@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}fusepy>=3.0.1:filesystems/py-fusepy@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}pycparser>=2.19:devel/py-pycparser@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}pygit2>=0.28.2:devel/py-pygit2@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}raven>=6.10.0:devel/py-raven@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}six>=1.12.0:devel/py-six@${PY_FLAVOR} +TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pytest>=4.6.5:devel/py-pytest@${PY_FLAVOR} + +USE_GITHUB= yes +GH_ACCOUNT= PressLabs + +NO_ARCH= yes +USES= python +USE_PYTHON= autoplist distutils concurrent optsuffix + +post-patch: + @${REINPLACE_CMD} -e 's/==/>=/' ${WRKSRC}/*requirements.txt + +# XXX Integrations tests want MOUNT_PATH, REPO_* passed via TEST_ENV +do-test: + @(cd ${TEST_WRKSRC} && ${SETENV} ${TEST_ENV} ${PYTHON_CMD} -m pytest) + +post-patch: patch-py3k-mock +patch-py3k-mock: + @${GREP} -Flr 'mock import' ${WRKSRC} | ${XARGS} ${REINPLACE_CMD} \ + -i .bak.mock -e 's/mock import/unittest.&/' + +.include <bsd.port.mk> diff --git a/filesystems/gitfs/distinfo b/filesystems/gitfs/distinfo new file mode 100644 index 000000000000..a44e0ec16308 --- /dev/null +++ b/filesystems/gitfs/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1571569210 +SHA256 (PressLabs-gitfs-0.5.2_GH0.tar.gz) = 921e24311e3b8ea3a5448d698a11a747618ee8dd62d5d43a85801de0b111cbf3 +SIZE (PressLabs-gitfs-0.5.2_GH0.tar.gz) = 64141 diff --git a/filesystems/gitfs/files/patch-gitfs_utils_args.py b/filesystems/gitfs/files/patch-gitfs_utils_args.py new file mode 100644 index 000000000000..bc4d1d42d80d --- /dev/null +++ b/filesystems/gitfs/files/patch-gitfs_utils_args.py @@ -0,0 +1,36 @@ +https://github.com/PressLabs/gitfs/issues/258 +https://github.com/PressLabs/gitfs/issues/257 + +--- gitfs/utils/args.py.orig 2019-10-20 11:00:10 UTC ++++ gitfs/utils/args.py +@@ -44,7 +44,7 @@ class Args(object): + ("foreground", (False, "bool")), + ("branch", ("master", "string")), + ("allow_other", (False, "bool")), +- ("allow_root", (True, "bool")), ++ ("allow_root", (False, "bool")), + ("commiter_name", (self.get_commiter_user, "string")), + ("commiter_email", (self.get_commiter_email, "string")), + ("max_size", (10, "float")), +@@ -76,12 +76,6 @@ class Args(object): + return self.check_args(self.set_defaults(args)) + + def check_args(self, args): +- # check allow_other and allow_root +- if args.allow_other: +- args.allow_root = False +- else: +- args.allow_root = True +- + # check log_level + if args.debug: + args.log_level = "debug" +@@ -182,7 +176,7 @@ class Args(object): + return "{}@{}".format(args.user, socket.gethostname()) + + def get_repo_path(self, args): +- return tempfile.mkdtemp(dir="/var/lib/gitfs") ++ return tempfile.mkdtemp(prefix="gitfs") + + def get_ssh_key(self, args): + return os.environ["HOME"] + "/.ssh/id_rsa" diff --git a/filesystems/gitfs/pkg-descr b/filesystems/gitfs/pkg-descr new file mode 100644 index 000000000000..ce7e2bf5144f --- /dev/null +++ b/filesystems/gitfs/pkg-descr @@ -0,0 +1,3 @@ +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. |