FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Fedora User

 
 
LinkBack Thread Tools
 
Old 07-22-2011, 02:36 PM
Richard Shaw
 
Default creating .rpm files for special installations

On Fri, Jul 22, 2011 at 9:24 AM, g <geleem@bellsouth.net> wrote:
> not recalling all abilities of rpm, my question is, can rpm/yum append to
> existing files?

I'm not a super experienced rpm user but I don't know of any way to do
it directly with rpm but you could use a scriptlet to do the work.

Depending on how the information needs to be added to the config file
there are many ways to handle that part, whatever you can manage with
common shell tools.

1. "cat" it onto the end?
2. sed

The best situation I think would be if there's a <config>.d/ type
directory where you can just drop a config file in it. That way if you
ever want to update it you can create a new plugin package to replace
the file, and yum erase will work properly.

Richard
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
 
Old 07-22-2011, 02:39 PM
Todd Zullinger
 
Default creating .rpm files for special installations

g wrote:
> on firefox tsl, a user of ubuntu needs to run a lan system wide
> installation of an extension to firefox.
>
> a reply was to create a .deb package and put in a local repository,
> add local repo to all clients repo list.
>
> to add an extension to firefox, appending to some config files is
> required.
>
> not recalling all abilities of rpm, my question is, can rpm/yum
> append to existing files?

It can. Whether it should is another matter. But the rpm scriptlets
are run as root, so you can do most anything.

--
Todd OpenPGP -> KeyID: 0xBEAF0CE3 | URL: www.pobox.com/~tmz/pgp
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~
Never do today that which will become someone else's responsibility
tomorrow.

--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
 
Old 07-22-2011, 07:37 PM
g
 
Default creating .rpm files for special installations

On 07/22/2011 02:24 PM, g wrote:
<>

> not recalling all abilities of rpm, my question is, can rpm/yum append to
> existing files?

to Richard Shaw and Todd Zullinger,

i thank you for your replies.

as yet, i have not been to rpm.org to refresh on operations of rpm and
appending to files. i will do so in near future.

right now, i am refreshing on iptables so i can get back to another thread.

i did google rpm.org for 'scriptlet' and had 864 hits. none of which did
i take time to go thru. obviously, or i would still be reading.

again, thank you for replies.

i will post back when i find a positive/negative answer.


later.
--

peace out.

tc.hago,

g
.

****
in a free world without fences, who needs gates.
**
help microsoft stamp out piracy - give linux to a friend today.
**
to mess up a linux box, you need to work at it.
to mess up an ms windows box, you just need to *look* at it.
**
The installation instructions stated to install Windows 2000 or better.
So I installed Linux.
**
learn linux:
'Rute User's Tutorial and Exposition' http://rute.2038bug.com/index.html
'The Linux Documentation Project' http://www.tldp.org/
'LDP HOWTO-index' http://www.tldp.org/HOWTO/HOWTO-INDEX/index.html
'HowtoForge' http://howtoforge.com/
****

--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
 
Old 07-22-2011, 08:11 PM
Richard Shaw
 
Default creating .rpm files for special installations

On Fri, Jul 22, 2011 at 2:37 PM, g <geleem@bellsouth.net> wrote:
> On 07/22/2011 02:24 PM, g wrote:
> <>
>
>> not recalling all abilities of rpm, my question is, can rpm/yum append to
>> existing files?
>
> to Richard Shaw and Todd Zullinger,
>
> i thank you for your replies.
>
> as yet, i have not been to rpm.org to refresh on operations of rpm and
> appending to files. i will do so in near future.
>
> right now, i am refreshing on iptables so i can get back to another thread.
>
> i did google rpm.org for 'scriptlet' and had 864 hits. none of which did
> i take time to go thru. obviously, or i would still be reading.

Sorry, I wasn't intentionally obtuse

A scriptlet is nothing more than a bash script within the spec file[1]
of an RPM package. For your purposes I think the appropriate place to
do what you're trying to do is in the "%post" section. This is
executed after package install.

Also, if you want to undo whatever you do in the %post script then you
would put that "scriptlet" in %postun.

Richard

[1] http://www.rpm.org/max-rpm/s1-rpm-inside-scripts.html
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
 
Old 07-22-2011, 08:46 PM
g
 
Default creating .rpm files for special installations

On 07/22/2011 08:11 PM, Richard Shaw wrote:
<>

> Sorry, I wasn't intentionally obtuse

'obtuse' is by no means a word i would use in describing your help.

