From 5f66f98b14b830ca4933aa99d1bee4612960cc15 Mon Sep 17 00:00:00 2001 From: "Erik C. Thauvin" Date: Tue, 10 Jul 2018 23:45:11 -0700 Subject: [PATCH] Added copyright. Added note about incompatibility with new versions of Java. --- .idea/copyright/Erik_s_Copyright_Notice.xml | 6 ++++ .idea/copyright/profiles_settings.xml | 15 ++++++++++ .idea/scopes/Source.xml | 3 ++ .idea/vcs.xml | 6 ++++ README.md | 3 ++ build.gradle | 32 +++++++++++++++++++++ example.properties | 5 ++++ src/main/groovy/com/example/App.groovy | 31 ++++++++++++++++++++ test.properties | 5 ++++ 9 files changed, 106 insertions(+) create mode 100644 .idea/copyright/Erik_s_Copyright_Notice.xml create mode 100644 .idea/copyright/profiles_settings.xml create mode 100644 .idea/scopes/Source.xml create mode 100644 .idea/vcs.xml create mode 100644 example.properties create mode 100644 test.properties diff --git a/.idea/copyright/Erik_s_Copyright_Notice.xml b/.idea/copyright/Erik_s_Copyright_Notice.xml new file mode 100644 index 0000000..08660a1 --- /dev/null +++ b/.idea/copyright/Erik_s_Copyright_Notice.xml @@ -0,0 +1,6 @@ + + + + \ No newline at end of file diff --git a/.idea/copyright/profiles_settings.xml b/.idea/copyright/profiles_settings.xml new file mode 100644 index 0000000..2ea0731 --- /dev/null +++ b/.idea/copyright/profiles_settings.xml @@ -0,0 +1,15 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/scopes/Source.xml b/.idea/scopes/Source.xml new file mode 100644 index 0000000..7fdbded --- /dev/null +++ b/.idea/scopes/Source.xml @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..94a25f7 --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/README.md b/README.md index 2fb81dd..eed70cb 100644 --- a/README.md +++ b/README.md @@ -9,3 +9,6 @@ then: groovy src/main/groovy/com/example/App.groovy ``` +No longer works in newer version of Java (> 8). + +The `keys()` method in `java.util.Properties` is no longer called on `store()`. \ No newline at end of file diff --git a/build.gradle b/build.gradle index bf4c9d6..e73f055 100644 --- a/build.gradle +++ b/build.gradle @@ -1,3 +1,35 @@ +/* +* build.gradle +* +* Copyright (c) 2018, Erik C. Thauvin (erik@thauvin.net) +* All rights reserved. +* +* Redistribution and use in source and binary forms, with or without +* modification, are permitted provided that the following conditions are met: +* +* Redistributions of source code must retain the above copyright notice, this +* list of conditions and the following disclaimer. +* +* Redistributions in binary form must reproduce the above copyright notice, +* this list of conditions and the following disclaimer in the documentation +* and/or other materials provided with the distribution. +* +* Neither the name of this project nor the names of its contributors may be +* used to endorse or promote products derived from this software without +* specific prior written permission. +* +* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +*/ + class TestPlugin implements Plugin { void apply(Project project) { project.task('runPlugin') { diff --git a/example.properties b/example.properties new file mode 100644 index 0000000..ebc7291 --- /dev/null +++ b/example.properties @@ -0,0 +1,5 @@ +#Generated by the App. +#Tue Jul 10 23:43:28 PDT 2018 +apple=one +coffee=three +beta=two diff --git a/src/main/groovy/com/example/App.groovy b/src/main/groovy/com/example/App.groovy index 9e98208..59dd63f 100644 --- a/src/main/groovy/com/example/App.groovy +++ b/src/main/groovy/com/example/App.groovy @@ -1,3 +1,34 @@ +/* + * App.groovy + * + * Copyright (c) 2018, Erik C. Thauvin (erik@thauvin.net) + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * Redistributions of source code must retain the above copyright notice, this + * list of conditions and the following disclaimer. + * + * Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * Neither the name of this project nor the names of its contributors may be + * used to endorse or promote products derived from this software without + * specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" + * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ package com.example class App { diff --git a/test.properties b/test.properties new file mode 100644 index 0000000..d0674e8 --- /dev/null +++ b/test.properties @@ -0,0 +1,5 @@ +#Generated by the plugin. +#Tue Jul 10 23:43:04 PDT 2018 +apple=one +coffee=three +beta=two