diff options
author | Raymaekers Luca <raymaekers.luca@gmail.com> | 2023-04-04 14:02:28 +0200 |
---|---|---|
committer | Raymaekers Luca <raymaekers.luca@gmail.com> | 2023-04-04 14:02:28 +0200 |
commit | dc03fb40fe55a7dc88c07509b47299223d4d5815 (patch) | |
tree | 93d33df604005218d287d535b37dfc4ab9de307d /bin/common | |
parent | 1496b8724c39dd6d16a46916ad4ed47a83a44852 (diff) |
cleaned up scripts, use sh (-> dash) where possible
Diffstat (limited to 'bin/common')
-rwxr-xr-x | bin/common/autofetch | 2 | ||||
-rwxr-xr-x | bin/common/gign | 2 | ||||
-rwxr-xr-x | bin/common/hextorgb | 15 | ||||
-rwxr-xr-x | bin/common/wt | 4 | ||||
-rwxr-xr-x | bin/common/y2feed | 2 |
5 files changed, 13 insertions, 12 deletions
diff --git a/bin/common/autofetch b/bin/common/autofetch index 3dcdc15..ae48444 100755 --- a/bin/common/autofetch +++ b/bin/common/autofetch @@ -1,4 +1,4 @@ -#!/usr/bin/env bash +#!/usr/bin/env sh GREEN='\033[0;32m' NC='\033[0m' # Fetches for git repos, meant to run at startup diff --git a/bin/common/gign b/bin/common/gign index e3ba12a..e82c0b8 100755 --- a/bin/common/gign +++ b/bin/common/gign @@ -1,2 +1,2 @@ -#!/usr/bin/env bash +#!/usr/bin/env sh git status --porcelain=v1 | grep "^??" | cut -d' ' -f2- | sed -r 's/^["](.*)["]$/\1/' >> .gitignore diff --git a/bin/common/hextorgb b/bin/common/hextorgb index b268db5..e70040e 100755 --- a/bin/common/hextorgb +++ b/bin/common/hextorgb @@ -1,7 +1,8 @@ -#!/usr/bin/env bash -cat /dev/stdin \ - | tr -d '#' | tr '[:lower:]' '[:upper:]' \ - | sed -r 's/([0-9A-F]{2})/\1\n/g ; i ibase=16' \ - | bc \ - | tr '\n' ',' \ - | sed 's/.$// ; s/.*/rgb(&)/' +#!/usr/bin/env sh +cat /dev/stdin | + tr -d '#' | + tr '[:lower:]' '[:upper:]' | + sed -r 's/([0-9A-F]{2})/1n/g ; i ibase=16' | + bc | + tr 'n' ',' | + sed 's/.$// ; s/.*/rgb(&)/' diff --git a/bin/common/wt b/bin/common/wt index 81081c8..0568b99 100755 --- a/bin/common/wt +++ b/bin/common/wt @@ -1,9 +1,9 @@ -#!/bin/bash +#!/bin/sh echo "$@" > /tmp/truewhile.tmp while true do - bash /tmp/truewhile.tmp + sh /tmp/truewhile.tmp sleep 1 clear done diff --git a/bin/common/y2feed b/bin/common/y2feed index e5e2201..0f27d68 100755 --- a/bin/common/y2feed +++ b/bin/common/y2feed @@ -1,4 +1,4 @@ -#!/usr/bin/env bash +#!/usr/bin/env sh test -z "${url:=$1}" \ && url="$(cat /dev/stdin)" |