From 18098a6859a4f382487484ea390ba48fff722d43 Mon Sep 17 00:00:00 2001 From: veclav talica Date: Fri, 16 Feb 2024 16:53:21 +0500 Subject: [PATCH] use #!/usr/bin/env bash --- articles/oscillators/make | 2 +- compile.sh | 7 ++++--- cook_tracks.sh | 2 +- prepare.sh | 2 +- upload.sh | 2 +- 5 files changed, 8 insertions(+), 7 deletions(-) diff --git a/articles/oscillators/make b/articles/oscillators/make index 3ba148c..7db5f66 100755 --- a/articles/oscillators/make +++ b/articles/oscillators/make @@ -1,4 +1,4 @@ -#!/bin/sh +#!/usr/bin/env bash cd $(dirname "$0") mkdir -p ./.dynamic diff --git a/compile.sh b/compile.sh index fc922d3..20fb9ed 100755 --- a/compile.sh +++ b/compile.sh @@ -1,10 +1,11 @@ -#!/bin/sh +#!/usr/bin/env bash set +e # Settings: # ========= export CC=cc +export URL=https://mjestecko.neocities.org mkdir -p ./html/articles @@ -23,8 +24,8 @@ for d in ./articles/*/; do mkdir -p "./html/articles/$(basename -- $d)" cp -r "$d/.static/." "./html/articles/$(basename -- $d)/" fi - ./tools/article_wrapper.py "$d/page.mmd" https://mjestecko.neocities.org | ./tools/mmd/build/multimarkdown > "./html/articles/$(basename -- $d).html" + ./tools/article_wrapper.py "$d/page.mmd" $URL | ./tools/mmd/build/multimarkdown > "./html/articles/$(basename -- $d).html" fi done -./tools/feed_generator.py ./articles/ https://mjestecko.neocities.org > ./html/feed.xml +./tools/feed_generator.py ./articles/ $URL > ./html/feed.xml diff --git a/cook_tracks.sh b/cook_tracks.sh index cb60463..1be7462 100755 --- a/cook_tracks.sh +++ b/cook_tracks.sh @@ -1,4 +1,4 @@ -#!/usr/bin/bash +#!/usr/bin/env bash set +e shopt -s extglob diff --git a/prepare.sh b/prepare.sh index 3ebf3f9..fa42a09 100755 --- a/prepare.sh +++ b/prepare.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/usr/bin/env bash git submodule init git submodule update diff --git a/upload.sh b/upload.sh index e1ae128..a3586c2 100755 --- a/upload.sh +++ b/upload.sh @@ -1,4 +1,4 @@ -#!/usr/bin/bash +#!/usr/bin/env bash for cur in ./html/{*,*/*,*/*/*}; do if [ -f "$cur" ] && [[ ! "$cur" == *.upload-checksum ]]; then