From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,HTML_MESSAGE,MAILING_LIST_MULTI autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 4931 invoked from network); 3 Jan 2023 18:20:46 -0000 Received: from minnie.tuhs.org (50.116.15.146) by inbox.vuxu.org with ESMTPUTF8; 3 Jan 2023 18:20:46 -0000 Received: from minnie.tuhs.org (localhost [IPv6:::1]) by minnie.tuhs.org (Postfix) with ESMTP id 5F1A84250F; Wed, 4 Jan 2023 04:20:34 +1000 (AEST) Received: from mail-pj1-f46.google.com (mail-pj1-f46.google.com [209.85.216.46]) by minnie.tuhs.org (Postfix) with ESMTPS id DAC1042506 for ; Wed, 4 Jan 2023 04:20:29 +1000 (AEST) Received: by mail-pj1-f46.google.com with SMTP id o31-20020a17090a0a2200b00223fedffb30so31940731pjo.3 for ; Tue, 03 Jan 2023 10:20:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :from:to:cc:subject:date:message-id:reply-to; bh=SRX8Yi/mpJDrSz2A9I+Mq53Hr37NmtxiBaBRakDU/4Q=; b=lBU19pb3EEsiHBVTtSDxYQrqY2S2i5tdM7x9i4kbQDkA1QJYIuDje4Rl3dFPH1+blc o7MbA5L+uH0/Yrx40dnYRFZ4bOwQ1fk2irzX4jExbky84+ZSrRAXV71qeSw+w/XKF7GH +dub/GexJ8Vr6U9PAdwBUsgPCOy+R8gJ/XNgaKTYYLX3zISAAhh/RYZS++VmjR66zl7r C7m5kYOr63C8/dWCum5hfdZHqXi3lVmisKz3HCGlfOZ3KERxkSfhDxyCeoDHeVJ2Bw1d auD3h67LOrnIFC53JiW2gzHB08tlwzfV0jrumJijdtxf1BJUzUcCKRIBzcpzfr9wgtPQ QHbg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=SRX8Yi/mpJDrSz2A9I+Mq53Hr37NmtxiBaBRakDU/4Q=; b=7+WdHCFamOB0wxw2V6VO2mjlUs5BolbJjulItcPjyqhO4XYGnRD7sp58B1C2yXiZdI W80gZ6yHSaO56Cc2UhiByhL9QWRcaT4MhbD39ITpKhShNRUbVt1coIXseHG8O5MgW6Mm 51r9EtrDg/DgIUBasPvOPJjVhdsYFZelJNITcYkNT6G0rNw8qwQfaGzEA6ZHPbSj/uO0 mne/bYoiddtk1PcbYu7zB/R4BUWCVovnTSa+suf91xw1J63PGnumGDcl2sk3NrABDGMW 5mT0sjKMoP+jwta17ZYqnuz/6sVBDYbh8aATU8UjQnfT+wng1RXq5iOnwHFiS2qSMjc8 HTWQ== X-Gm-Message-State: AFqh2kqGFGyqEs4FpyjIMm2BnUwl5hbvGB53Zv/4fFnQzPMwnyENAbjQ swag8uDCVXwkQ/kirrXA/nziGHdWUuqirO0RUbpoH2dl X-Google-Smtp-Source: AMrXdXuEIgDCLL/kgpRQyg6PBJvJA3xeamwyFZwEebh+z01SPGqT4OFplLq6HMR02DdL1xEHrp864336U0pMoAd88uA= X-Received: by 2002:a17:90a:fa9:b0:225:bf53:e476 with SMTP id 38-20020a17090a0fa900b00225bf53e476mr2919867pjz.104.1672769969084; Tue, 03 Jan 2023 10:19:29 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Niklas Karlsson Date: Tue, 3 Jan 2023 19:19:17 +0100 Message-ID: To: TUHS main list Content-Type: multipart/alternative; boundary="000000000000cc5c7a05f1601ba5" Message-ID-Hash: OZZWAIT2MPHBYGS2VFAWELAS33NEPYUF X-Message-ID-Hash: OZZWAIT2MPHBYGS2VFAWELAS33NEPYUF X-MailFrom: diamondwings@gmail.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-tuhs.tuhs.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.6b1 Precedence: list Subject: [TUHS] Re: A few comments on porting the Bourne shell List-Id: The Unix Heritage Society mailing list Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: --000000000000cc5c7a05f1601ba5 Content-Type: text/plain; charset="UTF-8" Den tis 3 jan. 2023 kl 18:28 skrev Dan Cross : > A few years ago, I was having lunch with some folks from the Go team > and one of them remarked, "you shouldn't write a shell script that's > longer than about 10 lines. Once you do, it's time to rewrite it in a > real programming language." I was a bit taken aback, but they had a > point. I'll note that Go standardized on using bash everywhere. > They wouldn't like my current project. It's a whole bunch of different shell scripts (and they use bash-isms, since it's inconceivable that anyone would use them on a non-Linux non-GNU system) calling each other as modules. The scripts aren't HUGE, but they're certainly a lot more than 10 lines. I work for an academic supercomputing facility, and we have a corporate customer using our systems to do aerodynamics calculations. They want a way to automatically submit jobs on our systems from their own environment, complete with transferring the source data files to us and the results files back to them when they're done. They're integrating that with their own set of scripts (a lot of Python, I believe) so an aerodynamics engineer can just pick an option from a menu and everything works automagically. I'd say bash works pretty well for that application. It's a lot of calling external programs (scp, sbatch (the command to submit a SLURM job, SLURM being the batch management facility a lot of large compute clusters use to manage their jobs), etc). I inherited this set of scripts from someone who quit before I joined in 2020, and have modified them extensively since then to work well with the corporate customer's scripts and be more generic. It's in a fully working state at this point, but I still have some feature requests to take care of. I am more of a sysadmin than a developer, but I certainly can write code when the situation warrants. Pure Windows sysadmins often can't write code at all (though there are certainly some who are very conversant with PowerShell) but I'd say any UNIX/Linux sysadmin worth their salt can at least write shell scripts, and often Python, or some years back, Perl. Niklas --000000000000cc5c7a05f1601ba5 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Den tis 3 jan. 2023 kl 18:28 skrev Dan Cross <crossd@gmail.com>:
A few years ago, I was having lunch with some folks from the Go team
and one of them remarked, "you shouldn't write a shell script that= 's
longer than about 10 lines. Once you do, it's time to rewrite it in a real programming language." I was a bit taken aback, but they had a point. I'll note that Go standardized on using bash everywhere.

