From 6e46eb67060deaa0fd3a5bba6397e5142df57f21 Mon Sep 17 00:00:00 2001 From: "Jonathan B. Coe" Date: Sun, 31 Mar 2024 18:25:34 +0100 Subject: [PATCH] Use pre-commit to strip notebook output --- .pre-commit-config.yaml | 4 ++++ Sandbox.ipynb | 14 +++++++------- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index cf3bd3a..68d53a4 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -42,3 +42,7 @@ repos: hooks: - id: black - id: black-jupyter +- repo: https://github.com/kynan/nbstripout + rev: 0.7.1 + hooks: + - id: nbstripout diff --git a/Sandbox.ipynb b/Sandbox.ipynb index a4ec0a6..bbc9f13 100644 --- a/Sandbox.ipynb +++ b/Sandbox.ipynb @@ -3,7 +3,7 @@ { "cell_type": "code", "execution_count": null, - "id": "df29dca7-2d79-42a0-b74f-3eebbd48512d", + "id": "0", "metadata": { "tags": [] }, @@ -15,7 +15,7 @@ { "cell_type": "code", "execution_count": null, - "id": "1d59eb20-7218-4619-9de2-e411cbed53f7", + "id": "1", "metadata": { "tags": [] }, @@ -27,7 +27,7 @@ { "cell_type": "code", "execution_count": null, - "id": "66041f39-125c-4969-9a61-16d327b38fa4", + "id": "2", "metadata": { "tags": [] }, @@ -42,7 +42,7 @@ { "cell_type": "code", "execution_count": null, - "id": "a4c57fec-9e2e-445a-b8cf-9d182f58d88c", + "id": "3", "metadata": { "tags": [] }, @@ -60,7 +60,7 @@ { "cell_type": "code", "execution_count": null, - "id": "e9ba3ee3-b0a7-4b50-93b9-e05660760948", + "id": "4", "metadata": { "tags": [] }, @@ -81,7 +81,7 @@ { "cell_type": "code", "execution_count": null, - "id": "d341bf1b-5df6-4405-9334-6af4fd7c57c3", + "id": "5", "metadata": { "tags": [] }, @@ -93,7 +93,7 @@ { "cell_type": "code", "execution_count": null, - "id": "e6ab9afc-e459-4864-bc95-9f7b1d1d67ae", + "id": "6", "metadata": {}, "outputs": [], "source": []