diff --git a/.gitignore b/.gitignore index 49a06933..0fefab93 100644 --- a/.gitignore +++ b/.gitignore @@ -12,4 +12,4 @@ DerivedData/ .docc-build /openapi -/tmp +/.tmp diff --git a/.swiftlint.yml b/.swiftlint.yml index e6850696..35d61816 100644 --- a/.swiftlint.yml +++ b/.swiftlint.yml @@ -64,7 +64,10 @@ function_parameter_count: 7 implicit_return: included: - closure +included: + - Package.swift + - Sources + - Tests + - macOS/XToolMac excluded: - - .build - - macOS/Build - Sources/DeveloperAPI/Generated diff --git a/.vscode/.gitignore b/.vscode/.gitignore new file mode 100644 index 00000000..0ae318ed --- /dev/null +++ b/.vscode/.gitignore @@ -0,0 +1 @@ +/launch.json diff --git a/.vscode/extensions.json b/.vscode/extensions.json new file mode 100644 index 00000000..e13d027f --- /dev/null +++ b/.vscode/extensions.json @@ -0,0 +1,6 @@ +{ + "recommendations": [ + "swiftlang.swift-vscode", + "vknabel.vscode-swiftlint", + ] +} diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 00000000..7d368574 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,3 @@ +{ + "swiftlint.path": "./.tmp/swiftlint/swiftlint", +} diff --git a/Makefile b/Makefile index edd2f9f8..565ebbfc 100644 --- a/Makefile +++ b/Makefile @@ -127,7 +127,7 @@ docs-preview: ./Documentation/build.sh preview SWIFTLINT_VERSION = $(shell head -1 .swiftlint.yml | cut -d' ' -f2) -SWIFTLINT_BIN = tmp/swiftlint/swiftlint-$(SWIFTLINT_VERSION) +SWIFTLINT_BIN = .tmp/swiftlint/swiftlint-$(SWIFTLINT_VERSION) SWIFTLINT_URL = https://github.com/realm/SwiftLint/releases/download/$(SWIFTLINT_VERSION)/$(if $(IS_MAC),portable_swiftlint,swiftlint_linux).zip .PHONY: lint @@ -135,12 +135,13 @@ lint: $(SWIFTLINT_BIN) $(SWIFTLINT_BIN) $(SWIFTLINT_FLAGS) $(SWIFTLINT_BIN): - @rm -rf tmp/swiftlint - @mkdir -p tmp/swiftlint - curl -fSL $(SWIFTLINT_URL) -o tmp/swiftlint/swiftlint.zip - unzip -q tmp/swiftlint/swiftlint.zip swiftlint -d tmp/swiftlint - @rm -f tmp/swiftlint/swiftlint.zip - @mv tmp/swiftlint/swiftlint $@ + @rm -rf .tmp/swiftlint + @mkdir -p .tmp/swiftlint + curl -fSL $(SWIFTLINT_URL) -o .tmp/swiftlint/swiftlint.zip + unzip -q .tmp/swiftlint/swiftlint.zip swiftlint -d .tmp/swiftlint + @rm -f .tmp/swiftlint/swiftlint.zip + @mv .tmp/swiftlint/swiftlint $@ + @ln -s swiftlint-$(SWIFTLINT_VERSION) .tmp/swiftlint/swiftlint SPEC_URL = https://developer.apple.com/sample-code/app-store-connect/app-store-connect-openapi-specification.zip