-
Notifications
You must be signed in to change notification settings - Fork 42
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #95 from ipfs/feat/repo-migration-raw-multihashes
Migration 11-12: migrate CIDsv1 to raw multihashes
- Loading branch information
Showing
3,914 changed files
with
963,522 additions
and
5 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
.PHONY: build clean | ||
|
||
build: | ||
go build -mod=vendor | ||
|
||
clean: | ||
go clean |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
module github.com/ipfs/fs-repo-migrations/fs-repo-11-to-12 | ||
|
||
go 1.15 | ||
|
||
require ( | ||
github.com/hsanjuan/ipfs-lite v1.1.19 | ||
github.com/ipfs/fs-repo-migrations v1.7.1 | ||
github.com/ipfs/go-cid v0.0.7 | ||
github.com/ipfs/go-datastore v0.4.5 | ||
github.com/ipfs/go-filestore v1.0.0 | ||
github.com/ipfs/go-ipfs v0.8.0 | ||
github.com/ipfs/go-ipfs-blockstore v1.0.3 // indirect | ||
github.com/ipfs/go-ipfs-ds-help v1.0.0 | ||
github.com/ipfs/go-ipfs-pinner v0.1.1 | ||
github.com/ipfs/go-ipld-format v0.2.0 | ||
github.com/otiai10/copy v1.5.1 | ||
) |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package main | ||
|
||
import ( | ||
mg11 "github.com/ipfs/fs-repo-migrations/fs-repo-11-to-12/migration" | ||
migrate "github.com/ipfs/fs-repo-migrations/go-migrate" | ||
) | ||
|
||
func main() { | ||
m := mg11.Migration{} | ||
migrate.Main(&m) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
#!/bin/bash | ||
|
||
# This script can be used to generate the repotest folder that is used | ||
# to test the migration, using go-ipfs v0.8.0. | ||
|
||
export IPFS_PATH=repotest | ||
|
||
mkdir a | ||
echo "file1" > a/file1 | ||
mkdir b | ||
echo "file2" > b/file2 | ||
mkdir c | ||
echo "file3" > c/file3 | ||
|
||
ipfs init | ||
|
||
# A: add with both v0 and v1 | ||
ipfs add -r --pin=false a | ||
ipfs add -r --cid-version=1 --raw-leaves=false --pin=false a | ||
|
||
# B: add with v1 | ||
ipfs add -r --cid-version=1 --raw-leaves=false --pin=false b | ||
|
||
# C: add with v0 | ||
ipfs add -r --pin=false c |
Oops, something went wrong.