Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

An extra whitespace indentation for the Apache License template #134

Closed
XuehaiPan opened this issue Nov 22, 2022 · 0 comments · Fixed by #135
Closed

An extra whitespace indentation for the Apache License template #134

XuehaiPan opened this issue Nov 22, 2022 · 0 comments · Fixed by #135

Comments

@XuehaiPan
Copy link
Contributor

XuehaiPan commented Nov 22, 2022

The Apache License template indents the URL with 5 spaces:

addlicense/tmpl.go

Lines 104 to 111 in 53d978a

const tmplApache = `Copyright{{ if .Year }} {{.Year}}{{ end }} {{.Holder}}
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
http://www.apache.org/licenses/LICENSE-2.0

where the letter h is under a:

You may obtain a copy of the License at
     |
     http://www.apache.org/licenses/LICENSE-2.0

The generated license also indent with 5 spaces:

addlicense/tmpl.go

Lines 1 to 8 in 53d978a

// Copyright 2018 Google LLC
//
// 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
//
// http://www.apache.org/licenses/LICENSE-2.0
//

In the Apache official license template: https://www.apache.org/licenses/LICENSE-2.0#apply

Copyright [yyyy] [name of copyright owner]

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

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

The URL is indented by 4 spaces and the letter h is under m.

You can also find the LICENSE file is indent by 4 spaces (h under m):

addlicense/LICENSE

Lines 190 to 197 in 53d978a

Copyright [yyyy] [name of copyright owner]
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
http://www.apache.org/licenses/LICENSE-2.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant