{"id":19235604,"url":"https://github.com/renyuneyun/projfs","last_synced_at":"2025-08-03T00:09:47.663Z","repository":{"id":38330625,"uuid":"217894912","full_name":"renyuneyun/projfs","owner":"renyuneyun","description":"Projection FileSystem is a FUSE filesystem performs directory content projection","archived":false,"fork":false,"pushed_at":"2023-04-03T19:48:53.000Z","size":65,"stargazers_count":10,"open_issues_count":3,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-03-02T05:36:31.019Z","etag":null,"topics":["fuse","fuse-filesystem","hacktoberfest"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/renyuneyun.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2019-10-27T18:03:29.000Z","updated_at":"2023-09-08T17:59:34.000Z","dependencies_parsed_at":"2024-02-01T15:01:55.888Z","dependency_job_id":null,"html_url":"https://github.com/renyuneyun/projfs","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/renyuneyun%2Fprojfs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/renyuneyun%2Fprojfs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/renyuneyun%2Fprojfs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/renyuneyun%2Fprojfs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/renyuneyun","download_url":"https://codeload.github.com/renyuneyun/projfs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223849357,"owners_count":17213673,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["fuse","fuse-filesystem","hacktoberfest"],"created_at":"2024-11-09T16:17:31.105Z","updated_at":"2024-11-09T16:17:31.761Z","avatar_url":"https://github.com/renyuneyun.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ***Proj***ection ***F***ile***S***ystem [![Build Status](https://travis-ci.org/renyuneyun/projfs.svg?branch=master)](https://travis-ci.org/renyuneyun/projfs)\n- - - - - - -\n\nProjFS is a FUSE filesystem aiming at providing a general way of doing filesystem projection: project directories and files to a new mount point by converting specified files through a custom projection command.\n\nIt can provide use cases such as automatically converting audio files while keeping the original file.\n\n# Build\n\nThis project is written in Rust, so just follow the standard way how a Rust application is built:\n\n```\ncargo build\n```\n\n# Usage\n\n## Basic usage\n\n```\nprojfs \u003csource\u003e \u003cmountpoint\u003e\n```\n\nThe `\u003cmountpoint\u003e` is where the new projected filesystem hierarchy will appear. It is (apparently) read-only.\n\nBy default, the program performs the projection by using `ffmpeg` to convert every audio and video file to `ogg` file (audio) (unless it's `ogg` audio already).\n\nIt identifies files by MIME type (using the `mime_guess` crate). All files are provided as-is except for `audio/*` and `video/*` files which are going to be projected. The command used to convert is `ffmpeg -i \u003coriginal_file\u003e -vn \u003coutput_file\u003e`. File suffix is changed to `ogg` where applicable.\n\n## Advanced usage\n\nPlease see the help document using:\n\n```\nprojfs --help\n```\n\nAn example projection specification is available in `example_projection.yml`. It also corresponds to the default behaviour. See the next section for a detailed explanation of the projection specification.\n\n# Projection Configuration\n\nAn example projection configuration file is placed under `example_projection.yml`, which is the same as not specifying a projection configuration file. The detail of the schema is explained here.\n\n\u003e The `configuration-schema.owl` file is an ontology describing the schema (i.e. the same as below). RDF/OWL may be promoted to one of the acceptable configuration file types in the future.\n\nThe configuration uses YAML format. The acceptable keys are specified below. Every key is mandatory unless marked as `[optional]`.\n\n- `mime_types`: a list of strings\n    File matching mime types specified here will be converted using the `projection_command`, unless it's specified in `ignored_mime_types`.\n    Each string is either a `mime type` (e.g. `audio/ogg`), or a wildcard of mime types (e.g. `audio/*`). Specifically, shorthand of wildcard (e.g. `audio`, or `audio/`) is accepted, but not encouraged.\n- `ignored_mime_types`: [optional] a list of strings\n    The mime types specified here will not be converted.\n    The acceptable values are the same as `mime_type`.\n- `name_mapping`: a string\n    The string is the new suffix which the converted file will have. It will replace the original file suffix if any (e.g. `file1.wav` -\u003e `file1.ogg` if `ogg` is specified here).\n- `projection_command`: a string\n    The string specifies the command used to do the conversion. It can accept two varirables, `{input}` and `{output}`: Each will be replaced with the corresponding source file path (`{input}`) and output (cache) file path (`{output}`).\n    The string will be separated by space and passed to `Command` module. That means there should not be escaped spaces (i.e. `\\ `), quoted spaced (e.g. `\" qwe\"`), etc. Were there any needs to use them, you can write your own script and point to it from here.\n\n\n# TODO\n\n* [x] Having a default cache dir\n* [x] Copying file attributes from source file (except for size)\n* [x] Different cache dirs for different source dirs\n* [x] Update cache only when necessary\n* [ ] Return placeholder information for files under-projection\n* [x] Accept configuration\n    * [x] Custom filetype\n    * [x] Custom projection command\n    * [ ] A list of configurations\n* [ ] One-to-many projection\n* [ ] Background automatic async cache\n* [ ] Update cache while running\n* [ ] Validate configuration before loading\n\n# License\n\nExcept for certain files specified afterwards, this project is licensed under the [Apache 2.0 License](http://www.apache.org/licenses/LICENSE-2.0) as stated below.\n\n## Copyright notice\n\nCopyright 2019 renyuneyun (Rui Zhao)\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\n## Exception\n\nThe following files under the source directory (`src/`) are directly obtained from the [fuse-mt](https://github.com/wfraser/fuse-mt) project ([commit](https://github.com/wfraser/fuse-mt/tree/97e115667682b4a7e54c1831360b8c572c667db3/example/src)), licensed under Apache 2.0 license and MIT license:\n\n* `libc_bridge/libc_extras.rs`\n* `libc_bridge/libc_bridge.rs`\n\nThe `projfs.rs` and `libc_bridge/mod.rs` files contain unmodified code from [fuse-mt](https://github.com/wfraser/fuse-mt/blob/97e115667682b4a7e54c1831360b8c572c667db3/example/src/passthrough.rs).\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frenyuneyun%2Fprojfs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frenyuneyun%2Fprojfs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frenyuneyun%2Fprojfs/lists"}