著者: Rainer Weikusat 日付: To: dng 題目: Re: [DNG] netman-autostart_0.1.1
Edward Bartolo <edbarx@???> writes:
> Hi All,
>
> Thanks for all helpful hints. I used echo to print multiple lines
> including the two lines, i.e. the lines starting with "Exec=" and
> "Comment=", in one command. The output is used to recreate the .deskop
> file as follows:
>
> Code quoted from: netman-gui.postinst: (lines 72 - 83)
>
> rm -f "${launcher}"
> echo \
> "[Desktop Entry]
> Categories=Application;Network;
> ${line}
> ${comment}
> GenericName=Netman
> Icon=netman.ico
> Name=Netman Network Manager
> Terminal=false
> Type=Application
> Categories=Network;" > "${launcher}"
>
> This worked as required without issues.
Assuming that blindly overwriting a conf-file like above is ok, a
so-called here document can be used in order to cut down on the amount
of "syntactic decoration", eg,
NB: I think this is correct, however, I didn't test it this time. It's
reasonably simple and Edward would just claim that it corrupted the
harddisk partition table, anyway ...