Modify

#2358 closed Feature Request (Completed)

FileInstall: accept "" as "source" to include the current script

Reported by: vlad@… Owned by: Jon
Milestone: 3.3.9.18 Component: AutoIt
Version: Severity: None
Keywords: Cc:

Description

To the extent of my search, this issue wasn't raised before (sorry if I'm wrong).

I understand the FileInstall's "variable source" issues and I'm not touching that. I also know that AutoIt3Wrapper offers a similar feature (include the current script in the compiled package), but the extraction is somewhat more complex.

As a programmer, I believe that enhancing FileInstall to accept and empty string as "source" and to interpret that as a "placeholder" for the current file shouldn't be too complicated.

The advantages of such an approach would be to ease the file name based versioning if one wants to always include the original script in each compiled exe (the way it is now, the FileInstall() line has to be manually changed each time the script's file name changes).

Attachments (0)

Change History (5)

comment:1 by TicketCleanup, on Jul 20, 2013 at 10:00:02 PM

Version: 3.3.8.1

Automatic ticket cleanup.

comment:2 by guinness, on Jul 20, 2013 at 11:19:30 PM

If this was to be accepted, I would say a pragma directive would be more appropriate. Imagine if a user mistakenly used "" in FileInstall and didn't mean to include their source.

comment:3 by vlad@…, on Jul 21, 2013 at 2:44:06 PM

The directive could be a solution as well ... probably better.

In terms of improper usage, FileInstall is a very special function by its nature and I imagine it is always used "with a clear purpose". As the "source" has to be literal, there is no chance a non-initialized variable could offer a "fake" empty string. So, in my opinion, an "accidental" empty string shouldn't be a real concern.

comment:4 by Jon, on Aug 18, 2013 at 12:21:56 PM

I've written some code that allows aut2exe to handle @ScriptFullPath when used as the first parameter.

comment:5 by Jon, on Aug 18, 2013 at 12:41:19 PM

Milestone: 3.3.9.18
Owner: set to Jon
Resolution: Completed
Status: newclosed

Added by revision [8632] in version: 3.3.9.18

Modify Ticket

Action
as closed The owner will remain Jon.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.