sfk163: looks like file masks regression

  • DV

    DV - 2011-10-12

    Steps to reproduce the problem: 
    1. download sfk163.zip
    2. unpack sfk163.zip to some folder and go to that folder
    3. execute "sfk.exe select -dir . -file *.exe" - you will see the following


    4. now execute "sfk.exe select -dir . -file s*.exe" - and you will see nothing! Though if you run sfk 1.6.2 (previous version), it correctly lists all the executable files started with "s*"

  • stahlworks

    stahlworks - 2011-10-12

    That's a bug because I changed internal code for name comparison.
    I hope I fixed it, you may try http://stahlworks.com/dev/sfk/sfkpre.exe
    and tell me if it's now working as expected.
    I also have to do further regression testing before a full update.

  • DV

    DV - 2011-10-13

    sfkpre.exe mostly seems to be OK, though it lists file upd.bat for a mask d*.* which seems to mean "file name started with d with any extension (but not without extension)".
    Also it lists the same upd.bat for a mask *d. which seems to mean "file name ended with d. and without extension". Though sfk 1.6.2 has the same behaviour, so I'm not sure if it's wrong. 

  • stahlworks

    stahlworks - 2011-10-13

    The SFK principle of file selection, as documented by

    sfk help select

    , is quite different.
    If you type

    sfk select -dir mydir -file foo

    it means to select all files having foo somewhere in their name,
    without the need to type * wildcards, as this is the use case most often needed.

    There is also a technical reason for that: under Linux: the * wildcard is misinterpreted by the shell, as it tries to expand it to a list of files, which fails if I want files named like "foo" in all sub folders. Therefore, by default, you do not specify wildcards.

    Now, if you want to select all files starting like foo, you have to type


    . And those ending like foo are selected by


    . To select files named exactly foo.txt, use


    . Under Linux, use / instead of \.

    And there is no syntax to explicitely select empty file extensions. To select files ending with "d.", use



    I hope the help text reflects this sufficiently.


Log in to post a comment.