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

Kotlin 1.8 and Anvil 2.4.4 support #568

Closed
wants to merge 18 commits into from
Closed
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
27 changes: 27 additions & 0 deletions .git-branches.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# More info around this file at https://www.git-town.com/configuration-file

[branches]
main = "main"
perennials = []
perennial-regex = ""

[create]
new-branch-type = ""
push-new-branches = false

[hosting]
dev-remote = "origin"
platform = "github"
# origin-hostname = ""

[ship]
delete-tracking-branch = true
strategy = "api"

[sync]
feature-strategy = "rebase"
perennial-strategy = "rebase"
prototype-strategy = "rebase"
push-hook = true
tags = true
upstream = true
256 changes: 113 additions & 143 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@ name: CI
on:
pull_request:
workflow_dispatch:
schedule:
# * is a special character in YAML so you have to quote this string
# every day at 10pm CST (4 UTC)
- cron: '0 4 * * *'

env:
macosGradleArgs: '-Dorg.gradle.jvmargs=-Xmx10g -Dfile.encoding=UTF-8 -XX:+UseParallelGC'
Expand Down Expand Up @@ -77,157 +73,131 @@ jobs:
if: github.actor != 'renovate[bot]'

steps:
- name: check out with token (used by forks)
- name: check out with token
uses: actions/checkout@v3
if: github.event.pull_request.head.repo.full_name != github.repository

- name: check out with PAT (used by main repo)
uses: actions/checkout@v3
if: github.event.pull_request.head.repo.full_name == github.repository
with:
ref: ${{ github.event.pull_request.head.ref }}
token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
fetch-depth: 0

- name: Set up JDK
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: '11'

- name: KtLint format (used by main repo)
if: github.event.pull_request.head.repo.full_name == github.repository
uses: gradle/gradle-build-action@v2
with:
arguments: ktlintformat
cache-read-only: false

# If KtLint generated changes, commit and push those changes.
- name: commit changes (used by main repo)
if: github.event.pull_request.head.repo.full_name == github.repository
uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: Apply KtLint format
commit_options: '--no-verify --signoff'

- name: KtLint check (used by forks)
- name: KtLint check
if: github.event.pull_request.head.repo.full_name != github.repository
uses: gradle/gradle-build-action@v2
with:
arguments: ktlintCheck
cache-read-only: false

versioning:

runs-on: ubuntu-latest
if: github.actor != 'renovate[bot]'

steps:
- name: check out with token (used by forks)
uses: actions/checkout@v3
if: github.event.pull_request.head.repo.full_name != github.repository

- name: check out with PAT (used by main repo)
uses: actions/checkout@v3
if: github.event.pull_request.head.repo.full_name == github.repository
with:
ref: ${{ github.event.pull_request.head.ref }}
token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
fetch-depth: 0

- name: Set up JDK
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: '11'

- name: Check that the version is a -SNAPSHOT version
uses: gradle/gradle-build-action@v2
with:
arguments: checkVersionIsSnapshot
cache-read-only: false

- name: Sync versions in website docs (used by main repo)
if: github.event.pull_request.head.repo.full_name == github.repository
uses: gradle/gradle-build-action@v2
with:
arguments: updateWebsiteNextDocsVersionRefs
cache-read-only: false

- name: Check versions in website docs (used by forks)
if: github.event.pull_request.head.repo.full_name != github.repository
uses: gradle/gradle-build-action@v2
with:
arguments: checkWebsiteNextDocsVersionRefs
cache-read-only: false

- name: commit changes
uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: update docs versions
commit_options: '--no-verify --signoff'

- name: Update version in website package.json (used by main repo)
if: github.event.pull_request.head.repo.full_name == github.repository
uses: gradle/gradle-build-action@v2
with:
arguments: updateWebsitePackageJsonVersion
cache-read-only: false

- name: Check version in website package.json (used by forks)
if: github.event.pull_request.head.repo.full_name != github.repository
uses: gradle/gradle-build-action@v2
with:
arguments: checkWebsitePackageJsonVersion
cache-read-only: false

- name: commit changes (used by main repo)
if: github.event.pull_request.head.repo.full_name == github.repository
uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: update website versions
commit_options: '--no-verify --signoff'

website:
name: build website
runs-on: ubuntu-latest
steps:

- name: Check out repo
uses: actions/checkout@v3

# Node is required for npm
- name: Set up Node
uses: actions/setup-node@v3
with:
node-version: 18.x
cache: yarn
cache-dependency-path: website/yarn.lock

- name: Install Yarn
working-directory: website
run: |
yarn install --frozen-lockfile

- uses: gradle/wrapper-validation-action@v1

- name: Set up JDK
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: '11'

- name: build website
uses: gradle/gradle-build-action@v2
with:
arguments: buildSite
cache-read-only: false

