From 479db85286294ac98639c29e45cb4786cee276a1 Mon Sep 17 00:00:00 2001 From: Turiiya Date: Thu, 12 Dec 2024 14:56:39 +0100 Subject: [PATCH] use better portable shebang in scripts --- download_samples.sh | 2 +- download_voices_tts-1-hd.sh | 4 ++-- download_voices_tts-1.sh | 2 +- startup.min.sh | 2 +- startup.sh | 2 +- test_voices.sh | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/download_samples.sh b/download_samples.sh index b74c22f..cf48b07 100755 --- a/download_samples.sh +++ b/download_samples.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/usr/bin/env bash for i in alloy echo fable onyx nova shimmer; do [ ! -e "voices/$i.wav" ] && curl -s https://cdn.openai.com/API/docs/audio/$i.wav | ffmpeg -loglevel error -i - -ar 22050 -ac 1 voices/$i.wav done diff --git a/download_voices_tts-1-hd.sh b/download_voices_tts-1-hd.sh index f101b00..c2a8c92 100755 --- a/download_voices_tts-1-hd.sh +++ b/download_voices_tts-1-hd.sh @@ -1,8 +1,8 @@ -#!/bin/sh +#!/usr/bin/env bash export COQUI_TOS_AGREED=1 export TTS_HOME=voices for model in $*; do python -c "from TTS.utils.manage import ModelManager; ModelManager().download_model('$model')" done -./download_samples.sh \ No newline at end of file +./download_samples.sh diff --git a/download_voices_tts-1.sh b/download_voices_tts-1.sh index cf9da1b..b3df672 100755 --- a/download_voices_tts-1.sh +++ b/download_voices_tts-1.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/usr/bin/env bash models=${*:-"en_GB-northern_english_male-medium en_US-libritts_r-medium"} # en_US-ryan-high piper --update-voices --data-dir voices --download-dir voices --model x 2> /dev/null for i in $models ; do diff --git a/startup.min.sh b/startup.min.sh index 28bd195..947327d 100755 --- a/startup.min.sh +++ b/startup.min.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash [ -f speech.env ] && . speech.env diff --git a/startup.sh b/startup.sh index 009286e..7c02617 100755 --- a/startup.sh +++ b/startup.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash [ -f speech.env ] && . speech.env diff --git a/test_voices.sh b/test_voices.sh index faa452a..5268743 100755 --- a/test_voices.sh +++ b/test_voices.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash URL=${1:-http://localhost:8000/v1/audio/speech}