Issue: "ipfs add" and "ipfs files write" the difference between the two?

Why are they different?

When importing files, IPFS chunks the files into small pieces and then builds a merkletree on top of these chunks. By default, ipfs add ... generates a balanced merkletree while ipfs files write uses a merkletree optimized for appending (IIRC).

Why are there two ways to add files, and the difference between them?

There are two commands because:

  • ipfs add just adds the file to IPFS but doesn’t give it a name.
  • ipfs files write --create puts the file into a virtual filesystem we call MFS (mutable file system). This is often more convenient for managing files (see: http://127.0.0.1:5001/webui/#/files/).

Really, we should eventually combine these commands into a more unified API (ideally, one that uses MFS by default). However, that hasn’t been a priority.