From 89d86c52a267d17bea0519fb6463b4581f6ba17e Mon Sep 17 00:00:00 2001 From: Emmanuele Bassi Date: Sun, 28 Jan 2018 23:42:27 +0000 Subject: [PATCH 1/4] Reference the Lesser GPL in the LGPL snippet The LGPL license snippet still references the GPL. --- data/snippets/licenses.snippets | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/data/snippets/licenses.snippets b/data/snippets/licenses.snippets index bce24bae1..74e136722 100644 --- a/data/snippets/licenses.snippets +++ b/data/snippets/licenses.snippets @@ -72,8 +72,8 @@ snippet lgpl * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . + * You should have received a copy of the GNU Lesser General Public + * License along with this program. If not, see . */ $0 - scope python, python3 @@ -91,8 +91,9 @@ snippet lgpl # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # Lesser General Public License for more details. # - # You should have received a copy of the GNU General Public License - # along with this program. If not, see . + # You should have received a copy of the GNU Lesser General Public + # License along with this program. If not, see . + # $0 - scope c-sharp, rust // @@ -110,7 +111,7 @@ snippet lgpl // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU // Lesser General Public License for more details. // - // You should have received a copy of the GNU General Public License - // along with this program. If not, see . + // You should have received a copy of the GNU Lesser General Public + // License along with this program. If not, see . // $0 -- GitLab From df0acde1623dd2bb656c79bbfaf312cae76d048d Mon Sep 17 00:00:00 2001 From: Emmanuele Bassi Date: Sun, 28 Jan 2018 23:45:29 +0000 Subject: [PATCH 2/4] Add SPDX license identifier The SPDX is an attempt at standardising the licensing attribution of free and open source software in a way that is machine parseable. Since we're shipping snippets that autogenerate the licensing blurb, it would be a good thing to include this annotation in them, so that newly written code can immediately be compliant. --- data/snippets/licenses.snippets | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/data/snippets/licenses.snippets b/data/snippets/licenses.snippets index 74e136722..73b3afc00 100644 --- a/data/snippets/licenses.snippets +++ b/data/snippets/licenses.snippets @@ -16,6 +16,8 @@ snippet gpl * * You should have received a copy of the GNU General Public License * along with this program. If not, see . + * + * SPDX-License-Identifier: GPL-3.0-or-later */ $0 - scope python, python3 @@ -35,6 +37,8 @@ snippet gpl # # You should have received a copy of the GNU General Public License # along with this program. If not, see . + # + # SPDX-License-Identifier: GPL-3.0-or-later $0 - scope c-sharp, rust // @@ -55,6 +59,7 @@ snippet gpl // You should have received a copy of the GNU General Public License // along with this program. If not, see . // + // SPDX-License-Identifier: GPL-3.0-or-later $0 snippet lgpl - scope c, chdr, cpp, css, js, vala @@ -74,6 +79,8 @@ snippet lgpl * * You should have received a copy of the GNU Lesser General Public * License along with this program. If not, see . + * + * SPDX-License-Identifier: LGPL-3.0-or-later */ $0 - scope python, python3 @@ -94,6 +101,7 @@ snippet lgpl # You should have received a copy of the GNU Lesser General Public # License along with this program. If not, see . # + # SPDX-License-Identifier: LGPL-3.0-or-later $0 - scope c-sharp, rust // @@ -114,4 +122,5 @@ snippet lgpl // You should have received a copy of the GNU Lesser General Public // License along with this program. If not, see . // + // SPDX-License-Identifier: LGPL-3.0-or-later $0 -- GitLab From efd7fc1a90d055bc367770afad0e8c92f9bd20d4 Mon Sep 17 00:00:00 2001 From: Emmanuele Bassi Date: Sun, 28 Jan 2018 23:48:46 +0000 Subject: [PATCH 3/4] Remove the redundant "copyright" glyph MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The "©" glyph means "copyright", so "Copyright ©" means "Copyright Copyright". Typically, either would be enough, but some legal frameworks recognise the word instead of the glyph, so we cannot drop "Copyright" and keep the "©". --- data/snippets/licenses.snippets | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/data/snippets/licenses.snippets b/data/snippets/licenses.snippets index 73b3afc00..055082c28 100644 --- a/data/snippets/licenses.snippets +++ b/data/snippets/licenses.snippets @@ -2,7 +2,7 @@ snippet gpl - scope c, chdr, cpp, css, js, vala /* ${1:$filename} * - * Copyright © $year ${2:$fullname} <${3:$email}> + * Copyright $year ${2:$fullname} <${3:$email}> * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -23,7 +23,7 @@ snippet gpl - scope python, python3 # ${1:$filename} # - # Copyright © $year ${2:$fullname} <${3:$email}> + # Copyright $year ${2:$fullname} <${3:$email}> # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -44,7 +44,7 @@ snippet gpl // // ${1:$filename} // - // Copyright © $year ${2:$fullname} <${3:$email}> + // Copyright $year ${2:$fullname} <${3:$email}> // // This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by @@ -65,7 +65,7 @@ snippet lgpl - scope c, chdr, cpp, css, js, vala /* ${1:$filename} * - * Copyright © $year ${2:$fullname} <${3:$email}> + * Copyright $year ${2:$fullname} <${3:$email}> * * This file is free software; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as @@ -86,7 +86,7 @@ snippet lgpl - scope python, python3 # ${1:$filename} # - # Copyright © $year ${2:$fullname} <${3:$email}> + # Copyright $year ${2:$fullname} <${3:$email}> # # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU Lesser General Public License as @@ -107,7 +107,7 @@ snippet lgpl // // ${1:$filename} // - // Copyright © $year ${2:$fullname} <${3:$email}> + // Copyright $year ${2:$fullname} <${3:$email}> // // This file is free software; you can redistribute it and/or modify it // under the terms of the GNU Lesser General Public License as -- GitLab From fd030979705816a8c6408de6c43e911b922491d2 Mon Sep 17 00:00:00 2001 From: Emmanuele Bassi Date: Mon, 29 Jan 2018 00:07:21 +0000 Subject: [PATCH 4/4] Add MIT license snippet While (L)GPL are the preferred licenses for GNOME code, some of the low level shared code inside the stack is released under the terms of the MIT license, and it would be nice to have a snippet for automating the insertion of these terms into extant code bases. --- data/snippets/licenses.snippets | 79 +++++++++++++++++++++++++++++++++ 1 file changed, 79 insertions(+) diff --git a/data/snippets/licenses.snippets b/data/snippets/licenses.snippets index 055082c28..812a237da 100644 --- a/data/snippets/licenses.snippets +++ b/data/snippets/licenses.snippets @@ -124,3 +124,82 @@ snippet lgpl // // SPDX-License-Identifier: LGPL-3.0-or-later $0 +snippet mit +- scope c, chdr, cpp, css, js, vala + /* ${1:$filename} + * + * Copyright $year ${2:$fullname} <${3:$email}> + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to + * deal in the Software without restriction, including without limitation the + * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or + * sell copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + * SPDX-License-Identifier: MIT + */ + $0 +- scope c-sharp, rust + // + // ${1:$filename} + // + // Copyright $year ${2:$fullname} <${3:$email}> + // + // Permission is hereby granted, free of charge, to any person obtaining a copy + // of this software and associated documentation files (the "Software"), to + // deal in the Software without restriction, including without limitation the + // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or + // sell copies of the Software, and to permit persons to whom the Software is + // furnished to do so, subject to the following conditions: + // + // The above copyright notice and this permission notice shall be included in + // all copies or substantial portions of the Software. + // + // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS + // IN THE SOFTWARE. + // + // SPDX-License-Identifier: MIT + $0 +- scope python, python3 + # + # ${1:$filename} + # + # Copyright $year ${2:$fullname} <${3:$email}> + # + # Permission is hereby granted, free of charge, to any person obtaining a copy + # of this software and associated documentation files (the "Software"), to + # deal in the Software without restriction, including without limitation the + # rights to use, copy, modify, merge, publish, distribute, sublicense, and/or + # sell copies of the Software, and to permit persons to whom the Software is + # furnished to do so, subject to the following conditions: + # + # The above copyright notice and this permission notice shall be included in + # all copies or substantial portions of the Software. + # + # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + # FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS + # IN THE SOFTWARE. + # + # SPDX-License-Identifier: MIT + $0 -- GitLab