ipfs
Store and share content using IPFS
TLDR
Add a file from local to the filesystem, pin it and print the relative hash
Add a directory and its files recursively from local to the filesystem and print the relative hash
Save a remote file and give it a name but not pin it
Pin a remote file locally
Display pinned files
Unpin a file from the local storage
Remove unpinned files from local storage
SYNOPSIS
ipfs [flags] <command> [arguments]
PARAMETERS
--api <api-address>
Specifies the API endpoint of the IPFS daemon. Defaults to the value of $IPFS_PATH/api. If the daemon is not running this command cannot be executed.
--help
Displays help text for the command or subcommand.
--version
Displays the IPFS version.
--timeout <duration>
Sets a timeout for the command execution (e.g., '5m', '10s').
--offline
Execute the command without connecting to the network.
DESCRIPTION
The `ipfs` command is the primary interface for interacting with the InterPlanetary File System (IPFS).
IPFS is a decentralized, peer-to-peer file system that aims to create a permanent and distributed web. The `ipfs` command provides tools to add, retrieve, and manage data stored on the IPFS network, as well as tools for configuring and managing an IPFS node. It allows you to add files to IPFS, retrieve files using their content identifier (CID), publish and resolve IPNS names, manage your local node's configuration, and interact with other nodes on the network.
Essentially, it offers functionalities similar to traditional file systems, but with a focus on content addressing, decentralization, and immutability. The command leverages a modular architecture, where different subcommands cater to specific aspects of IPFS functionality, offering a wide array of capabilities for developers and users seeking a distributed and resilient storage solution.
CAVEATS
Many `ipfs` subcommands require a running IPFS daemon (ipfs daemon). Some commands have specific prerequisites or dependencies that must be met for them to function correctly.
<B>IPFS</B> <B>SUBCOMMANDS</B>
The `ipfs` command has many subcommands to manage specific components of the system. A few examples:
- add: Add a file to IPFS.
- cat: Display IPFS object data.
- get: Download IPFS objects.
- ls: List IPFS links.
- refs: List links from IPFS objects.
<B>IPFS</B> <B>PATHS</B>
IPFS uses content identifiers (CIDs) to uniquely identify files and directories. These CIDs form the basis of IPFS paths, which can be used to access data on the network. An example of an IPFS path is `/ipfs/Qm...
HISTORY
IPFS was initially developed by Protocol Labs, starting around 2014. It was conceived as a replacement for HTTP based on content addressing rather than location addressing. The `ipfs` command-line tool is the primary way users interact with the IPFS network and has been continuously developed and improved since the early stages of the project. Its usage has expanded from simple file sharing to more complex applications such as decentralized websites, data storage, and content distribution. The `ipfs` command has a modular design philosophy that has allowed many developers to contribute and build upon its core functionality.