Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tutorial: Using go-ipfs as a Library #6695

Merged
merged 61 commits into from
Oct 29, 2019
Merged

Tutorial: Using go-ipfs as a Library #6695

merged 61 commits into from
Oct 29, 2019

Conversation

daviddias
Copy link
Member

This is very much a WIP/Draft PR. I'm opening it so that I can ask some tips and feedback.

My goal is to get a clean example that mirrors https://github.com/ipfs/js-ipfs/tree/master/examples/ipfs-101 and through it, learn how to use go-ipfs programmatically so that I can continue making progress on writing the Test Plan 1 for TestGround

Comment on lines 1 to 4
# IPFS 101, spawn a node and add a file to the IPFS network

> This example is the sister example of IPFS 101 for [js-ipfs](https://github.com/ipfs/js-ipfs/tree/master/examples/ipfs-101).

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll update this README once I have main.go working. Currently this is just c&p from https://github.com/ipfs/js-ipfs/tree/master/examples/ipfs-101

@github-actions github-actions bot requested a review from dirkmc October 2, 2019 07:06
@daviddias
Copy link
Member Author

Currently, this example finishes silently.

> go run main.go 2>&1
Start%

It was supposed to start an IPFS node, fetch a CID and write it to a folder. If anyone has any tip on what I'm missing, it would be much appreciated!

@daviddias
Copy link
Member Author

Another repo to take inspiration from https://github.com/hsanjuan/ipfs-lite

@daviddias
Copy link
Member Author

daviddias commented Oct 9, 2019

Thank you @aschmahmann on helping set the plugins to set up. c&p your comment from the DM so that it is visible here:

@aschmahmann: I added the plugins. It should run now if you use your local repo. However, the nodes created from temporarily spawned repos don't seem to be working properly.

It seems it is missing the right pathing to work. Update got it to work :) It actually doesn't work. It was relying on the already created repo on the default path. If that is missing, it fails to create a repo with the plugins.

@daviddias daviddias changed the title IPFS 101 example with go-ipfs Tutorial: Using go-ipfs as a Library Oct 9, 2019
docs/examples/go-ipfs-as-a-library/README.md Outdated Show resolved Hide resolved
docs/examples/go-ipfs-as-a-library/main.go Outdated Show resolved Hide resolved
docs/examples/go-ipfs-as-a-library/main.go Outdated Show resolved Hide resolved
docs/examples/go-ipfs-as-a-library/main.go Show resolved Hide resolved
daviddias and others added 13 commits October 22, 2019 20:23
@daviddias
Copy link
Member Author

Thank you so much for the thorough review @jessicaschilling! :D

@Stebalien wanna give it a review? Then I can adjust the links to the lines of code and it is ready to go :)

@daviddias
Copy link
Member Author

@Stebalien did you had the chance to review this PR or would you like to grant me the permission to merge it?

Copy link
Member

@Stebalien Stebalien left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! LGTM modulo some nits (and we should switch out the bootstrappers as @olizilla says).

docs/examples/go-ipfs-as-a-library/main.go Show resolved Hide resolved
docs/examples/go-ipfs-as-a-library/main.go Outdated Show resolved Hide resolved
docs/examples/go-ipfs-as-a-library/main.go Outdated Show resolved Hide resolved
@daviddias
Copy link
Member Author

CI fails on sharness, interop and go-ipfs-api. Pretty sure it is not related to this PR.

@daviddias
Copy link
Member Author

I take from @Stebalien approval that it is good to be merged. Clicking the squash and merge for a clean single commit :)

CI failed only on parts unrelated to this PR. Opened a issue for a fix on the interop tests ipfs/interop#92

@daviddias daviddias merged commit 1bc15a4 into master Oct 29, 2019
@daviddias
Copy link
Member Author

Wowowowow! Thank you so much for everyone that contributed to the creation of this Tutorial!! It was a long process but I'm confident that it will yield many new tinkerers with go-ipfs! :D

@daviddias daviddias deleted the go-ipfs-101 branch October 29, 2019 08:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants