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

chore(license): update source code headers + copyright year #53

Merged
merged 1 commit into from
Oct 11, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,5 @@ Please see our [support](SUPPORT.md) documentation for further instructions.
## Copyright and License

```
Copyright (c) 2022 Target Brands, Inc.
Copyright 2022 Target Brands, Inc.
```
4 changes: 1 addition & 3 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,7 @@ linters-settings:
# https://github.com/denis-tingaikin/go-header
goheader:
template: |-
Copyright (c) {{ YEAR }} Target Brands, Inc. All rights reserved.

Use of this source code is governed by the LICENSE file in this repository.
SPDX-License-Identifier: Apache-2.0

# https://github.com/client9/misspell
misspell:
Expand Down
4 changes: 1 addition & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
# Copyright (c) 2022 Target Brands, Inc. All rights reserved.
#
# Use of this source code is governed by the LICENSE file in this repository.
# SPDX-License-Identifier: Apache-2.0

###########################################################################
## docker build --no-cache -t vela-npm:local . ##
Expand Down
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.

Copyright (c) 2022 Target Brands, Inc.
Copyright 2022 Target Brands, Inc.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down
4 changes: 1 addition & 3 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
# Copyright (c) 2022 Target Brands, Inc. All rights reserved.
#
# Use of this source code is governed by the LICENSE file in this repository.
# SPDX-License-Identifier: Apache-2.0

# capture the current date we build the application from
BUILD_DATE = $(shell date +%Y-%m-%dT%H:%M:%SZ)
Expand Down
6 changes: 2 additions & 4 deletions cmd/vela-npm/main.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
// Copyright (c) 2022 Target Brands, Inc. All rights reserved.
//
// Use of this source code is governed by the LICENSE file in this repository.
// SPDX-License-Identifier: Apache-2.0

package main

Expand Down Expand Up @@ -34,7 +32,7 @@
Usage: "Vela npm plugin for publishing NodeJS packages",
Version: v.Semantic(),
HelpName: "vela-npm",
Copyright: "Copyright (c) 2022 Target Brands, Inc. All rights reserved.",
Copyright: "Copyright 2022 Target Brands, Inc. All rights reserved.",
Authors: []*cli.Author{
{
Name: "Vela Admins",
Expand Down Expand Up @@ -248,7 +246,7 @@
}

// run the plugin
if err := p.Exec(); err != nil {

Check failure on line 249 in cmd/vela-npm/main.go

View workflow job for this annotation

GitHub Actions / diff-review

if-return: redundant if ...; err != nil check, just return error instead. (revive)

Check failure on line 249 in cmd/vela-npm/main.go

View workflow job for this annotation

GitHub Actions / full-review

if-return: redundant if ...; err != nil check, just return error instead. (revive)

Check failure on line 249 in cmd/vela-npm/main.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] cmd/vela-npm/main.go#L249

if-return: redundant if ...; err != nil check, just return error instead. (revive)
Raw output
cmd/vela-npm/main.go:249:2: if-return: redundant if ...; err != nil check, just return error instead. (revive)
	if err := p.Exec(); err != nil {
		return err
	}
return err
}

Expand Down
4 changes: 1 addition & 3 deletions internal/npm/config.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
// Copyright (c) 2022 Target Brands, Inc. All rights reserved.
//
// Use of this source code is governed by the LICENSE file in this repository.
// SPDX-License-Identifier: Apache-2.0

package npm

Expand Down
4 changes: 1 addition & 3 deletions internal/npm/config_test.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
// Copyright (c) 2022 Target Brands, Inc. All rights reserved.
//
// Use of this source code is governed by the LICENSE file in this repository.
// SPDX-License-Identifier: Apache-2.0
package npm

import "testing"
Expand Down
4 changes: 1 addition & 3 deletions internal/npm/package.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
// Copyright (c) 2022 Target Brands, Inc. All rights reserved.
//
// Use of this source code is governed by the LICENSE file in this repository.
// SPDX-License-Identifier: Apache-2.0
package npm

import (
Expand Down
4 changes: 1 addition & 3 deletions internal/npm/package_test.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
// Copyright (c) 2022 Target Brands, Inc. All rights reserved.
//
// Use of this source code is governed by the LICENSE file in this repository.
// SPDX-License-Identifier: Apache-2.0
package npm

import (
Expand Down
4 changes: 1 addition & 3 deletions internal/npm/plugin.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
// Copyright (c) 2022 Target Brands, Inc. All rights reserved.
//
// Use of this source code is governed by the LICENSE file in this repository.
// SPDX-License-Identifier: Apache-2.0
package npm

import (
Expand Down Expand Up @@ -62,7 +60,7 @@
return errors.New("no shell handler provided")
}

if err := p.config.Validate(); err != nil {

Check failure on line 63 in internal/npm/plugin.go

View workflow job for this annotation

GitHub Actions / diff-review

if-return: redundant if ...; err != nil check, just return error instead. (revive)

Check failure on line 63 in internal/npm/plugin.go

View workflow job for this annotation

GitHub Actions / full-review

if-return: redundant if ...; err != nil check, just return error instead. (revive)

Check failure on line 63 in internal/npm/plugin.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] internal/npm/plugin.go#L63

if-return: redundant if ...; err != nil check, just return error instead. (revive)
Raw output
internal/npm/plugin.go:63:2: if-return: redundant if ...; err != nil check, just return error instead. (revive)
	if err := p.config.Validate(); err != nil {
		return err
	}
return err
}

Expand Down Expand Up @@ -127,7 +125,7 @@
return err
}