nor 'vague', by any stretching of imagination.

'nebulous', but a stretch of it's meaning.

'guiding in a general direction' does come to mind now that you have
me thinking about.

> A scriptlet is nothing more than a bash script within the spec file[1]
> of an RPM package. For your purposes I think the appropriate place to
> do what you're trying to do is in the "%post" section. This is
> executed after package install.

ok.more guidance. !yeah!

> Also, if you want to undo whatever you do in the %post script then you
> would put that "scriptlet" in %postun.

more guidance. !yeah!

> Richard
>
> [1] http://www.rpm.org/max-rpm/s1-rpm-inside-scripts.html

again, i thank you for you offerings of help.

i would not and do not expect an exact answer because what i am questioning
is not something that would be normally needed.


[years ago, in 7th grade, my homeroom and english teacher told me i was
impudent. when i told her 'thank you' and class cracked up laughing,
she sent me to principal's office. because principal new me, even she
cracked up laughing when i told her what happened. while principal and
i walked back to the teacher, we had a very good and enjoyable
conversation. when we entered teachers room, principal told her she did
not believe that i was impudent and immediately transfered me to another
homeroom and a new english teacher. i got along great with both of them.]


--

peace out.

tc.hago,

g
.

****
in a free world without fences, who needs gates.
**
help microsoft stamp out piracy - give linux to a friend today.
**
to mess up a linux box, you need to work at it.
to mess up an ms windows box, you just need to *look* at it.
**
The installation instructions stated to install Windows 2000 or better.
So I installed Linux.
**
learn linux:
'Rute User's Tutorial and Exposition' http://rute.2038bug.com/index.html
'The Linux Documentation Project' http://www.tldp.org/
'LDP HOWTO-index' http://www.tldp.org/HOWTO/HOWTO-INDEX/index.html
'HowtoForge' http://howtoforge.com/
****

--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
 
Old 07-22-2011, 08:55 PM
Richard Shaw
 
Default creating .rpm files for special installations

On Fri, Jul 22, 2011 at 3:46 PM, g <geleem@bellsouth.net> wrote:
> On 07/22/2011 08:11 PM, Richard Shaw wrote:
> <>
>
>> Sorry, I wasn't intentionally obtuse
>
> 'obtuse' is by no means a word i would use in describing your help.

Well that was a bit tongue-in-cheek

Yeah, I recently (last few months) became a Fedora and RPM Fusion
packager and I've learned a great deal in a short amount of time
troubleshooting packages (mine and others). I've still got a lot to
learn so when I offer help I hope someone more experienced is around
just in case I lead someone astray!

Richard
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
 
Old 07-22-2011, 09:16 PM
g
 
Default creating .rpm files for special installations

On 07/22/2011 08:55 PM, Richard Shaw wrote:
> On Fri, Jul 22, 2011 at 3:46 PM, g <geleem@bellsouth.net> wrote:
>> On 07/22/2011 08:11 PM, Richard Shaw wrote:
<>

>>> Sorry, I wasn't intentionally obtuse
>> 'obtuse' is by no means a word i would use in describing your help.
>
> Well that was a bit tongue-in-cheek

slightly.

> Yeah, I recently (last few months) became a Fedora and RPM Fusion
> packager and I've learned a great deal in a short amount of time
> troubleshooting packages (mine and others). I've still got a lot to
> learn so when I offer help I hope someone more experienced is around
> just in case I lead someone astray!

very few know everything about what they are doing when it is new. only
with practice and time will you ever come near.

and hope that you never reach that finial point of knowing it all. life
can and will become dull when there is nothing new.


i will pass along what my high school phys ed coach told me;

perseverance. always remember it and you will accomplish what you want.

i learned to apply it and it has proved very true.


--

peace out.

tc.hago,

g
.

****
in a free world without fences, who needs gates.
**
help microsoft stamp out piracy - give linux to a friend today.
**
to mess up a linux box, you need to work at it.
to mess up an ms windows box, you just need to *look* at it.
**
The installation instructions stated to install Windows 2000 or better.
So I installed Linux.
**
learn linux:
'Rute User's Tutorial and Exposition' http://rute.2038bug.com/index.html
'The Linux Documentation Project' http://www.tldp.org/
'LDP HOWTO-index' http://www.tldp.org/HOWTO/HOWTO-INDEX/index.html
'HowtoForge' http://howtoforge.com/
****

--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
 

Thread Tools




All times are GMT. The time now is 06:09 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org