2019-04-06 12:36:28 +00:00
|
|
|
#!/bin/sh
|
2019-04-19 11:01:06 +00:00
|
|
|
dir=${1:-"$PWD"} busybox sh -c '
|
|
|
|
if test "$dir";then
|
|
|
|
if test "$dir" = "--help";then
|
2019-04-06 12:36:28 +00:00
|
|
|
echo "replaces /home/ with ~ making friendlier paths.";
|
|
|
|
else
|
2019-04-19 11:01:06 +00:00
|
|
|
true
|
2019-04-06 12:36:28 +00:00
|
|
|
fi;
|
|
|
|
fi
|
2019-04-19 11:01:06 +00:00
|
|
|
dir="${dir:-"$PWD"}";ls -d1p "$dir"|sed -E -e "s\`^[^/]\`$PWD/&\`" -e "s.^/home/$USER.~." -e "s.^/home(/|).~."
|
|
|
|
'
|