Skip to content

Commit c96f708

Browse files
committed
Add ".spec" file support
1 parent 87b93e5 commit c96f708

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

addlicense/main.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -365,7 +365,7 @@ func licenseHeader(path string, tmpl *template.Template, data LicenseData) ([]by
365365
lic, err = executeTemplate(tmpl, data, "/**", " * ", " */")
366366
case ".cc", ".cpp", ".cs", ".go", ".hh", ".hpp", ".m", ".mm", ".proto", ".rs", ".swift", ".dart", ".groovy", ".v", ".sv", ".lr":
367367
lic, err = executeTemplate(tmpl, data, "", "// ", "")
368-
case ".py", ".sh", ".bash", ".zsh", ".yaml", ".yml", ".dockerfile", "dockerfile", ".rb", "gemfile", ".ru", ".tcl", ".hcl", ".tf", ".tfvars", ".nomad", ".bzl", ".pl", ".pp", ".ps1", ".psd1", ".psm1", ".txtar":
368+
case ".py", ".sh", ".bash", ".zsh", ".yaml", ".yml", ".dockerfile", "dockerfile", ".rb", "gemfile", ".ru", ".tcl", ".hcl", ".tf", ".tfvars", ".nomad", ".bzl", ".pl", ".pp", ".ps1", ".psd1", ".psm1", ".txtar", ".spec":
369369
lic, err = executeTemplate(tmpl, data, "", "# ", "")
370370
case ".el", ".lisp":
371371
lic, err = executeTemplate(tmpl, data, "", ";; ", "")

addlicense/main_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -317,7 +317,7 @@ func TestLicenseHeader(t *testing.T) {
317317
"// HYS\n\n",
318318
},
319319
{
320-
[]string{"f.py", "f.sh", ".bash", ".zsh", "f.yaml", "f.yml", "f.dockerfile", "dockerfile", "f.rb", "gemfile", ".ru", "f.tcl", "f.bzl", "f.pl", "f.pp", "f.ps1", "f.psd1", "f.psm1", "f.hcl", "f.tf", "f.nomad", "f.tfvars", "f.txtar"},
320+
[]string{"f.py", "f.sh", ".bash", ".zsh", "f.yaml", "f.yml", "f.dockerfile", "dockerfile", "f.rb", "gemfile", ".ru", "f.tcl", "f.bzl", "f.pl", "f.pp", "f.ps1", "f.psd1", "f.psm1", "f.hcl", "f.tf", "f.nomad", "f.tfvars", "f.txtar", "f.spec"},
321321
"# HYS\n\n",
322322
},
323323
{

0 commit comments

Comments
 (0)