فهرست منبع

add a copyright notice with original author

Signed-off-by: Nicolas De Loof <[email protected]>
Nicolas De Loof 2 سال پیش
والد
کامیت
0d905a896d

+ 4 - 0
internal/locker/runtime_darwin.go

@@ -21,6 +21,10 @@ import (
 	"path/filepath"
 )
 
+// Based on https://github.com/adrg/xdg
+// Licensed under MIT License (MIT)
+// Copyright (c) 2014 Adrian-George Bostan <[email protected]>
+
 func osDependentRunDir() (string, error) {
 	home, err := os.UserHomeDir()
 	if err != nil {

+ 5 - 1
internal/locker/runtime_unix.go

@@ -24,10 +24,14 @@ import (
 	"strconv"
 )
 
+// Based on https://github.com/adrg/xdg
+// Licensed under MIT License (MIT)
+// Copyright (c) 2014 Adrian-George Bostan <[email protected]>
+
 func osDependentRunDir() (string, error) {
 	run := filepath.Join("run", "user", strconv.Itoa(os.Getuid()))
 	if _, err := os.Stat(run); err == nil {
-		return run
+		return run, nil
 	}
 
 	// /run/user/$uid is set by pam_systemd, but might not be present, especially in containerized environments

+ 4 - 0
internal/locker/runtime_windows.go

@@ -23,6 +23,10 @@ import (
 	"golang.org/x/sys/windows"
 )
 
+// Based on https://github.com/adrg/xdg
+// Licensed under MIT License (MIT)
+// Copyright (c) 2014 Adrian-George Bostan <[email protected]>
+
 func osDependentRunDir() (string, error) {
 	flags := []uint32{windows.KF_FLAG_DEFAULT, windows.KF_FLAG_DEFAULT_PATH}
 	for _, flag := range flags {

+ 4 - 0
pkg/remote/cache_darwin.go

@@ -21,6 +21,10 @@ import (
 	"path/filepath"
 )
 
+// Based on https://github.com/adrg/xdg
+// Licensed under MIT License (MIT)
+// Copyright (c) 2014 Adrian-George Bostan <[email protected]>
+
 func osDependentCacheDir() (string, error) {
 	home, err := os.UserHomeDir()
 	if err != nil {

+ 4 - 0
pkg/remote/cache_unix.go

@@ -23,6 +23,10 @@ import (
 	"path/filepath"
 )
 
+// Based on https://github.com/adrg/xdg
+// Licensed under MIT License (MIT)
+// Copyright (c) 2014 Adrian-George Bostan <[email protected]>
+
 func osDependentCacheDir() (string, error) {
 	home, err := os.UserHomeDir()
 	if err != nil {

+ 4 - 0
pkg/remote/cache_windows.go

@@ -23,6 +23,10 @@ import (
 	"golang.org/x/sys/windows"
 )
 
+// Based on https://github.com/adrg/xdg
+// Licensed under MIT License (MIT)
+// Copyright (c) 2014 Adrian-George Bostan <[email protected]>
+
 func osDependentCacheDir() (string, error) {
 	flags := []uint32{windows.KF_FLAG_DEFAULT, windows.KF_FLAG_DEFAULT_PATH}
 	for _, flag := range flags {