They wouldn't like my current project. It&= #39;s a whole bunch of different shell scripts (and they use bash-isms, sin= ce it's inconceivable that anyone would use them on a non-Linux non-GNU= system) calling each other as modules. The scripts aren't HUGE, but th= ey're certainly a lot more than 10 lines.

= I work for an academic supercomputing facility, and we have a corporate cus= tomer using our systems to do aerodynamics calculations. They want a way to= automatically submit jobs on our systems from their own environment, compl= ete with transferring the source data files to us and the results files bac= k to them when they're done. They're integrating that with their ow= n set of scripts (a lot of Python, I believe) so an aerodynamics engineer c= an just pick an option from a menu and everything works automagically. I= 9;d say bash works pretty well for that application. It's a lot of call= ing external programs (scp, sbatch (the command to submit a SLURM job, SLUR= M being the batch management facility a lot of large compute clusters use t= o manage their jobs), etc).

I inherited this set o= f scripts from someone who quit before I joined in 2020, and have modified = them extensively since then to work well with the corporate customer's = scripts and be more generic. It's in a fully working state at this poin= t, but I still have some feature requests to take care of.

I am more of a sysadmin than a developer, but I certainly can writ= e code when the situation warrants. Pure Windows sysadmins often can't = write code at all (though there are certainly some who are very conversant = with PowerShell) but I'd say any UNIX/Linux sysadmin worth their salt c= an at least write shell scripts, and often Python, or some years back, Perl= .

Niklas
--000000000000cc5c7a05f1601ba5--