From b261f6a5e5cb4b5b684ca0fb1d0438dc9f84a562 Mon Sep 17 00:00:00 2001 From: Michael Rozumyanskiy Date: Wed, 26 Apr 2017 00:18:57 +0300 Subject: [PATCH 1/5] Bump version to 0.1.5 --- version.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/version.properties b/version.properties index 1ffd5d1..8df3b97 100644 --- a/version.properties +++ b/version.properties @@ -1,6 +1,6 @@ version.major=0 version.minor=1 -version.patch=4 +version.patch=5 version.snapshot=false version.dryRun=false From b388b7a5adccd8357c8dc9167ce83c1a204da9f7 Mon Sep 17 00:00:00 2001 From: Michael Rozumyanskiy Date: Wed, 26 Apr 2017 00:19:06 +0300 Subject: [PATCH 2/5] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 0ea0acc..968bab5 100644 --- a/README.md +++ b/README.md @@ -18,7 +18,7 @@ buildscript { } dependencies { - classpath 'io.michaelrocks:paranoid-gradle-plugin:0.1.4' + classpath 'io.michaelrocks:paranoid-gradle-plugin:0.1.5' } } From 9d47c0d685ce7763783c3bb8646624c9c9838a04 Mon Sep 17 00:00:00 2001 From: Michael Rozumyanskiy Date: Wed, 26 Apr 2017 00:19:25 +0300 Subject: [PATCH 3/5] Bump Kotlin version to 1.1.2 --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index ac2088b..5a9879e 100644 --- a/build.gradle +++ b/build.gradle @@ -1,5 +1,5 @@ allprojects { - ext.kotlinVersion = '1.1.1' + ext.kotlinVersion = '1.1.2' buildscript { repositories { From 2f3de4e91775a1b779c0b3a6972fddbb82ccd22d Mon Sep 17 00:00:00 2001 From: Michael Rozumyanskiy Date: Wed, 26 Apr 2017 00:20:24 +0300 Subject: [PATCH 4/5] Generate proper escape sequences for ' and \ characters --- .../main/kotlin/io/michaelrocks/paranoid/processor/Generator.kt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/processor/src/main/kotlin/io/michaelrocks/paranoid/processor/Generator.kt b/processor/src/main/kotlin/io/michaelrocks/paranoid/processor/Generator.kt index 753d8d5..2ba71cc 100644 --- a/processor/src/main/kotlin/io/michaelrocks/paranoid/processor/Generator.kt +++ b/processor/src/main/kotlin/io/michaelrocks/paranoid/processor/Generator.kt @@ -121,6 +121,8 @@ class Generator(private val stringRegistry: StringRegistry) { return when (this) { '\n' -> "'\\n'" '\r' -> "'\\r'" + '\'' -> "'\\''" + '\\' -> "'\\\\'" else -> "'\\u%04x'".format(toShort()) } } From 9ce771b7d35c57a77eda3d176c370a444597f5c4 Mon Sep 17 00:00:00 2001 From: Michael Rozumyanskiy Date: Wed, 26 Apr 2017 00:31:30 +0300 Subject: [PATCH 5/5] Add more special characters to the sample project --- .../java/io/michaelrocks/paranoid/sample/MainActivity.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sample/src/main/java/io/michaelrocks/paranoid/sample/MainActivity.java b/sample/src/main/java/io/michaelrocks/paranoid/sample/MainActivity.java index 30424b1..ed35710 100644 --- a/sample/src/main/java/io/michaelrocks/paranoid/sample/MainActivity.java +++ b/sample/src/main/java/io/michaelrocks/paranoid/sample/MainActivity.java @@ -32,9 +32,9 @@ protected void onCreate(final Bundle savedInstanceState) { setContentView(R.layout.main_activity); final TextView questionTextView = (TextView) findViewById(R.id.questionTextView); - questionTextView.setText(String.format(QUESTION, "Does it work?")); + questionTextView.setText(String.format(QUESTION, "How does it work?")); final TextView answerTextView = (TextView) findViewById(R.id.answerTextView); - answerTextView.setText(String.format(ANSWER, "Sure it does!")); + answerTextView.setText(String.format(ANSWER, "It's magic! ¯\\_(ツ)_/¯")); } }