Uploaded image for project: 'Puppet'
  1. Puppet
  2. PUP-8243

Allow ERB templates to be tolerant of a leading BOM

    XMLWordPrintable

Details

    • Hide

      An ERB template with a leading BOM should work properly in the PowerShell module

      Show
      An ERB template with a leading BOM should work properly in the PowerShell module
    • Coremunity
    • Platform Core KANBAN
    • Enhancement
    • Previously, if a template contained a BOM, then it was preserved by the `template` function, and would end up in the resulting file or PowerShell command. Now we pass the `bom` option when reading the file, which strips the BOM as it is read.
    • Needs Assessment

    Description

      See additional details in MODULES-1996 / PUP-6447.

      The basic gist is that internal calls to read, like the one made by template loading with Puppet::FileSystem.read_preserve_line_endings, do not specify the "allow bom" flag when reading UTF-8 files.

      This should be a straightforward addition that allows templates (for instance PowerShell templates that were once PS1 files created by PowerShell ISE that have a leading BOM) to properly remove the leading BOM.

      Attachments

        Issue Links

          Activity

            People

              josh Josh Cooper
              ethan Ethan Brown
              Votes:
              1 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Zendesk Support