Show a patch.

GET /api/patches/17593/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 17593,
    "url": "https://patchwork.libcamera.org/api/patches/17593/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/17593/",
    "project": {
        "id": 1,
        "url": "https://patchwork.libcamera.org/api/projects/1/?format=api",
        "name": "libcamera",
        "link_name": "libcamera",
        "list_id": "libcamera_core",
        "list_email": "libcamera-devel@lists.libcamera.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": ""
    },
    "msgid": "<20221013095957.1642901-4-kieran.bingham@ideasonboard.com>",
    "date": "2022-10-13T09:59:57",
    "name": "[libcamera-devel,v4,3/3] utils: Provide a release script",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "f2bceed70429ba45441dfa46b351790e15c4a2bc",
    "submitter": {
        "id": 4,
        "url": "https://patchwork.libcamera.org/api/people/4/?format=api",
        "name": "Kieran Bingham",
        "email": "kieran.bingham@ideasonboard.com"
    },
    "delegate": null,
    "mbox": "https://patchwork.libcamera.org/patch/17593/mbox/",
    "series": [
        {
            "id": 3553,
            "url": "https://patchwork.libcamera.org/api/series/3553/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=3553",
            "date": "2022-10-13T09:59:54",
            "name": "Add release infrastructure",
            "version": 4,
            "mbox": "https://patchwork.libcamera.org/series/3553/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/17593/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/17593/checks/",
    "tags": {},
    "headers": {
        "Return-Path": "<libcamera-devel-bounces@lists.libcamera.org>",
        "X-Original-To": "parsemail@patchwork.libcamera.org",
        "Delivered-To": "parsemail@patchwork.libcamera.org",
        "Received": [
            "from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id EBAF5C3286\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 13 Oct 2022 10:00:07 +0000 (UTC)",
            "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 3FCAA62DA6;\n\tThu, 13 Oct 2022 12:00:07 +0200 (CEST)",
            "from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id C189262D6B\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 13 Oct 2022 12:00:02 +0200 (CEST)",
            "from Monstersaurus.ksquared.org.uk.beta.tailscale.net\n\t(cpc89244-aztw30-2-0-cust3082.18-1.cable.virginm.net [86.31.172.11])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 3EEB2CCE;\n\tThu, 13 Oct 2022 12:00:02 +0200 (CEST)"
        ],
        "DKIM-Signature": [
            "v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1665655207;\n\tbh=drqcbLpGgjAQ435jNKUnbsqEYzqiMArqg5oNyQWTv9o=;\n\th=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:\n\tFrom;\n\tb=3BBrbuJtcTDp+fTat12cFVnlPOqp7mKq9jBWYldyVMOkZA8YwU5nM5HYbFQm7vhr1\n\t8Nm/wtnpdwJkIqP63tMRek4NJwP7fT2Xd7xcHjISz9XSptc6qEbMcGQR/AeHREz/oA\n\tzT5qYCeM35mciK5dwTLpFRku5nDrLamN654dHhSQUHpySFGc5xAfHfcK2taFIcyoFB\n\tPLRWk/NHaVOb/jcV8FEDJihqSWa2qWmRK+bgUmxVWgjieZEiAvntDZ/Yk66xRPcidQ\n\tUePTb6FjKVz3EIgG0+VgzO38OOduC702PFRny/PZCmeA1lNTFq/BtdueHYk6yF58uA\n\taR42r6GZ99w1Q==",
            "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1665655202;\n\tbh=drqcbLpGgjAQ435jNKUnbsqEYzqiMArqg5oNyQWTv9o=;\n\th=From:To:Cc:Subject:Date:In-Reply-To:References:From;\n\tb=oSvIizohhSSoNu2v8/MQaEq1TORXVKP9gP2AjraEBXqijV7Oa/c4mkyqYaYOh+azX\n\tAFDoRxB4D3RvxoEKztTWQTqNnza7wD+BjUoIeh4Y3M6fYQZmPVZDFNvZgB0uf49GMx\n\tAysDxB6329UhstUiBCEaZQ6eh6rT8x47uw+lndNw="
        ],
        "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"oSvIizoh\"; dkim-atps=neutral",
        "To": "libcamera devel <libcamera-devel@lists.libcamera.org>",
        "Date": "Thu, 13 Oct 2022 10:59:57 +0100",
        "Message-Id": "<20221013095957.1642901-4-kieran.bingham@ideasonboard.com>",
        "X-Mailer": "git-send-email 2.34.1",
        "In-Reply-To": "<20221013095957.1642901-1-kieran.bingham@ideasonboard.com>",
        "References": "<20221013095957.1642901-1-kieran.bingham@ideasonboard.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[libcamera-devel] [PATCH v4 3/3] utils: Provide a release script",
        "X-BeenThere": "libcamera-devel@lists.libcamera.org",
        "X-Mailman-Version": "2.1.29",
        "Precedence": "list",
        "List-Id": "<libcamera-devel.lists.libcamera.org>",
        "List-Unsubscribe": "<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>",
        "List-Archive": "<https://lists.libcamera.org/pipermail/libcamera-devel/>",
        "List-Post": "<mailto:libcamera-devel@lists.libcamera.org>",
        "List-Help": "<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>",
        "List-Subscribe": "<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>",
        "From": "Kieran Bingham via libcamera-devel\n\t<libcamera-devel@lists.libcamera.org>",
        "Reply-To": "Kieran Bingham <kieran.bingham@ideasonboard.com>",
        "Errors-To": "libcamera-devel-bounces@lists.libcamera.org",
        "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"
    },
    "content": "Support making releases of libcamera by introducing a helper script\nwhich will facilitate the increment of any release version, along with\ngenerating an associated tag.\n\nReviewed-by: Jacopo Mondi <jacopo@jmondi.org>\nReviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\nSigned-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n\n---\nv4\n - Set -e on script to stop on any errors\n - Use -e when creating the release commit to support the releaser\n   adding notes\n - Take the commit message into the signed tag as the release message\n   (No signoffs are stripped)\n\nv3\n - Improve error message\n - Remove redundant git add\n\nSigned-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n---\n utils/release.sh | 46 ++++++++++++++++++++++++++++++++++++++++++++++\n 1 file changed, 46 insertions(+)\n create mode 100755 utils/release.sh",
    "diff": "diff --git a/utils/release.sh b/utils/release.sh\nnew file mode 100755\nindex 000000000000..6b4e081ba179\n--- /dev/null\n+++ b/utils/release.sh\n@@ -0,0 +1,46 @@\n+#!/bin/sh\n+\n+# SPDX-License-Identifier: GPL-2.0-or-later\n+# Prepare a project release\n+\n+set -e\n+\n+# Abort if we are not within the project root or the tree is not clean.\n+if [ ! -e utils/gen-version.sh ] || [ ! -e .git ]; then\n+\techo \"This release script must be run from the root of libcamera git tree.\"\n+\texit 1\n+fi\n+\n+if ! git diff-index --quiet HEAD; then\n+\techo \"Tree must be clean to release.\"\n+\texit 1\n+fi\n+\n+# Identify current version components\n+version=$(./utils/gen-version.sh)\n+\n+# Decide if we are here to bump major, minor, or patch release.\n+case $1 in\n+\tmajor|minor|patch)\n+\t\tbump=$1;\n+\t\t;;\n+\t*)\n+\t\techo \"You must specify the version bump level: (major, minor, patch)\"\n+\t\texit 1\n+\t\t;;\n+esac\n+\n+new_version=$(./utils/semver bump \"$bump\" \"$version\")\n+\n+echo \"Bumping $bump\"\n+echo \"  Existing version is: $version\"\n+echo \"  New version is : $new_version\"\n+\n+# Patch in the version to our meson.build\n+sed -i -E \"s/ version : '.*',/ version : '$new_version',/\" meson.build\n+\n+# Commit the update\n+git commit meson.build -esm \"libcamera v$new_version\"\n+\n+# Create a tag from that commit\n+git show -s --format=%B | git tag \"v$new_version\" -as -F -\n",
    "prefixes": [
        "libcamera-devel",
        "v4",
        "3/3"
    ]
}