[Wine] Script to add key to the WINE/Windows registry?

Martin Gregorie martin at gregorie.org
Fri Oct 22 09:18:03 CDT 2010


On Fri, 2010-10-22 at 07:59 -0500, argolance wrote:
> Hello,
> 
> > You can use Wine's regedit or reg programs. They function the same as native ones.
> The chances are that it should be possible but I don't know exactly
> how/what to do! I tried without success! I plan to integrate this
> script to a pinstall.sh pet package and I guess I feel a bit better
> with LINUX scripts!
> 
Do you want to write a script that always loads the same set of keys
into the registry? If so, a 'here document' is probably what you need.
Here's a complete tutorial:

===========tutorial===========
#!/bin/bash

a="Aaaaa"
b=junk

cat >ex1.txt <<EOF
Substitution
This line contains $a
This line contains $b
EOF

echo "==== ex1.txt ===="
cat ex1.txt
echo "================="

cat >ex2.txt <<"FINISH"
No substitution
This line contains $a
This line contains $b
FINISH

echo "==== ex2.txt ===="
cat ex2.txt
echo "================="

rm ex[12].txt

=======end of tutorial========

Substitution in the here document is controlled by the presence or
absence of quotes round the here document delimiter (EOF in my
examples). This is a tested example: cut 'n paste into a file, make it
executable with chmod and experiment with it.


Martin






More information about the wine-users mailing list