Skip to content

Instantly share code, notes, and snippets.

@kbastani
Created May 22, 2014 23:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kbastani/588d53ffc824da4c8b1d to your computer and use it in GitHub Desktop.
Save kbastani/588d53ffc824da4c8b1d to your computer and use it in GitHub Desktop.
sample project page

= What is the Neo4j GraphGist project?

:neo4j-version: 2.1.0 :author: Anders Nawroth :twitter: @nawroth :tags: domain:example

http://neo4j.com[Neo4j] GraphGists are an easy way to create and share documents containing not just prose, structure and pictures but most importantly example graph models and use-cases expressed in Neo4j's query language http://docs.neo4j.org/refcard/2.1/[Cypher].

These documents are written in the simple, textual Markup language AsciiDoc and rendered in your browser as rich and interactive web pages that you can quickly evolve from describing simple howtos or questions to providing an extensive use-case specification.

To see the expressive power of this approach, here are some winners of our past community competitions:

=== Examples

=== It is really easy to get started:

  1. Log into your GitHub account
  2. Choose one of the examples listed above, click the green page source button.
  3. Fork the original GraphGist into your own account and start to edit the prose, images, setup and use-case Cypher queries
  4. Paste the Github Gist URL into the top right URL box of any GraphGist page, your Gist will be loaded and rendered immediately
  5. Reload your GraphGist page whenever you made an update to your document
  6. Share your GraphGist with your colleagues, friends or us, hit the submit link in the footer, when you are ready to get your t-shirt reward

++++

<iframe src="//player.vimeo.com/video/74279113" width="500" height="281" frameborder="0" webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe> ++++
  • link:./?github-neo4j-contrib%2Fgists%2F%2Fmeta%2FSimple.adoc[A simple GraphGist]
  • link:./?github-neo4j-contrib%2Fgists%2F%2Fmeta%2FHowTo.adoc[How to create a GraphGist]

=== Setup a Graph to show you and your Likes

And render as a graph.

//setup [source,cypher]

CREATE (you:Person {name:"You"})-[like:LIKE]->(us:Database:NoSql:Graph {name:"Neo4j" }) RETURN you,like,us

//graph

=== Now query the graph to show all the things you like

And render as a table.

[source,cypher]

CREATE (you:Person {name:"You"})-[like:LIKE]->(us:Database:NoSql:Graph {name:"Neo4j" }) RETURN you.name as who ,type(like) as how,us.name as what

//table

NOTE: This document is a GraphGist itself, so you can use the green +Page Source+ button on top of the page to see the original AsciiDoc document.

We'd love to get your feedback, so feel free to write us at docs at neo4j.org or comment in the section below.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment