Last active
December 23, 2015 11:59
-
-
Save johnynek/6632488 to your computer and use it in GitHub Desktop.
Sed rules for porting to scalding 0.9.0 from earlier versions. Run this in the directory with your jobs with gnu sed (brew install gnu-sed).
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
find . -type f -print0 | xargs -0 gsed -i 's/\.sum(/.sum[Double](/g' | |
find . -type f -print0 | xargs -0 gsed -i 's/\.plus\[/.sum[/g' | |
find . -type f -print0 | xargs -0 gsed -i 's/import com.twitter.scalding.DateOps.richDateToCalendar/import com.twitter.scalding.RichDate.toCalendar/' | |
find . -type f -print0 | xargs -0 gsed -i 's/ RichDate("\([^"]\+\)")(\([^)]\+\))/ com.twitter.scalding.DateParser.default.parse("\1")(\2).get/g' | |
find . -type f -print0 | xargs -0 gsed -i 's/\.then[^(Do)]/.thenDo/g' | |
find . -type f -print0 | xargs -0 gsed -i 's/Mode\.mode/mode/g' | |
find . -type f -print0 | xargs -0 gsed -i 's/new RichDate/RichDate/g' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
the 1st command is wrong. Should be