diff options
Diffstat (limited to 'src/librefetch')
-rwxr-xr-x | src/librefetch/librefetch | 31 |
1 files changed, 2 insertions, 29 deletions
diff --git a/src/librefetch/librefetch b/src/librefetch/librefetch index 2412db8..6a05cb9 100755 --- a/src/librefetch/librefetch +++ b/src/librefetch/librefetch @@ -18,8 +18,8 @@ # You should have received a copy of the GNU General Public License # along with Parabola. If not, see <http://www.gnu.org/licenses/>. -export TEXTDOMAIN='libretools' -export TEXTDOMAINDIR='/usr/share/locale' +. /usr/share/libretools/conf.sh +. libremessages declare -r tempdir="$(mktemp -d --tmpdir ${0##*/}.XXXXXXXXXXX)" cleanup() { rm -rf -- "$tempdir"; } @@ -296,33 +296,6 @@ print() { printf -- "$(gettext "$fmt")\n" "$@" } -# Emulates the behavior of bleeding /usr/share/libretools/conf.sh -# without requiring bleeding libretools -load_conf_libretools_librefetch() { - . /etc/libretools.d/librefetch.conf - local ret=0 - for VAR in MIRROR DOWNLOADER; do - if [[ -z ${!VAR:-} ]]; then - echo "Configure '$VAR' in /etc/libretools.d/librefetch.conf" - ret=1 - fi >>/dev/stderr - done - if [[ $ret != 0 ]]; then - return 1 - fi -} - -# From devtools common.sh, which is only distributed in a package with bleeding -# libretools -in_array() { - local needle=$1; shift - local item - for item in "$@"; do - [[ $item = $needle ]] && return 0 # Found - done - return 1 # Not Found -} - ################################################################################ main "$@" |