Skip to content

Commit 5fce1e3

Browse files
authored
Merge pull request #3 from teogor/env/github
Add GitHub Workflows and Pull Request Templates
2 parents d6c7299 + 7bc2321 commit 5fce1e3

File tree

3 files changed

+80
-0
lines changed

3 files changed

+80
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
---
2+
name: Pull request
3+
about: Create a pull request
4+
label: 'triage me'
5+
---
6+
Thank you for opening a Pull Request!
7+
Before submitting your PR, there are a few things you can do to make sure it goes smoothly:
8+
9+
- [ ] Make sure to open a GitHub issue as a bug/feature request before writing your code! That way
10+
we can discuss the change, evaluate designs, and agree on the general idea
11+
- [ ] Ensure the tests and linter
12+
pass (`./gradlew --init-script gradle/init.gradle.kts spotlessApply` to automatically apply
13+
formatting)
14+
- [ ] Appropriate docs were updated (if necessary)
15+
16+
Fixes #<issue_number_goes_here> 🦕

.github/ci-gradle.properties

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
#
2+
# Copyright 2020 The Android Open Source Project
3+
#
4+
# Licensed under the Apache License, Version 2.0 (the "License");
5+
# you may not use this file except in compliance with the License.
6+
# You may obtain a copy of the License at
7+
#
8+
# http://www.apache.org/licenses/LICENSE-2.0
9+
#
10+
# Unless required by applicable law or agreed to in writing, software
11+
# distributed under the License is distributed on an "AS IS" BASIS,
12+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
# See the License for the specific language governing permissions and
14+
# limitations under the License.
15+
#
16+
17+
org.gradle.daemon=false
18+
org.gradle.parallel=true
19+
org.gradle.workers.max=2
20+
21+
kotlin.incremental=false
22+
kotlin.compiler.execution.strategy=in-process
23+
24+
# Controls KotlinOptions.allWarningsAsErrors.
25+
# This value used in CI and is currently set to false.
26+
# If you want to treat warnings as errors locally, set this property to true
27+
# in your ~/.gradle/gradle.properties file.
28+
warningsAsErrors=false

.github/workflows/publish.yml

+36
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Publish to Maven
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
publish:
8+
name: Snapshot build and publish
9+
runs-on: ubuntu-latest
10+
environment: PRODUCTION
11+
timeout-minutes: 120
12+
env:
13+
ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.OSSRH_USERNAME }}
14+
ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.OSSRH_PASSWORD }}
15+
ORG_GRADLE_PROJECT_signingInMemoryKeyId: ${{ secrets.SIGNING_KEY_ID }}
16+
ORG_GRADLE_PROJECT_signingInMemoryKeyPassword: ${{ secrets.SIGNING_PASSWORD }}
17+
ORG_GRADLE_PROJECT_signingInMemoryKey: ${{ secrets.SIGNING_KEY }}
18+
SONATYPE_CONNECT_TIMEOUT_SECONDS: 120
19+
SONATYPE_CLOSE_TIMEOUT_SECONDS: 1800
20+
21+
steps:
22+
- name: Check out code
23+
uses: actions/[email protected]
24+
25+
- name: Set up JDK 17
26+
uses: actions/[email protected]
27+
with:
28+
distribution: 'zulu'
29+
java-version: 17
30+
31+
- name: Grant Permission to Execute Gradle
32+
run: chmod +x gradlew
33+
34+
- name: Publish to MavenCentral
35+
run: |
36+
./gradlew publish --no-configuration-cache

0 commit comments

Comments
 (0)