From e27da1d6a235519feaae783de0980771a660c175 Mon Sep 17 00:00:00 2001 From: Emil Marashliev Date: Tue, 2 Jun 2020 14:03:27 +0200 Subject: [PATCH] Remove CircleCI and add GitHub Actions instead --- .circleci/config.yml | 67 ----------------------------- .github/workflows/documentation.yml | 23 ++++++++++ .github/workflows/test.yml | 18 ++++++++ 3 files changed, 41 insertions(+), 67 deletions(-) delete mode 100644 .circleci/config.yml create mode 100644 .github/workflows/documentation.yml create mode 100644 .github/workflows/test.yml diff --git a/.circleci/config.yml b/.circleci/config.yml deleted file mode 100644 index db8669b..0000000 --- a/.circleci/config.yml +++ /dev/null @@ -1,67 +0,0 @@ -version: 2 -jobs: - MacOS: - macos: - xcode: "9.3.0" - steps: - - checkout - - restore_cache: - keys: - - v3-spm-deps-{{ checksum "Package.swift" }} - - run: - name: Install CMySQL and CTLS - command: | - export HOMEBREW_NO_AUTO_UPDATE=1 - brew tap vapor/homebrew-tap - brew install cmysql - brew install ctls - brew install libressl - - run: - name: Build and Run Tests - no_output_timeout: 1800 - command: | - swift package generate-xcodeproj --enable-code-coverage - xcodebuild -scheme Submissions-Package -enableCodeCoverage YES test | xcpretty - - run: - name: Report coverage to Codecov - command: | - bash <(curl -s https://codecov.io/bash) - - save_cache: - key: v1-spm-deps-{{ checksum "Package.swift" }} - paths: - - .build - Linux: - docker: - - image: nodesvapor/vapor-ci:swift-4.1 - steps: - - checkout - - restore_cache: - keys: - - v4-spm-deps-{{ checksum "Package.swift" }} - - run: - name: Copy Package file - command: cp Package.swift res - - run: - name: Build and Run Tests - no_output_timeout: 1800 - command: | - swift test -Xswiftc -DNOJSON - - run: - name: Restoring Package file - command: mv res Package.swift - - save_cache: - key: v2-spm-deps-{{ checksum "Package.swift" }} - paths: - - .build -workflows: - version: 2 - build-and-test: - jobs: - - MacOS - - Linux -experimental: - notify: - branches: - only: - - master - - develop \ No newline at end of file diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml new file mode 100644 index 0000000..4d93220 --- /dev/null +++ b/.github/workflows/documentation.yml @@ -0,0 +1,23 @@ +# .github/workflows/documentation.yml +name: Documentation + +on: [release] + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v1 + - name: Generate Documentation + uses: SwiftDocOrg/swift-doc@master + with: + inputs: "Sources/Submissions" + module-name: Submissions + output: "Documentation" + - name: Upload Documentation to Wiki + uses: SwiftDocOrg/github-wiki-publish-action@v1 + with: + path: "Documentation" + env: + GH_PERSONAL_ACCESS_TOKEN: ${{ secrets.WIKI_ACCESS_TOKEN }} \ No newline at end of file diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..ed64b39 --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,18 @@ +name: test +on: +- pull_request +jobs: + vapor_macos: + runs-on: macos-latest + env: + DEVELOPER_DIR: /Applications/Xcode_11.4.1.app/Contents/Developer + steps: + - uses: actions/checkout@v2 + - run: xcrun swift test --enable-test-discovery --sanitize=thread + vapor_bionic: + container: + image: vapor/swift:5.2-bionic + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - run: swift test --enable-test-discovery --sanitize=thread \ No newline at end of file