From 0a6d4ffd136f6e1bdf2ca4fe4d3c003fd27f28a8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alex=20Koz=2E=20=F0=9F=91=BE?= Date: Tue, 12 Apr 2016 20:51:51 +0300 Subject: [PATCH 1/4] add new cheat sheet (term/comands) for IPFS (http://ipfs.io) --- share/goodie/cheat_sheets/json/ipfs.json | 203 +++++++++++++++++++++++ 1 file changed, 203 insertions(+) create mode 100644 share/goodie/cheat_sheets/json/ipfs.json diff --git a/share/goodie/cheat_sheets/json/ipfs.json b/share/goodie/cheat_sheets/json/ipfs.json new file mode 100644 index 000000000..517533e4c --- /dev/null +++ b/share/goodie/cheat_sheets/json/ipfs.json @@ -0,0 +1,203 @@ +{ + "id": "ipfs_cheat_sheet", + "name": "IPFS", + "description": "A quick reference to IPFS, a peer-to-peer hypermedia protocol for The Permanent Web.\nThe InterPlanetary File System (IPFS) is a new hypermedia distribution protocol, addressed by content and identities. IPFS enables the creation of completely distributed applications. It aims to make the web faster, safer, and more open.", + + "metadata": { + "sourceName": "ipfs.io", + "sourceUrl" : "https://ipfs.io/docs/commands/" + }, + + "aliases": [ + "ipns", + "ipld" + ], + + "template_type": "terminal", + + "section_order": [ + "Installing", + "Configuring", + "Basic Commands", + "Advanced Commands", + "Network Commands", + "Tool Commands", + "Options Keys" + ], + + "sections": { + + "Installing": [ + { + "key": "curl -O http://dist.ipfs.io/go-ipfs/v0.4.0/go-ipfs_v0.4.0_darwin-amd64.tar.gz", + "val": "Downloads wp-cli.phar." + }, + { + "key": "tar xvfz go-ipfs_v0.4.0_darwin-amd64.tar.gz", + "val": "Unpack the archive with executable." + }, + { + "key": "mv go-ipfs/ipfs /usr/local/bin/ipfs", + "val": "Move the executables into /usr/local/bin directory." + } + ], + + "Configuring": [ + { + "key": "export IPFS_PATH=/path/to/ipfsrepo", + "val": "Path to the repo custom location. By default, the repo is located at `~/.ipfs.`" + }, + { + "key": "ipfs init", + "val": "Initialize ipfs local configuration." + } + ], + + "Options Keys": [ + { + "key": "-c, --config \\[path:string\\]", + "val": "Path to the configuration file to use." + }, + { + "key": "-D, --debug", + "val": "Operate in debug mode." + }, + { + "key": "-h", + "val": "Show a short version of the command help text." + }, + { + "key": "--help", + "val": "Show the full command help text." + }, + { + "key": "-L, --local", + "val": "Run the command locally, instead of using the daemon." + }, + { + "key": "--api \\[uri:string\\]", + "val": "Use a specific API instance (defaults to /ip4/127.0.0.1/tcp/5001)" + } + ], + + "Basic Commands": [ + { + "key": "ipfs help", + "val": "Show a short version of the command help text." + }, + { + "key": "ipfs init", + "val": "Initialize ipfs local configuration." + }, + { + "key": "ipfs add ", + "val": "Add an object to ipfs." + }, + { + "key": "ipfs cat ", + "val": "Show ipfs object data." + }, + { + "key": "ipfs get ", + "val": "Download ipfs objects." + }, + { + "key": "ipfs ls ", + "val": "List links from an object." + }, + { + "key": "ipfs refs ", + "val": "List hashes of links from an object." + }, + { + "key": "ipfs add ", + "val": "Add an object to ipfs." + }, + { + "key": "ipfs add ", + "val": "Add an object to ipfs." + } + ], + + "Advanced Commands": [ + { + "key": "ipfs daemon", + "val": "Start a long-running daemon process." + }, + { + "key": "ipfs daemon --mount", + "val": "Start a long-running daemon process and mount and mount an ipfs read-only mountpoint." + }, + { + "key": "ipfs mount", + "val": "Mount an ipfs read-only mountpoint." + }, + { + "key": "ipfs resolve", + "val": "Resolve any type of name." + }, + { + "key": "ipfs name", + "val": "Publish or resolve IPNS names." + }, + { + "key": "ipfs dns", + "val": "Resolve DNS links." + }, + { + "key": "ipfs pin", + "val": "Pin objects to local storage." + }, + { + "key": "ipfs repo gc", + "val": "Garbage collect unpinned objects." + } + ], + + "Network Commands": [ + { + "key": "ipfs id", + "val": "Show info about ipfs peers." + }, + { + "key": "ipfs bootstrap", + "val": "Add or remove bootstrap peers." + }, + { + "key": "ipfs swarm", + "val": "Manage connections to the p2p network." + }, + { + "key": "ipfs dht", + "val": "Query the dht for values or peers." + }, + { + "key": "ipfs ping", + "val": "Measure the latency of a connection." + }, + { + "key": "ipfs diag", + "val": "Print diagnostics." + } + ], + + "Tool Commands": [ + { + "key": "ipfs config", + "val": "Manage configuration." + }, + { + "key": "ipfs version", + "val": "Show ipfs version information." + }, + { + "key": "ipfs update", + "val": "Download and apply go-ipfs updates." + }, + { + "key": "ipfs commands", + "val": "List all available commands." + } + ] + } +} From fad2eb87e5d193116e06996efbb5008f97c9b98f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alex=20Koz=2E=20=F0=9F=91=BE?= Date: Tue, 12 Apr 2016 21:16:26 +0300 Subject: [PATCH 2/4] fix #$% missed description --- share/goodie/cheat_sheets/json/ipfs.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/goodie/cheat_sheets/json/ipfs.json b/share/goodie/cheat_sheets/json/ipfs.json index 517533e4c..7fff90690 100644 --- a/share/goodie/cheat_sheets/json/ipfs.json +++ b/share/goodie/cheat_sheets/json/ipfs.json @@ -30,7 +30,7 @@ "Installing": [ { "key": "curl -O http://dist.ipfs.io/go-ipfs/v0.4.0/go-ipfs_v0.4.0_darwin-amd64.tar.gz", - "val": "Downloads wp-cli.phar." + "val": "Downloads ipfs executable." }, { "key": "tar xvfz go-ipfs_v0.4.0_darwin-amd64.tar.gz", From 29d923f0d1a935e0179ccc2c7fe8ff747054a2f9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alex=20Koz=2E=20=F0=9F=91=BE?= Date: Tue, 12 Apr 2016 22:18:01 +0300 Subject: [PATCH 3/4] fix sourceUrl to "IPFS Documentation" --- share/goodie/cheat_sheets/json/ipfs.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/goodie/cheat_sheets/json/ipfs.json b/share/goodie/cheat_sheets/json/ipfs.json index 7fff90690..d2b7a30f1 100644 --- a/share/goodie/cheat_sheets/json/ipfs.json +++ b/share/goodie/cheat_sheets/json/ipfs.json @@ -4,7 +4,7 @@ "description": "A quick reference to IPFS, a peer-to-peer hypermedia protocol for The Permanent Web.\nThe InterPlanetary File System (IPFS) is a new hypermedia distribution protocol, addressed by content and identities. IPFS enables the creation of completely distributed applications. It aims to make the web faster, safer, and more open.", "metadata": { - "sourceName": "ipfs.io", + "sourceName": "IPFS Documentation", "sourceUrl" : "https://ipfs.io/docs/commands/" }, From 4c9a797c2f647cd0ae8ff6fb64c076c599b3be16 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alex=20Koz=2E=20=F0=9F=91=BE?= Date: Wed, 13 Apr 2016 13:09:40 +0300 Subject: [PATCH 4/4] remove "Installing" section for greater beauty. --- share/goodie/cheat_sheets/json/ipfs.json | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/share/goodie/cheat_sheets/json/ipfs.json b/share/goodie/cheat_sheets/json/ipfs.json index d2b7a30f1..ae7b5dc4c 100644 --- a/share/goodie/cheat_sheets/json/ipfs.json +++ b/share/goodie/cheat_sheets/json/ipfs.json @@ -16,7 +16,6 @@ "template_type": "terminal", "section_order": [ - "Installing", "Configuring", "Basic Commands", "Advanced Commands", @@ -27,21 +26,6 @@ "sections": { - "Installing": [ - { - "key": "curl -O http://dist.ipfs.io/go-ipfs/v0.4.0/go-ipfs_v0.4.0_darwin-amd64.tar.gz", - "val": "Downloads ipfs executable." - }, - { - "key": "tar xvfz go-ipfs_v0.4.0_darwin-amd64.tar.gz", - "val": "Unpack the archive with executable." - }, - { - "key": "mv go-ipfs/ipfs /usr/local/bin/ipfs", - "val": "Move the executables into /usr/local/bin directory." - } - ], - "Configuring": [ { "key": "export IPFS_PATH=/path/to/ipfsrepo",