From 46fff7e268c06bf84e86a9b53ad0c7654634b908 Mon Sep 17 00:00:00 2001 From: Hatter Jiang Date: Mon, 6 Apr 2026 01:11:18 +0800 Subject: [PATCH] =?UTF-8?q?=E2=9E=95=20Add=20metadata=20entry=20for=20new?= =?UTF-8?q?=20script=20trim.ts=20in=20script-meta-v2.json=20and=20introduc?= =?UTF-8?q?e=20single-scripts/trim.ts=20file?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- script-meta-v2.json | 9 +++++++++ single-scripts/trim.ts | 10 ++++++++++ 2 files changed, 19 insertions(+) create mode 100755 single-scripts/trim.ts diff --git a/script-meta-v2.json b/script-meta-v2.json index 6a17ecc..a9b9110 100644 --- a/script-meta-v2.json +++ b/script-meta-v2.json @@ -302,6 +302,15 @@ "publish_time": 1769361581018, "update_time": 1769705771521 }, + "trim.ts": { + "script_name": "trim.ts", + "script_length": 383, + "script_sha256": "b6fcabb93f2897823c67fba95968f54127ba93f67371c0156efff3dbb86ab3a0", + "script_full_url": "https://git.hatter.ink/hatter/ts-scripts/raw/branch/main/single-scripts/trim.ts", + "single_script_file": true, + "publish_time": 1775409068941, + "update_time": 1775409068941 + }, "wget.ts": { "script_name": "wget.ts", "script_length": 4076, diff --git a/single-scripts/trim.ts b/single-scripts/trim.ts new file mode 100755 index 0000000..cc8ca2b --- /dev/null +++ b/single-scripts/trim.ts @@ -0,0 +1,10 @@ +#!/usr/bin/env runts -- --allow-all + +import { stdinToArrayBuffer } from "https://script.hatter.ink/@61/deno-commons-mod.ts"; + +const input = new TextDecoder().decode(await stdinToArrayBuffer()); + +console.log(input.trim()); + +// @SCRIPT-SIGNATURE-V1: yk-r1.ES256.20260406T011018+08:00.MEQCICGZsgnG2bowizRaqJcD +// pAguPjyV9zam3gadSDF9MqUwAiANMI4ruImBUecq8S4nZ71BKPGg4BdDb2NZMzVPWFClHg==