[ARVADOS] updated: f6ea610fcc842abdbc9cfe2dd10a64debc81ac1a

git at public.curoverse.com git at public.curoverse.com
Thu Sep 11 18:31:15 EDT 2014


Summary of changes:
 .../_example_sdk_go_collection_list.liquid         | 27 +++++++++++++++++++
 doc/sdk/go/index.html.textile.liquid               | 31 +---------------------
 2 files changed, 28 insertions(+), 30 deletions(-)
 create mode 100644 doc/_includes/_example_sdk_go_collection_list.liquid

       via  f6ea610fcc842abdbc9cfe2dd10a64debc81ac1a (commit)
       via  946aeb2debef9cb5fc3c4b557a2973b36f6d3750 (commit)
      from  0bb834af65ea679d03bfe6c4e578e3d3403b8bf8 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit f6ea610fcc842abdbc9cfe2dd10a64debc81ac1a
Author: mishaz <misha at curoverse.com>
Date:   Thu Sep 11 22:30:46 2014 +0000

    Included included file.

diff --git a/doc/sdk/go/index.html.textile.liquid b/doc/sdk/go/index.html.textile.liquid
index 6996a4e..e4e3821 100644
--- a/doc/sdk/go/index.html.textile.liquid
+++ b/doc/sdk/go/index.html.textile.liquid
@@ -66,35 +66,6 @@ Get the User object for the current user:
 
 Print all returned fields for collections:
 
-<notextile>
-<pre><code class="userinput">	var collections map[string]interface{}
-
-	params := arvadosclient.Dict{"limit": 10}
-
-	err = arv.Call("GET", "collections", "", "", params, &collections)
-	if err != nil {
-		log.Fatalf("error querying collections", err.Error())
-	}
-
-	for key, value := range collections {
-		if key == "items" {
-			items := value.([]interface{})
-			for index, item := range items {
-				fmt.Println("===========  ", index, "  ===========")
-				item_map := item.(map[string]interface{})
-				if len(item_map) == 0 {
-					fmt.Println("item", index, ": empty map")
-				} else {
-					for k,v := range item_map {
-						fmt.Println(index, k, ":", v)
-					}
-				}
-			}
-		} else {
-			fmt.Println(key, ":", value)
-		}
-	}
-</code></pre>
-</notextile>
+{% code 'example_sdk_go_collection_list' as go %}
 
 A few more usage examples can be found in the services/keepproxy and sdk/go/keepclient directories in the arvados source tree.

commit 946aeb2debef9cb5fc3c4b557a2973b36f6d3750
Author: mishaz <misha at curoverse.com>
Date:   Thu Sep 11 22:29:27 2014 +0000

    Moved code to seperate file for syntax coloring.
    Switched to using arv.List instead of arv.Call.

diff --git a/doc/_includes/_example_sdk_go_collection_list.liquid b/doc/_includes/_example_sdk_go_collection_list.liquid
new file mode 100644
index 0000000..fecf909
--- /dev/null
+++ b/doc/_includes/_example_sdk_go_collection_list.liquid
@@ -0,0 +1,27 @@
+	var collections map[string]interface{}
+
+	params := arvadosclient.Dict{"limit": 10}
+
+	err = arv.List("collections", params, &collections)
+	if err != nil {
+		log.Fatalf("error querying collections", err.Error())
+	}
+
+	for key, value := range collections {
+		if key == "items" {
+			items := value.([]interface{})
+			for index, item := range items {
+				fmt.Println("===========  ", index, "  ===========")
+				item_map := item.(map[string]interface{})
+				if len(item_map) == 0 {
+					fmt.Println("item", index, ": empty map")
+				} else {
+					for k,v := range item_map {
+						fmt.Println(index, k, ":", v)
+					}
+				}
+			}
+		} else {
+			fmt.Println(key, ":", value)
+		}
+	}

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list