Go Back   Winamp Forums > Developer Center > NSIS Discussion

Reply
Thread Tools Search this Thread Display Modes
Old 27th June 2003, 19:53   #1
timecop12
Junior Member
 
Join Date: Jun 2003
Location: Germany
Posts: 20
Question Install in the directory of installer

Hi all,

how can I set the $INSTDIR to the same
directory as the installer file is.

Example:
C:\downloads\myinstaller.exe
$INSTDIR = C:\downloads

It sould be the current path of the installer file.

Thanks
- timecop
timecop12 is offline   Reply With Quote
Old 27th June 2003, 20:01   #2
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,337
Use the GetParent function to get the parent directory of any file. Finding the file is up to you. It can be done searching the hard disk, reading from the registry or any other file. If you need help figuring out how a certain way post back here and someone will surely be able to help.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 27th June 2003, 20:07   #3
Joel
Debian user
(Forum King)
 
Joel's Avatar
 
Join Date: Jan 2003
Location: Arch land
Posts: 4,896
Don't you mean:
$EXEDIR:
code:

InstallDir "$EXEDIR"




* PC: Intel Core 2 DUO E6550 @ 2.33 GHz with 2 GB RAM: Archlinux w/ xfce4.
* Laptop: Intel Core 2 DUO T6600 @ 2.20 GHz with 4 GB RAM: Debian unstable w/ xfce4.
Joel is offline   Reply With Quote
Old 27th June 2003, 20:15   #4
timecop12
Junior Member
 
Join Date: Jun 2003
Location: Germany
Posts: 20
Very fast answer! Thanks.
Now, I was looking in the documentation and I think
InstallDir $EXEDIR
is the an easier way.
timecop12 is offline   Reply With Quote
Old 27th June 2003, 20:21   #5
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,337
Installer, right, my bad. I thought it was another application.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Reply
Go Back   Winamp Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump