Compare commits

...

No commits in common. 'c9' and 'i10cs' have entirely different histories.
c9 ... i10cs

@ -10,6 +10,20 @@ debug(){
debug "cjc: bash debug is on"
isJavaConfig() {
local arg="${1}"
local relpath=`realpath -s $arg`
local realink=`readlink -f $arg`
if [[ ${relpath} = /usr/lib/jvm/java* || ${relpath} = /etc/java/java* ]] ; then
if [[ ${realink} = /usr/lib/jvm/java* || ${realink} = /etc/java/java* ]] ; then
debug "$arg / ${relpath} / ${realink} is correct jdk folder"
return 0
fi
fi
debug "$arg / ${relpath} / ${realink} is not jdk folder, file/dir should be skipped"
return 1
}
cmdvDebug() {
if [ "x$debug" == "xtrue" ] ; then
"$@" -v
@ -23,17 +37,35 @@ mvDebug() {
}
rmDebug() {
cmdvDebug rm "$@"
local switch=""
for x in "$@" ; do
if [[ $x == -* ]] ; then
switch="$switch $x"
elif isJavaConfig "$x" ; then
cmdvDebug rm $switch "$x"
fi
done
}
rmdirDebug() {
cmdvDebug rmdir "$@"
local switch=""
for x in "$@" ; do
if [[ $x == -* ]] ; then
switch="$switch $x"
elif isJavaConfig "$x" ; then
cmdvDebug rmdir $switch "$x"
fi
done
}
#we should be pretty strict about removing once used (even "used" [with fail]) config file, as it may corrupt another installation
clean(){
debug "cleanup: removing $config"
rmDebug -rf $config
if [ "x$debug" == "xtrue" ] ; then
rm -rf $config -v
else
rm -rf $config 1>/dev/null 2>&1
fi
}
if [ "x" == "x$config" ] ; then
@ -225,9 +257,12 @@ done
debug "cleaning legacy leftowers"
if [ "x$debug" == "xtrue" ] ; then
find $sourceSearchPath -empty -type d -delete
emptyCandidates=`find $sourceSearchPath -empty -type d`
else
find $sourceSearchPath -empty -type d -delete 2>/dev/null >/dev/null
emptyCandidates=`find $sourceSearchPath -empty -type d 2>/dev/null`
fi
if [ ! "x$emptyCandidates" == "x" ] ; then
rmdirDebug $emptyCandidates
fi
rmdirDebug $sourceSearchPath

@ -7,8 +7,8 @@ Name: copy-jdk-configs
# hash relevant to version tag
%global htag 88d3ed89f30d8b0eb4877d860fa8d951f224f156
Version: 4.0
Release: 3%{?dist}
Version: 4.1
Release: 7%{?dist}
Summary: JDKs configuration files copier
License: BSD
@ -75,9 +75,42 @@ rm "%{rpm_state_dir}/%{file}" 2> /dev/null || :
%license LICENSE
%changelog
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 4.0-3
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
Related: rhbz#1991688
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 4.1-7
- Bump release for October 2024 mass rebuild:
Resolves: RHEL-64018
* Fri Oct 25 2024 MSVSphere Packaging Team <packager@msvsphere-os.ru> - 4.1-6
- Rebuilt for MSVSphere 10
* Mon Jun 24 2024 Troy Dawson <tdawson@redhat.com> - 4.1-6
- Bump release for June 2024 mass rebuild
* Wed Jan 24 2024 Fedora Release Engineering <releng@fedoraproject.org> - 4.1-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Fri Jan 19 2024 Fedora Release Engineering <releng@fedoraproject.org> - 4.1-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Wed Jul 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 4.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 4.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Thu Sep 29 2022 Fedora Release Engineering <releng@fedoraproject.org> - 4.1-1
- update to attempt to solve bug which could delete empty dirs in /etc
* Wed Sep 28 2022 Fedora Release Engineering <releng@fedoraproject.org> - 4.1-0
- update to attempt to solve bug which could delete empty dirs in /etc
* Wed Jul 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 4.0-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Wed Jan 19 2022 Fedora Release Engineering <releng@fedoraproject.org> - 4.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
* Wed Jul 21 2021 Fedora Release Engineering <releng@fedoraproject.org> - 4.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
* Tue Jun 08 2021 Fedora Release Engineering <releng@fedoraproject.org> - 4.0-1
- added requires and orderWithRequires of findutils to provide find and xargs (rh1965305)

Loading…
Cancel
Save