Results 1 to 2 of 2
  1. #1
    Join Date
    Jul 2016
    Posts
    3

    Default How to use js format for all txt files in a folder

    I'm working on a project where javascript files must be named as xxx.txt, and cannot have double extensions like *.js.txt. This stupid requirement is imposed by the software consuming my project, I have no way to remove the requirement.

    Although every time I compare the working copy of the txt file with the one in index, I'm able to manually change the file format, is there a way for beyond compare to remember that in this particular path, all txt files are JavaScript files?

  2. #2
    Join Date
    Oct 2007
    Location
    Madison, WI
    Posts
    2,505

    Default

    Yes, you can include relative path information in file format masks. Open the File Formats dialog from the Tools menu ("Beyond Compare" menu on macOS), select "JavaScript Source" from the list on the left, then edit the "Mask" field in the "General" tab on the right. The basic form is something simple like "folder\*.txt", but you can use any of the *, ?, or [a-z] wildcards within folder names, and you can use "..." as "zero or more subfolders" to indicate it should match recursively too. For example "folder\...\*.txt" would match "folder\a.txt" and "folder\subfolder\b.txt", while "folder\*.txt" would only match the first one.
    ZoŽ P Scooter Software

Posting Permissions

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