- name: knit check
uses: gradle/gradle-build-action@v2
with:
arguments: knitcheck
cache-read-only: false
# versioning:
#
# runs-on: ubuntu-latest
# if: github.actor != 'renovate[bot]'
#
# steps:
# - name: check out with token (used by forks)
# uses: actions/checkout@v3
# if: github.event.pull_request.head.repo.full_name != github.repository
#
# - name: check out with PAT (used by main repo)
# uses: actions/checkout@v3
# if: github.event.pull_request.head.repo.full_name == github.repository
# with:
# ref: ${{ github.event.pull_request.head.ref }}
# token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
# fetch-depth: 0
#
# - name: Set up JDK
# uses: actions/setup-java@v3
# with:
# distribution: 'zulu'
# java-version: '11'
#
# - name: Check that the version is a -SNAPSHOT version
# uses: gradle/gradle-build-action@v2
# with:
# arguments: checkVersionIsSnapshot
# cache-read-only: false
#
# - name: Sync versions in website docs (used by main repo)
# if: github.event.pull_request.head.repo.full_name == github.repository
# uses: gradle/gradle-build-action@v2
# with:
# arguments: updateWebsiteNextDocsVersionRefs
# cache-read-only: false
#
# - name: Check versions in website docs (used by forks)
# if: github.event.pull_request.head.repo.full_name != github.repository
# uses: gradle/gradle-build-action@v2
# with:
# arguments: checkWebsiteNextDocsVersionRefs
# cache-read-only: false
#
# - name: commit changes
# uses: stefanzweifel/git-auto-commit-action@v4
# with:
# commit_message: update docs versions
# commit_options: '--no-verify --signoff'
#
# - name: Update version in website package.json (used by main repo)
# if: github.event.pull_request.head.repo.full_name == github.repository
# uses: gradle/gradle-build-action@v2
# with:
# arguments: updateWebsitePackageJsonVersion
# cache-read-only: false
#
# - name: Check version in website package.json (used by forks)
# if: github.event.pull_request.head.repo.full_name != github.repository
# uses: gradle/gradle-build-action@v2
# with:
# arguments: checkWebsitePackageJsonVersion
# cache-read-only: false
#
# - name: commit changes (used by main repo)
# if: github.event.pull_request.head.repo.full_name == github.repository
# uses: stefanzweifel/git-auto-commit-action@v4
# with:
# commit_message: update website versions
# commit_options: '--no-verify --signoff'

# website:
# name: build website
# runs-on: ubuntu-latest
# steps:
#
# - name: Check out repo
# uses: actions/checkout@v3
#
# # Node is required for npm
# - name: Set up Node
# uses: actions/setup-node@v3
# with:
# node-version: 18.x
# cache: yarn
# cache-dependency-path: website/yarn.lock
#
# - name: Install Yarn
# working-directory: website
# run: |
# yarn install --frozen-lockfile
#
# - uses: gradle/wrapper-validation-action@v1
#
# - name: Set up JDK
# uses: actions/setup-java@v3
# with:
# distribution: 'zulu'
# java-version: '11'
#
# - name: build website
# uses: gradle/gradle-build-action@v2
# with:
# arguments: buildSite
# cache-read-only: false
#
# - name: knit check
# uses: gradle/gradle-build-action@v2
# with:
# arguments: knitcheck
# cache-read-only: false

api-check:

Expand Down
54 changes: 27 additions & 27 deletions .github/workflows/publish-snapshot.yml
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
name: Publish snapshot

on:
workflow_dispatch:
push:
branches:
- main

jobs:
publish-snapshot :
runs-on : ubuntu-latest
if : github.repository == 'RBusarow/Tangle'
timeout-minutes : 25

steps :
- uses : actions/checkout@v2
- uses : actions/setup-java@v2
with :
distribution : 'adopt'
java-version : '11'
check-latest : true

- name : Publish Snapshots
run : ./gradlew clean publish --no-build-cache --no-daemon --stacktrace --no-parallel
env :
ORG_GRADLE_PROJECT_mavenCentralUsername : ${{ secrets.SONATYPE_NEXUS_USERNAME }}
ORG_GRADLE_PROJECT_mavenCentralPassword : ${{ secrets.SONATYPE_NEXUS_PASSWORD }}
#name: Publish snapshot
#
#on:
# workflow_dispatch:
# push:
# branches:
# - main
#
#jobs:
# publish-snapshot :
# runs-on : ubuntu-latest
# if : github.repository == 'RBusarow/Tangle'
# timeout-minutes : 25
#
# steps :
# - uses : actions/checkout@v2
# - uses : actions/setup-java@v2
# with :
# distribution : 'adopt'
# java-version : '11'
# check-latest : true
#
# - name : Publish Snapshots
# run : ./gradlew clean publish --no-build-cache --no-daemon --stacktrace --no-parallel
# env :
# ORG_GRADLE_PROJECT_mavenCentralUsername : ${{ secrets.SONATYPE_NEXUS_USERNAME }}
# ORG_GRADLE_PROJECT_mavenCentralPassword : ${{ secrets.SONATYPE_NEXUS_PASSWORD }}
Loading