1
0
Fork 0
forked from glenux/mfm
🟢 🔁 | Simple command-line helper for FUSE filesystems (sshfs, gocryptfs, etc.)
Find a file
2024-02-12 11:53:49 +01:00
.reuse fix: add SPDX headers 2023-10-25 14:07:15 +02:00
doc doc: update example config to demonstrate templating 2023-11-24 17:02:17 +01:00
LICENSES fix: add SPDX headers 2023-10-25 14:07:15 +02:00
scripts fix: split vagrant provisioning into multiple parts 2023-11-02 16:55:29 +01:00
spec feat: add basic support for spec 2024-01-15 02:06:28 +01:00
src fix: implement config init 2024-01-24 14:13:29 +01:00
static feat: prepare (empty) files for completion and sample config 2024-01-24 00:06:28 +01:00
.code_preloader.yml fix: update code_preloader ignore list 2024-01-24 00:07:29 +01:00
.drone.yml ci: bump crystal version 2024-01-09 22:32:22 +01:00
.gitattributes doc: add asciinema demo recording as lfs 2023-10-25 14:04:28 +02:00
.gitignore chore: ignore _* files/dirs 2024-01-15 02:05:07 +01:00
.tool-versions chore: pin crystal version with tool-versions 2023-11-21 00:33:37 +01:00
Makefile fix: change binary name 2024-01-24 01:25:44 +01:00
README.md doc: add stupid comment for demo 2024-02-12 11:53:49 +01:00
shard.lock fix: implement config init 2024-01-24 14:13:29 +01:00
shard.yml fix: implement config init 2024-01-24 14:13:29 +01:00
Vagrantfile fix: split vagrant provisioning into multiple parts 2023-11-02 16:55:29 +01:00

Build Status License LGPL3.0-or-later Donate on patreon

This project is available on our self-hosted server and on CodeBerg and GitHub as mirrors. For the latest updates and comprehensive version of our project, please visit our primary repository at: https://code.apps.glenux.net/glenux/mfm.

Minimalist Fuse Manager (MFM)

MFM is a Crystal-lang CLI designed to streamline the management of various FUSE filesystems, such as sshfs, gocryptfs, httpdirfs, and more. Through its user-friendly interface, users can effortlessly mount and unmount filesystems, get real-time filesystem status, and handle errors proficiently.

Prerequisites & Dependencies

Before using MFM, make sure the following tools are installed on your system:

For Debian/Ubuntu you can use the following command:

$ sudo apt-get update && sudo apt-get install libpcre3 libevent-2.1-7 fzf gocryptfs httpdirfs sshfs

Building from source

To build from source, you'll also need:

For Debian/Ubuntu you can use the following command:

$ sudo apt-get update && sudo apt-get install libpcre3-dev libevent-2.1-dev make

Installation

1. From Source

To get started with MFM, ensure that you have the prerequisites installed on your system (see above).

Then follow these steps to install:

git clone https://code.apps.glenux.net/glenux/mfm
cd mfm
make prepare
make build
sudo make install                 # either to install system-wide
make install PREFIX=$HOME/.local  # or to install as a user

2. Binary Download

Alternatively, download a pre-compiled binary version of MFM.

Usage

Command Line Options

Global

Usage: mfm [options]

Global options
    -c, --config FILE                Set configuration file
    -v, --verbose                    Set more verbosity
    -o, --open                       Automatically open directory after mount
    --version                        Show version
    -h, --help                       Show this help

Commands (not implemented yet):
    config                           Manage configuration file
    mapping                          Manage filesystems

Config management

Usage: mfm filesystem [options]

Global options
    -c, --config FILE                Set configuration file
    -v, --verbose                    Set more verbosity
    -o, --open                       Automatically open directory after mount
    --version                        Show version
    -h, --help                       Show this help

Commands (not implemented yet):
    init                             Create init file

Filesystem management

Usage: mfm mapping [options]

Global options
    -c, --config FILE                Set configuration file
    -v, --verbose                    Set more verbosity
    -o, --open                       Automatically open directory after mount
    --version                        Show version
    -h, --help                       Show this help

Commands (not implemented yet):
    list                             List fuse mappings
    create                           Create new fuse mapping
    edit                             Edit fuse mapping
    delete                           Create new fuse mapping

Demo

Configuration

MFM uses a YAML configuration file, typically found at ~/.config/mfm.yml, to detail the filesystem names, types, and respective configurations.

YAML File Format

---
version: "1"

global:
  mountpoint: "{{env.HOME}}/mnt"

filesystems:
  - type: "gocryptfs"
    name: "Work - SSH Keys"
    encrypted_path: "/home/user/.ssh/keyring.work.vault"

  - type: "sshfs"
    name: "Personal - Media Server"
    remote_user: "{{env.USER}}"
    remote_host: "mediaserver.local"
    remote_path: "/mnt/largedisk/music"
    remote_port: 22

  - type: httpdirfs
    name: "Debian Repository"
    url: "http://ftp.debian.org/debian/"

  # Add more filesystems as needed

Contribution Guidelines

Contributing to MFM:

  1. Fork the Repository: Start by forking MFM's repository.
  2. Create a Feature Branch: Develop each feature or fix in its own branch.
  3. Commit Changes: Provide clear and informative commit messages.
  4. Run Tests: Ensure that all features are operational.
  5. Push to Your Fork: Push your changes to your fork on GitHub.
  6. Submit a Pull Request: Begin a pull request to the main repository and explain your changes.
  7. Review: Await feedback from the maintainers and respond as necessary.

By contributing, you agree to our code of conduct and license terms.

Authors and Contributors

  • Glenn Y. Rolland - Initial Work

Inspired By

License

GNU GPL-3