syncthing/lib/osutil
Jakob Borg a3c724f2c3
all: Add build constants for runtime.GOOS comparisons (#8442)
all: Add package runtimeos for runtime.GOOS comparisons

I grew tired of hand written string comparisons. This adds generated
constants for the GOOS values, and predefined Is$OS constants that can
be iffed on. In a couple of places I rewrote trivial switch:es to if:s,
and added Illumos where we checked for Solaris (because they are
effectively the same, and if we're going to target one of them that
would be Illumos...).
2022-07-28 19:36:39 +02:00
..
atomic_test.go all: use T.TempDir to create temporary test directory (#8280) 2022-04-15 07:44:06 +04:00
atomic_unix_test.go all: Remove usage of deprecated io/ioutil (#7971) 2021-11-22 08:59:47 +01:00
atomic.go all: Add build constants for runtime.GOOS comparisons (#8442) 2022-07-28 19:36:39 +02:00
filenames_darwin.go all: Update license url to https (ref #3976) 2017-02-09 08:04:16 +01:00
filenames_unix.go all: Update build constraints to Go 1.17 style (#7894) 2021-08-17 10:10:41 +02:00
filenames_windows.go all: Update license url to https (ref #3976) 2017-02-09 08:04:16 +01:00
hidden_unix.go all: Update build constraints to Go 1.17 style (#7894) 2021-08-17 10:10:41 +02:00
hidden_windows.go all: Update build constraints to Go 1.17 style (#7894) 2021-08-17 10:10:41 +02:00
lan.go lib/osutil: Only announce address of interfaces which are up (fixes #7458) (#8422) 2022-07-07 19:19:29 +02:00
lowprio_linux.go all: Update build constraints to Go 1.17 style (#7894) 2021-08-17 10:10:41 +02:00
lowprio_unix.go all: Update build constraints to Go 1.17 style (#7894) 2021-08-17 10:10:41 +02:00
lowprio_windows.go lib/osutil: Use x/sys/windows for SetLowPriority 2021-11-27 15:35:07 +01:00
osutil_test.go all: Add build constants for runtime.GOOS comparisons (#8442) 2022-07-28 19:36:39 +02:00
osutil.go all: Add build constants for runtime.GOOS comparisons (#8442) 2022-07-28 19:36:39 +02:00
ping.go lib/dialer: Preserve nilness in error handling (fixes #6368) (#6369) 2020-02-26 13:16:18 +01:00
replacingwriter_test.go all: Update license url to https (ref #3976) 2017-02-09 08:04:16 +01:00
replacingwriter.go all: Add build constants for runtime.GOOS comparisons (#8442) 2022-07-28 19:36:39 +02:00
rlimit_unix.go all: Add build constants for runtime.GOOS comparisons (#8442) 2022-07-28 19:36:39 +02:00
rlimit_windows.go all: Update build constraints to Go 1.17 style (#7894) 2021-08-17 10:10:41 +02:00
tempfile.go all: Convert folders to use filesystem abstraction 2017-08-19 14:36:56 +00:00
traversessymlink_test.go all: Add build constants for runtime.GOOS comparisons (#8442) 2022-07-28 19:36:39 +02:00
traversessymlink.go lib: Prevent using protocol method with native path (fixes #7557) (#7563) 2021-04-11 15:29:43 +02:00