Re: (no subject)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Kolev, Nik wrote, around 06/15/2005 06:43 AM:
The way I approach this is have a %post scriptlet that either edits
the files to what they need to be, or overwrites them (while
preserving a copy of the existing ones to restore to when
uninstalling) with the new version of these files (which should be
part of the package).

Something like (I am only trying to demonstrate):

%post mv $(DEFAULT_FILE) $(SAVE_DEFAULT_FILE) mv $(NEW_DEFAULT_FILE)
$(DEFAULT_FILE)

%postun mv $(SAVE_DEFAULT_FILE) $(DEFAULT_FILE)

%files $(NEW_DEFAULT_FILE)

You may also want to consider using a triggers to do this, so you get a chance to react when the original package is updated.

See /usr/share/doc/rpm-*/triggers for info & examples.


[Index of Archives]     [RPM Ecosystem]     [Linux Kernel]     [Red Hat Install]     [PAM]     [Red Hat Watch]     [Red Hat Development]     [Red Hat]     [Gimp]     [Yosemite News]     [IETF Discussion]

  Powered by Linux