if err := p.publish(); err != nil {

Check failure on line 128 in internal/npm/plugin.go

View workflow job for this annotation

GitHub Actions / diff-review

if-return: redundant if ...; err != nil check, just return error instead. (revive)

Check failure on line 128 in internal/npm/plugin.go

View workflow job for this annotation

GitHub Actions / full-review

if-return: redundant if ...; err != nil check, just return error instead. (revive)

Check failure on line 128 in internal/npm/plugin.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] internal/npm/plugin.go#L128

if-return: redundant if ...; err != nil check, just return error instead. (revive)
Raw output
internal/npm/plugin.go:128:2: if-return: redundant if ...; err != nil check, just return error instead. (revive)
	if err := p.publish(); err != nil {
		return err
	}
return err
}

Expand Down
4 changes: 1 addition & 3 deletions internal/npm/plugin_test.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
// Copyright (c) 2022 Target Brands, Inc. All rights reserved.
//
// Use of this source code is governed by the LICENSE file in this repository.
// SPDX-License-Identifier: Apache-2.0
package npm

import (
Expand Down Expand Up @@ -111,7 +109,7 @@
}
p, mock, fs := createTestPlugin(t, c)
home := path.Join("usr", "mctestface")
fs.MkdirAll(home, 0755) // nolint: errcheck // testing

Check failure on line 112 in internal/npm/plugin_test.go

View workflow job for this annotation

GitHub Actions / diff-review

directive `// nolint: errcheck // testing` should be written without leading space as `//nolint: errcheck // testing` (nolintlint)

Check failure on line 112 in internal/npm/plugin_test.go

View workflow job for this annotation

GitHub Actions / full-review

directive `// nolint: errcheck // testing` should be written without leading space as `//nolint: errcheck // testing` (nolintlint)

Check failure on line 112 in internal/npm/plugin_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] internal/npm/plugin_test.go#L112

directive `// nolint: errcheck // testing` should be written without leading space as `//nolint: errcheck // testing` (nolintlint)
Raw output
internal/npm/plugin_test.go:112:26: directive `// nolint: errcheck // testing` should be written without leading space as `//nolint: errcheck // testing` (nolintlint)
	fs.MkdirAll(home, 0755) // nolint: errcheck // testing
	                        ^
mock.
EXPECT().
GetHomeDir().
Expand Down Expand Up @@ -143,7 +141,7 @@
}
p, mock, fs := createTestPlugin(t, c)
home := path.Join("usr", "mctestface")
fs.MkdirAll(home, 0755) // nolint: errcheck // testing

Check failure on line 144 in internal/npm/plugin_test.go

View workflow job for this annotation

GitHub Actions / diff-review

directive `// nolint: errcheck // testing` should be written without leading space as `//nolint: errcheck // testing` (nolintlint)

Check failure on line 144 in internal/npm/plugin_test.go

View workflow job for this annotation

GitHub Actions / full-review

directive `// nolint: errcheck // testing` should be written without leading space as `//nolint: errcheck // testing` (nolintlint)

Check failure on line 144 in internal/npm/plugin_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] internal/npm/plugin_test.go#L144

directive `// nolint: errcheck // testing` should be written without leading space as `//nolint: errcheck // testing` (nolintlint)
Raw output
internal/npm/plugin_test.go:144:26: directive `// nolint: errcheck // testing` should be written without leading space as `//nolint: errcheck // testing` (nolintlint)
	fs.MkdirAll(home, 0755) // nolint: errcheck // testing
	                        ^
mock.
EXPECT().
GetHomeDir().
Expand Down Expand Up @@ -176,7 +174,7 @@
}
p, mock, fs := createTestPlugin(t, c)
home := path.Join("usr", "mctestface")
fs.MkdirAll(home, 0755) // nolint: errcheck // testing

Check failure on line 177 in internal/npm/plugin_test.go

View workflow job for this annotation

GitHub Actions / diff-review

directive `// nolint: errcheck // testing` should be written without leading space as `//nolint: errcheck // testing` (nolintlint)

Check failure on line 177 in internal/npm/plugin_test.go

View workflow job for this annotation

GitHub Actions / full-review

directive `// nolint: errcheck // testing` should be written without leading space as `//nolint: errcheck // testing` (nolintlint)

Check failure on line 177 in internal/npm/plugin_test.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] internal/npm/plugin_test.go#L177

directive `// nolint: errcheck // testing` should be written without leading space as `//nolint: errcheck // testing` (nolintlint)
Raw output
internal/npm/plugin_test.go:177:26: directive `// nolint: errcheck // testing` should be written without leading space as `//nolint: errcheck // testing` (nolintlint)
	fs.MkdirAll(home, 0755) // nolint: errcheck // testing
	                        ^
mock.
EXPECT().
GetHomeDir().
Expand Down
4 changes: 1 addition & 3 deletions internal/shell/os_context.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
// Copyright (c) 2022 Target Brands, Inc. All rights reserved.
//
// Use of this source code is governed by the LICENSE file in this repository.
// SPDX-License-Identifier: Apache-2.0

package shell

Expand Down
4 changes: 1 addition & 3 deletions test/os_context_mock.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 1 addition & 3 deletions version/version.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
// Copyright (c) 2022 Target Brands, Inc. All rights reserved.
//
// Use of this source code is governed by the LICENSE file in this repository.
// SPDX-License-Identifier: Apache-2.0

package version

Expand Down