+++ /dev/null
-#!/usr/bin/env perl
-
-my $mode = "NONE";
-my @modified, @added, @removed;
-
-while($line = <>) {
- if ($line =~ /Modified Files:/) {
- $mode = "MODIFIED";
- next;
- }
-
- if ($line =~ /Added Files:/) {
- $mode = "ADDED";
- next;
- }
-
- if ($line =~ /Removed Files:/) {
- $mode = "REMOVED";
- next;
- }
-
- if ($mode eq "NONE") { next; }
- if ($line =~ /-------/) { next; }
-
- chop($line);
- $line =~ s/^CVS:\s+//;
- $line =~ s/\s+$//;
- # print "processing $line for $mode\n";
- @files = split(/ /, $line);
- # print "new files for $mode: ", join(', ', @files), "\n";
-
- if ($mode eq "MODIFIED") {
- push(@modified, @files);
- } elsif ($mode eq "ADDED") {
- push(@added, @files);
- } elsif ($mode eq "REMOVED") {
- push(@removed, @files);
- } else {
- die "Unknown mode $mode!";
- }
-}
-
-print join(' ', @modified);
-if ($ENV{"SHOW_ALL_FILES"} ne "no") {
- print ' ', join(' ', @added), ' ', join(' ', @removed);
-}
-print "\n";
+++ /dev/null
-#!/bin/bash
-# Put this script and cvs-modified-files.pl into your PATH (~bin is good) and
-#
-# export CVSEDITOR=cvsdiffclient
-#
-# in your .bashrc and you will get a nice bunch of CVS commit reminders:
-# <merge/land tag information>
-# b=<bug_number>
-# r=<reviewed by>
-#
-# Remember to remove the leading "CVS: " part of the comment before saving
-# your commit comment if you want those entries to be saved.
-
-[ -f .mergeinfo ] && . ./.mergeinfo
-
-FILES=`cvs-modified-files.pl $1`
-TMP=`mktemp /tmp/cvslog-XXXXXXXX`
-if [ -f $TMP ]; then
- if [ -f .mergeinfo ]; then
- . .mergeinfo
- [ "$OPERATION" ] || OPERATION=Update
- [ "$OPERWHERE" ] || OPERWHERE=from
- echo "CVS: $OPERATION $child $OPERWHERE $parent ($date)" >> $TMP
- elif [ -r CVS/Tag ]; then
- echo "CVS: Branch: `sed 's/^T//' CVS/Tag`" >> $TMP
- fi
- echo "CVS: did you update the ChangeLog for a bug fix?" >> $TMP
- echo "CVS: did you update the hours spent in Bugzilla?" >> $TMP
- echo "CVS: b=<bug>" >> $TMP
- echo "CVS: r=<reviewed_by>" >> $TMP
-
- cat $1 >> $TMP
- cp $TMP $1
- rm $TMP
-fi
-
-if [ "${FILES:+have_files}"x = have_filesx ]; then
- echo Diffing $1 : $FILES
- cvs diff -wbBup $FILES 2>/dev/null | sed "s/^/CVS: /" >>$1
-fi
-#gnuclient $1 || vi $1
-[ "$EDITOR" ] || EDITOR=vi
-
-$EDITOR $1
+++ /dev/null
-cvs -z3 -q
-diff -u -p
-co -d -P
-update -d -P
-commit
+++ /dev/null
-# Readlink is not present on some older distributions: emulate it.
-readlink() {
- local path=$1 ll
-
- if [ -L "$path" ]; then
- ll="$(LC_ALL=C ls -l "$path" 2> /dev/null)" &&
- echo "${ll/* -> }"
- else
- return 1
- fi
-}
-relink() {
- if [ -h "$2" ]; then
- local old=$(readlink "$2")
- [ "$old" = "$1" ] && return 0
- echo "Changing symlink $2 from $old to $1"
- elif [ -e "$2" ]; then
- echo "Replacing file $2 with symlink to $1"
- fi
- rm -f "$2" \
- && ln -s "$1" "$2"
-}
+++ /dev/null
-if [ -f /boot/vmlinuz-%ver_str ]; then
- image=vmlinuz
-elif [ -f /boot/image-%ver_str ]; then
- image=image
-elif [ -f /boot/vmlinux-%ver_str ]; then
- image=vmlinux
-else
- # nothing to do (UML kernels for example).
- exit 0
-fi
-
-# If we have old symlinks, rename them to *.previous
-if [ -L /boot/$image -a -L /boot/initrd -a \
- "$(readlink /boot/$image)" != $image-%ver_str -a \
- "$(readlink /boot/initrd)" != initrd-%ver_str ]; then
- mv /boot/$image /boot/$image.previous
- mv /boot/initrd /boot/initrd.previous
-fi
-
-# update /boot/vmlinuz symlink
-relink $image-%ver_str /boot/$image
-
-if test "$YAST_IS_RUNNING" != instsys ; then
- if [ -f /etc/fstab ]; then
- echo Setting up /lib/modules/%ver_str
- /sbin/update-modules.dep -v %ver_str
- cd /boot
- /sbin/mkinitrd -k $image-%ver_str -i initrd-%ver_str
-
- if [ -e /boot/initrd-%ver_str ]; then
- relink initrd-%ver_str /boot/initrd
- else
- rm -f /boot/initrd
- fi
- else
- echo "please run mkinitrd as soon as your system is complete"
- fi
-fi
-
-if [ "$YAST_IS_RUNNING" != instsys -a -x /sbin/new-kernel-pkg ]; then
- # Notify boot loader that a new kernel image has been installed.
- # (during initial installation the boot loader configuration does not
- # yet exist when the kernel is installed, but yast kicks the boot
- # loader itself later.)
- /sbin/new-kernel-pkg %ver_str
-fi
+++ /dev/null
-if [ -L /boot/vmlinux ]; then
- image=vmlinux
-elif [ -L /boot/vmlinuz ]; then
- image=vmlinuz
-elif [ -L /boot/image ]; then
- image=image
-else
- # nothing to do (UML kernels for example).
- exit 0
-fi
-
-if [ "$(readlink /boot/$image)" = $image-%ver_str ]; then
- # This may be the last kernel RPM on the system, or it may
- # be an update. In both of those cases the symlinks will
- # eventually be correct. Only if this kernel
- # is removed and other kernel rpms remain installed,
- # find the most recent of the remaining kernels, and make
- # the symlinks point to it. This makes sure that the boot
- # manager will always have a kernel to boot in its default
- # configuration.
- shopt -s nullglob
- for image in $(cd /boot ; ls -dt $image-*); do
- initrd=initrd-${image#*-}
- if [ -f /boot/$image -a -f /boot/$initrd ]; then
- relink $image /boot/${image%%%%-*}
- relink $initrd /boot/${initrd%%%%-*}
- break
- fi
- done
- shopt -u nullglob
-fi
-
-# Created in the other kernel's %post
-case "$(readlink /boot/$image.previous)" in
-$image-%ver_str|$(readlink /boot/$image))
- rm -f /boot/$image.previous ;;
-esac
-case "$(readlink /boot/initrd.previous)" in
-initrd-%ver_str|$(readlink /boot/initrd))
- rm -f /boot/initrd.previous ;;
-esac
-# created in %post
-rm -f /boot/initrd-%ver_str
+++ /dev/null
-old_shopt=$(shopt -p nullglob || :)
-shopt -s nullglob
-for script in /lib/modules/scripts/* ; do
- if [ -f "$script" -a -x "$script" ] \
- && ! "$script" --@when@ %ver_str $1 ; then
- echo "$script failed."
- fi
-done
-eval $old_shopt