Skip to content

Commit

Permalink
first commit
Browse files Browse the repository at this point in the history
  • Loading branch information
tky committed Mar 20, 2012
0 parents commit 7a6509d
Show file tree
Hide file tree
Showing 4 changed files with 43 additions and 0 deletions.
21 changes: 21 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
scalding-sample
========================
simple scalding samples.

Usage
------------------------------
::

First, clone the Scalding repository on Github, see detail

https://github.com/twitter/scalding/wiki/Getting-Started

Next, add scalad.rb to your path,
ln -s scripts/scald.rb $HOME/bin/

https://github.com/twitter/scalding/wiki/Scald.rb

Ok, now you can run this simple project

scripts/scalad.rb src/main/scala/Sample1.scala
9 changes: 9 additions & 0 deletions build.sbt
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name := "scalding-sample"

version := "1.0.0"

scalaVersion := "2.8.1"

resolvers += "Concurrent Maven Repo" at "http://conjars.org/repo"

libraryDependencies += "com.twitter" % "scalding_2.8.1" % "0.2.0"
5 changes: 5 additions & 0 deletions data/sample1.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
252453 Apple
787345 Orange
808056 Banana
252453 Banana
787345 Apple
8 changes: 8 additions & 0 deletions src/main/scala/Sample1.scala
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import com.twitter.scalding._

class Sample1(args: Args) extends Job(args) {
val input = TextLine("data/sample1.txt")
val output = TextLine("data/sample1-out.txt")

input.read.write(output)
}

0 comments on commit 7a6509d

Please sign in to comment.