cmd: Add a blank line between copyright and license

This commit is contained in:
Anthony Fok 2017-07-30 02:15:55 -06:00
parent 75c6acfc8f
commit a1b7d3cc4d
5 changed files with 9 additions and 3 deletions

View file

@ -121,7 +121,8 @@ func validateCmdName(source string) string {
func createCmdFile(license License, path, cmdName string) {
template := `{{comment .copyright}}
{{comment .license}}
{{if .license}}//
{{comment .license}}{{end}}
package {{.cmdPackage}}

View file

@ -107,7 +107,8 @@ func createLicenseFile(license License, path string) {
func createMainFile(project *Project) {
mainTemplate := `{{ comment .copyright }}
{{if .license}}{{ comment .license }}{{end}}
{{if .license}}//
{{ comment .license }}{{end}}
package main
@ -135,7 +136,8 @@ func main() {
func createRootCmdFile(project *Project) {
template := `{{comment .copyright}}
{{if .license}}{{comment .license}}{{end}}
{{if .license}}//
{{comment .license}}{{end}}
package cmd

View file

@ -1,4 +1,5 @@
// Copyright © 2017 NAME HERE <EMAIL ADDRESS>
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at

View file

@ -1,4 +1,5 @@
// Copyright © 2017 NAME HERE <EMAIL ADDRESS>
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at

View file

@ -1,4 +1,5 @@
// Copyright © 2017 NAME HERE <EMAIL ADDRESS>
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at