From a8271e367a341a3a0a3085db18ce71f4b0d7732d Mon Sep 17 00:00:00 2001 From: Ole Petter Date: Wed, 4 Jan 2023 09:41:52 +0100 Subject: [PATCH 1/3] refac: Add the token type to the lexer debug print Signed-off-by: Ole Petter --- commitlint/commitlint | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/commitlint/commitlint b/commitlint/commitlint index 7c9b088..6f327fd 100755 --- a/commitlint/commitlint +++ b/commitlint/commitlint @@ -85,8 +85,8 @@ function advance() { tok_type = next_tok_type next_tok = _tok next_tok_type = _tok_type - debugf("Current token: %s", tok) - debugf("Next token: %s", next_tok) + debugf("Current token(%s): %s", tok_type, tok) + debugf("Next token(%s): %s", next_tok_type, next_tok) } function _advance() { From 0e8c08b5629c5c2e55f30b32edfcfd7c522297cc Mon Sep 17 00:00:00 2001 From: Ole Petter Date: Wed, 4 Jan 2023 09:43:36 +0100 Subject: [PATCH 2/3] fix: Accept standard git revert commits Ticket: None Changelog: None Signed-off-by: Ole Petter --- commitlint/commitlint | 6 ++++++ commitlint/testcommitlint.sh | 8 +++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/commitlint/commitlint b/commitlint/commitlint index 6f327fd..a219b62 100755 --- a/commitlint/commitlint +++ b/commitlint/commitlint @@ -315,6 +315,12 @@ function is_footer(token) { function parse() { + # In the case of Reverts, the commit is already in the tree, so it need not be + # conforming to our specification. + if (match(next_tok, "Revert")){ + return + } + parse_header() # expect empty line before the body diff --git a/commitlint/testcommitlint.sh b/commitlint/testcommitlint.sh index 1488fea..4959925 100755 --- a/commitlint/testcommitlint.sh +++ b/commitlint/testcommitlint.sh @@ -1,5 +1,5 @@ #! /bin/bash -# Copyright 2022 Northern.tech AS +# Copyright 2023 Northern.tech AS # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -451,5 +451,11 @@ Changelog: none Signed-off-by: Kristian Amlie " +assert "true" \ + "Accept standard git-revert commits" \ +"Revert \"build(docker-client): Add support for building the cpp-client + +This reverts commit 6a80e86e265a1d659bac6e3e67b899ba387f829c.\"" + exit 0 From 11ecb17abb027c8191137f2e53b928f6b34c695f Mon Sep 17 00:00:00 2001 From: Ole Petter Date: Wed, 4 Jan 2023 10:23:20 +0100 Subject: [PATCH 3/3] chore: bump the license year to 2023 Signed-off-by: Ole Petter --- LICENSE | 2 +- LIC_FILES_CHKSUM.sha256 | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/LICENSE b/LICENSE index c58aee7..387f2d5 100644 --- a/LICENSE +++ b/LICENSE @@ -1,4 +1,4 @@ -Copyright 2022 Northern.tech AS +Copyright 2023 Northern.tech AS All content in this project is licensed under the Apache License v2, unless indicated otherwise. diff --git a/LIC_FILES_CHKSUM.sha256 b/LIC_FILES_CHKSUM.sha256 index 8e662f1..ce9ae86 100644 --- a/LIC_FILES_CHKSUM.sha256 +++ b/LIC_FILES_CHKSUM.sha256 @@ -1,5 +1,4 @@ - -1033348db7606a7e61b6484f293847cf8d7a35766efebb97e304d4bd5d7f3f6b LICENSE +52b2497ce07650b825015e80ca7a5d40c360c04c530234ca6d950b0f98bca23a LICENSE # # BSD-3-Clause 2eb550be6801c1ea434feba53bf6d12e7c71c90253e0a9de4a4f46cf88b56477 vendor/github.com/pmezard/go-difflib/LICENSE