fuga 0.0.2

A CLI tool to operate files or directories in 2 steps.
fuga-0.0.2 is not a library.
Visit the last successful build: fuga-1.1.0

Crates.io Crates.io build

๐Ÿ“ฆ FUGA ๐Ÿ“ฆ

A CLI tool to operate files or directories in 2 steps.

ๆ—ฅๆœฌ่ชžใฎREADMEใฏใ“ใกใ‚‰

๐Ÿ“ฆ DESCRIPTION

  • fuga is a CLI tool that performs file operations in two steps.
  • Developed as an alternative to commands like mv, cp, and ln.
  • Mark files or directories to operate on using fuga mark, and then perform copy or move operations after navigating to another directory.

๐Ÿ“ฆ INSTALLATION

Pre-built Binaries

  • Pre-built binaries for the following architectures are available on releases.

    • aarch64-apple-darwin (Mac - Apple Chip)
    • x86_64-apple-darwin (Mac - Intel Chip)
    • x86_64-unknown-linux-gnu (Linux - Intel Chip)
  • Place the binary for your architecture in a directory included in your system's PATH.

Build with Cargo

  • You can install fuga by building it using the cargo command.
cargo install fuga

Verify Installation

  • If the installation is successful, the version information can be displayed using the following command:
$ fuga -V
fuga v0.0.1

๐Ÿ“ฆ USAGE

USAGE:
    fuga <SUBCOMMAND>

OPTIONS:
    -h, --help       Print help information
    -V, --version    Print version information

SUBCOMMANDS:
    copy       Copy the marked file or directory
    help       Print this message or the help of the given subcommand(s)
    link       Make a symbolic link to the marked file or directory
    mark       Set the path of the target file or directory
    move       Move the marked file or directory
    version    Show the version of the tool

Setting the Target File

  • Mark the file or directory you want to operate on with fuga mark <TARGET>.
$ fuga mark target_file.txt
โœ… : ๐Ÿ“„ target_file.txt has marked.
  • To check the currently marked file or directory, use fuga mark --show.
$ fuga mark --show
โ„น๏ธ : ๐Ÿ“„ /home/user/path/to/file/target_file.txt
  • To unmark a file or directory, use fuga mark --reset.
$ fuga mark --reset
โœ… : The marked path has reset.

File Operations

Three file operations are possible: Copy, Move, and Symbolic Link creation.

Copy

  • Navigate to the destination directory and use fuga copy to copy the marked file or directory.
$ cd test_dir_copy

$ fuga copy
โ„น๏ธ : Start copying ๐Ÿ“„ target_file.txt from /home/user/path/to/file/target_file.txt
โœ… : ๐Ÿ“„ target_file.txt has copied.
  • You can also specify the destination directory or file name.
$ fuga copy test_dir_copy
โ„น๏ธ : Start copying ๐Ÿ“„ test_dir_copy/target_file.txt from /home/user/path/to/file/target_file.txt
โœ… : ๐Ÿ“„ test_dir_copy/target_file.txt has copied.

$ fuga copy copy.txt
โ„น๏ธ : Start copying ๐Ÿ“„ copy.txt from /home/user/path/to/file/target_file.txt
โœ… : ๐Ÿ“„ copy.txt has copied.

Move

  • Navigate to the destination directory and use fuga move to move the marked file or directory.
$ cd test_dir_move

$ fuga move
โ„น๏ธ : Start moving ๐Ÿ“„ target_file.txt from /home/user/path/to/file/target_file.txt
โœ… : ๐Ÿ“„ target_file.txt has moved.
  • Similar to copying, you can specify the destination directory or file name.
$ fuga move test_dir_move
โ„น๏ธ : Start copying ๐Ÿ“„ test_dir_move/target_file.txt from /home/user/path/to/file/target_file.txt
โœ… : ๐Ÿ“„ test_dir_move/target_file.txt has moved.

$ fuga move move.txt
โ„น๏ธ : Start moving ๐Ÿ“„ move.txt from /home/user/path/to/file/target_file.txt
โœ… : ๐Ÿ“„ move.txt has moved.

Symbolic Link

  • Navigate to the directory where you want to create a symbolic link and use fuga link to create a symbolic link to the marked file or directory.
$ cd test_dir_link

$ fuga link
โ„น๏ธ : Start making symbolic link ๐Ÿ“„ target_file.txt from /home/user/path/to/file/target_file.txt
โœ… : ๐Ÿ“„ target_file.txt has made.
  • You can also specify the destination directory or file name for the symbolic link.
$ fuga link test_dir_link
โ„น๏ธ : Start making symbolic link ๐Ÿ“„ test_dir_link/target_file.txt from /home/user/path/to/file/target_file.txt
โœ… : ๐Ÿ“„ test_dir_link/target_file.txt has made.

$ fuga link link.txt
โ„น๏ธ : Start making symbolic link ๐Ÿ“„ link.txt from /home/user/path/to/file/target_file.txt
โœ… : ๐Ÿ“„ link.txt has made.