changeset 12507:2c465d82bec1 draft

<wib_jonas> `` f=/hackenv/bin/datei; >$f echo $\'#!/bin/bash\\nset -e\\nif (( 1 < $# )); then echo "datei error: too many command-line arguments. Usage: datei datetimestring"; exit 2; fi\\nexec date ${1:+-d "$1"} "+%Y-%m-%d %H:%M:%S.%3N %z %Z %B %-e %A %G-W%V-%u"\'; chmod a+x "$f"
author HackEso <hackeso@esolangs.org>
date Wed, 03 Jul 2024 18:07:19 +0100
parents 4e21820a85a7
children 335a2a849232
files bin/datei
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/bin/datei	Wed Jul 03 17:59:16 2024 +0100
+++ b/bin/datei	Wed Jul 03 18:07:19 2024 +0100
@@ -1,2 +1,4 @@
-#!/bin/sh
+#!/bin/bash
+set -e
+if (( 1 < $# )); then echo "datei error: too many command-line arguments. Usage: datei datetimestring"; exit 2; fi
 exec date ${1:+-d "$1"} "+%Y-%m-%d %H:%M:%S.%3N %z %Z %B %-e %A %G-W%V-%u"