Indigo Rose Software

Professional Software Development Tools

 
Results 1 to 11 of 11

Thread: Relative Paths

  1. #1
    Join Date
    Dec 2004
    Posts
    1

    Relative Paths

    How to create an installer using relative paths for the original files? We use VSS and each developer might have a different path. We don't want to rebuild the installer every time a developer wants to create one.

    thanks

  2. #2
    Join Date
    Jan 2000
    Posts
    2,002
    You can't use relatve paths. However, what you can do is use a design time constant (Publish > Settings > Constants) in the path:

    #LOCAL_FOLDER# = C:\Brett's Test Folder

    File sources:

    #LOCAL_FOLDER#
    #LOCAL_FOLDER#\Data
    #LOCAL_FOLDER#\Docs
    #LOCAL_FOLDER#\Images
    etc...

    Then when you want to change the local source location, just change the DT constant value.

  3. #3
    Hi Brett,

    I ran into a similar situation and that solution worked well for me. However, is it possible to base this off a system variable? (E.g. set from a cmd prompt) This way other developers / building system does not need to be manually configured every time.

    Regards,

    Pascal

  4. #4
    Join Date
    Jan 2001
    Location
    Anderson Island, WA, USA
    Posts
    2,861
    Quote Originally Posted by Pascal v Vuuren View Post
    I ran into a similar situation and that solution worked well for me. However, is it possible to base this off a system variable? (E.g. set from a cmd prompt) This way other developers / building system does not need to be manually configured every time.
    While not ideal; I put the sf7 files in the "root" of the project I'm working on -- then I use "relative" paths based on #PROJECTFILEDIR#


    (Click here to contact me)
    Providing Independent Professional Consulting Services for
    IndigoRose products, World Wide.
    Located in -8:00 (-7:00 DST) GMT Timezone (Western United States)

  5. #5
    Quote Originally Posted by jassing View Post
    While not ideal; I put the sf7 files in the "root" of the project I'm working on -- then I use "relative" paths based on #PROJECTFILEDIR#
    Thank you, that is an interesting solution to the problem. I'll need to see if anybody in the team has any objections to relocating the Installation Scripts to the project root, but that sounds like it would work.

  6. #6
    Join Date
    Jan 2001
    Location
    Anderson Island, WA, USA
    Posts
    2,861
    Quote Originally Posted by Pascal v Vuuren View Post
    Thank you, that is an interesting solution to the problem. I'll need to see if anybody in the team has any objections to relocating the Installation Scripts to the project root, but that sounds like it would work.
    For one client, they use vault (like source safe) to store files; and everyone has a different directory structure on their local machines. Since switching to #PRJOJECTFILEDIR# no one has complained about missing files.

    I use #SUFDIR# for all includes.
    the #projectfiledir# works 'everywhere' (files, output, incldues).

    Good luck.
    -j


    (Click here to contact me)
    Providing Independent Professional Consulting Services for
    IndigoRose products, World Wide.
    Located in -8:00 (-7:00 DST) GMT Timezone (Western United States)

  7. #7
    My main concern was for the automated building environment, as any given installer will typically only have one developer attending to it and the folder structures are generally the same. However, when building the actual folder will depend on the number of previous builds for that version that have not yet been archived. So it might be D:\Build.700.01, D:\Build.700.02, etc.

    However, I see you can specify a command line constant file, which will replace any of the defined constants with the values from the file. That simplifies matters greatly.

    Thank you for the assistance guys.

  8. #8
    Join Date
    Jul 2007
    Posts
    37

    Does any of this apply to SUFI?

    I am trying to do the same thing with SUFI. Does any of this apply and if so where do you set these constants? The menu structure is not the same and I haven't found a place that seems to work.

    Thanks,

    Ken

  9. #9
    Join Date
    Jan 2001
    Location
    Anderson Island, WA, USA
    Posts
    2,861
    Quote Originally Posted by kcfischer View Post
    I am trying to do the same thing with SUFI. Does any of this apply and if so where do you set these constants? The menu structure is not the same and I haven't found a place that seems to work.

    Thanks,

    Ken

    Sort of; however it's not the same.
    $(var.ProjectFolder) in SUFWI would be the same as #PROJECTFILEDIR# in suf7

    In SUFWI's help -- look at the topic "Global Build Variables" for more information.


    (Click here to contact me)
    Providing Independent Professional Consulting Services for
    IndigoRose products, World Wide.
    Located in -8:00 (-7:00 DST) GMT Timezone (Western United States)

  10. #10
    Join Date
    Feb 2001
    Location
    Indigo Rose Software
    Posts
    2,728
    It's also worth noting that relative paths are supported in SUFWI (relative to the location of the .sufproj file).
    --[[ Indigo Rose Software Developer ]]

  11. #11
    Join Date
    Jul 2007
    Posts
    37
    Thanks. I found the reference to file paths being relative to the project folder in the release notes. For anyone else reading this in the furture. If you have a Files subfolder that sits just below your SUFI project file, use Files for the path to the file (no backslash or variable name needed)

    Still working through the details on the bootstrapper, but I think I can set this up so it will work on our build machines.

    Thanks for the help!

    Ken

Similar Threads

  1. indexed .wmv video and .pdf's
    By compass in forum AutoPlay Media Studio 4.0
    Replies: 1
    Last Post: 06-07-2004, 07:14 PM
  2. Getting System Folder Paths
    By Desmond in forum AutoPlay Media Studio 5.0 Examples
    Replies: 0
    Last Post: 10-01-2003, 02:39 PM
  3. preventing certain paths
    By mpaulson in forum Setup Factory 6.0
    Replies: 1
    Last Post: 08-05-2003, 04:01 PM
  4. Remove hard coded paths
    By TimCarroll in forum Setup Factory 6.0
    Replies: 0
    Last Post: 07-10-2002, 12:46 PM
  5. Relative paths for source files
    By John Schacher in forum Setup Factory 5.0
    Replies: 1
    Last Post: 06-02-2000, 01:29 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts