From fb61d5bdd87f0d1844f3a0f8083873eb419269d6 Mon Sep 17 00:00:00 2001 From: "Scott C. MacCallum" Date: Thu, 16 Feb 2023 00:56:01 +0000 Subject: [PATCH] Add blank line removal --- cluster-web-to-other.ksh | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/cluster-web-to-other.ksh b/cluster-web-to-other.ksh index 9ae23c5..5e9ca0e 100755 --- a/cluster-web-to-other.ksh +++ b/cluster-web-to-other.ksh @@ -22,14 +22,24 @@ sed -i 's:

2023<\/a><\ html2text -o /sdf/arpa/ns/s/scm/index -ascii -style pretty /sdf/arpa/ns/s/scm/index.html -# Convert the 02.html file to a 02 text file +# Convert the posts HTML file to a text file html2text -o /sdf/arpa/ns/s/scm/02 -ascii -style pretty /sdf/arpa/ns/s/scm/02.html +# Remove the blank lines from the beginning of the index file + +sed -i '1d;2d;3d' /sdf/arpa/ns/s/scm/index + +# Remove the blank lines from the beginning of the posts file + +sed -i '1d;2d;3d' /sdf/arpa/ns/s/scm/02 + # Write the .plan text file from the index text file cat /sdf/arpa/ns/s/scm/index > .plan +# Write the posts to the top of the .plane file + # Write the index text file to the root of Gopher cp /sdf/arpa/ns/s/scm/index /ftp/pub/users/scm @@ -38,6 +48,8 @@ cp /sdf/arpa/ns/s/scm/index /ftp/pub/users/scm cp /sdf/arpa/ns/s/scm/02 /ftp/pub/users/scm/posts/2023 +# Set the proper Gopher directory permissions + chmod -R 754 /ftp/pub/users/scm #