-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #533 from permutive-engineering/feature/fs2-pubsub
Revamp library as new `fs2-pubsub`
- Loading branch information
Showing
96 changed files
with
3,989 additions
and
5,212 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Validating CODEOWNERS rules …
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* @permutive-engineering/developer-experience |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Don't edit this file! | ||
# It is automatically updated after every release of https://github.com/alejandrohdezma/sbt-ci | ||
# If you want to suggest a change, please open a PR or issue in that repository | ||
|
||
# This file contains the template for the "auto-generated release notes" | ||
|
||
changelog: | ||
exclude: | ||
labels: | ||
- ":chart_with_upwards_trend: dependency-update" | ||
authors: | ||
- dependabot | ||
categories: | ||
- title: "⚠️ Breaking changes" | ||
labels: | ||
- ":warning: breaking" | ||
- title: "🚀 New features" | ||
labels: | ||
- ":rocket: feature" | ||
- title: "📘 Documentation updates" | ||
labels: | ||
- ":blue_book: documentation" | ||
- title: "🐛 Bug fixes" | ||
labels: | ||
- ":beetle: bug" | ||
- title: Other Changes | ||
labels: | ||
- "*" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,168 +1,74 @@ | ||
# This file was automatically generated by sbt-github-actions using the | ||
# githubWorkflowGenerate task. You should add and commit this file to | ||
# your git repository. It goes without saying that you shouldn't edit | ||
# this file by hand! Instead, if you wish to make changes, you should | ||
# change your sbt build configuration to revise the workflow description | ||
# to meet your needs, then regenerate this file. | ||
|
||
name: Continuous Integration | ||
# Don't edit this file! | ||
# It is automatically updated after every release of https://github.com/alejandrohdezma/sbt-ci | ||
# If you want to suggest a change, please open a PR or issue in that repository | ||
|
||
# Runs `sbt ci-test` on the project on differnt JDKs (this task should be added to the project as a command alias | ||
# containing the necessary steps to compile, check formatters, launch tests...). | ||
# | ||
# Examples of this `ci-test` alias can be found [here](https://github.com/search?q=org%3Aalejandrohdezma+%22ci-test%22+path%3Abuild.sbt++NOT+is%3Aarchived&type=code). | ||
# | ||
# It will also do the following: | ||
# | ||
# - It will automatically label PRs based on head branch. | ||
# - It will automatically enable auto-merge on `Scala Steward` PRs. You'll need to add a `STEWARD_BOT` repository or | ||
# organization variable with the name of your scala-steward bot. See https://docs.github.com/en/actions/learn-github-actions/variables. | ||
|
||
name: CI | ||
|
||
on: | ||
pull_request: | ||
branches: ['**', '!update/**', '!pr/**'] | ||
push: | ||
branches: ['**', '!update/**', '!pr/**'] | ||
tags: [v*] | ||
|
||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
|
||
concurrency: | ||
group: ${{ github.workflow }} @ ${{ github.ref }} | ||
cancel-in-progress: true | ||
types: [opened, reopened, labeled, unlabeled, synchronize] | ||
|
||
jobs: | ||
build: | ||
name: Build and Test | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest] | ||
scala: [2.13, 2.12, 3] | ||
java: [temurin@11] | ||
project: [rootJVM] | ||
runs-on: ${{ matrix.os }} | ||
timeout-minutes: 60 | ||
labeler: | ||
if: github.event.pull_request.state == 'OPEN' && github.actor != 'dependabot[bot]' | ||
name: Labeler | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout current branch (full) | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Setup Java (temurin@11) | ||
id: setup-java-temurin-11 | ||
if: matrix.java == 'temurin@11' | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: temurin | ||
java-version: 11 | ||
cache: sbt | ||
|
||
- name: sbt update | ||
if: matrix.java == 'temurin@11' && steps.setup-java-temurin-11.outputs.cache-hit == 'false' | ||
run: sbt +update | ||
|
||
- name: Check that workflows are up to date | ||
run: sbt githubWorkflowCheck | ||
|
||
- name: Check headers and formatting | ||
if: matrix.java == 'temurin@11' && matrix.os == 'ubuntu-latest' | ||
run: sbt 'project ${{ matrix.project }}' '++ ${{ matrix.scala }}' headerCheckAll scalafmtCheckAll 'project /' scalafmtSbtCheck | ||
|
||
- name: Test | ||
run: sbt 'project ${{ matrix.project }}' '++ ${{ matrix.scala }}' test | ||
|
||
- name: Check binary compatibility | ||
if: matrix.java == 'temurin@11' && matrix.os == 'ubuntu-latest' | ||
run: sbt 'project ${{ matrix.project }}' '++ ${{ matrix.scala }}' mimaReportBinaryIssues | ||
|
||
- name: Generate API documentation | ||
if: matrix.java == 'temurin@11' && matrix.os == 'ubuntu-latest' | ||
run: sbt 'project ${{ matrix.project }}' '++ ${{ matrix.scala }}' doc | ||
|
||
- name: Make target directories | ||
if: github.event_name != 'pull_request' && (startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/main') | ||
run: mkdir -p fs2-google-pubsub-grpc/target fs2-google-pubsub/target fs2-google-pubsub-http/target project/target | ||
|
||
- name: Compress target directories | ||
if: github.event_name != 'pull_request' && (startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/main') | ||
run: tar cf targets.tar fs2-google-pubsub-grpc/target fs2-google-pubsub/target fs2-google-pubsub-http/target project/target | ||
|
||
- name: Upload target directories | ||
if: github.event_name != 'pull_request' && (startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/main') | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: target-${{ matrix.os }}-${{ matrix.java }}-${{ matrix.scala }}-${{ matrix.project }} | ||
path: targets.tar | ||
|
||
publish: | ||
name: Publish Artifacts | ||
needs: [build] | ||
if: github.event_name != 'pull_request' && (startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/main') | ||
- name: Update PR labels | ||
uses: alejandrohdezma/actions/labeler@v1 | ||
if: github.event.pull_request.head.repo.full_name == github.repository | ||
|
||
- name: Check PR labels | ||
uses: alejandrohdezma/actions/label-check@v1 | ||
|
||
ci-steward: | ||
if: | | ||
github.event.pull_request.state == 'OPEN' && github.event.pull_request.head.repo.full_name == github.repository && | ||
github.event.pull_request.user.login == vars.STEWARD_BOT | ||
name: (Scala Steward) Enable auto-merge | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Enable auto-merge for this PR | ||
run: gh pr merge --auto --merge ${{github.event.pull_request.number}} -R "$GITHUB_REPOSITORY" | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
test: | ||
needs: [ci-steward] | ||
if: | | ||
always() && !contains(needs.*.result, 'failure') && github.event.pull_request.state == 'OPEN' && | ||
github.actor != 'dependabot[bot]' | ||
name: Run "sbt ci-test" on JDK ${{ matrix.jdk }} | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ubuntu-latest] | ||
java: [temurin@11] | ||
runs-on: ${{ matrix.os }} | ||
jdk: | ||
- 11 | ||
- 17 | ||
steps: | ||
- name: Checkout current branch (full) | ||
uses: actions/checkout@v4 | ||
- name: Checkout project | ||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 | ||
with: | ||
ref: ${{ github.head_ref }} | ||
fetch-depth: 0 | ||
|
||
- name: Setup Java (temurin@11) | ||
id: setup-java-temurin-11 | ||
if: matrix.java == 'temurin@11' | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: temurin | ||
java-version: 11 | ||
cache: sbt | ||
|
||
- name: sbt update | ||
if: matrix.java == 'temurin@11' && steps.setup-java-temurin-11.outputs.cache-hit == 'false' | ||
run: sbt +update | ||
|
||
- name: Download target directories (2.13, rootJVM) | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: target-${{ matrix.os }}-${{ matrix.java }}-2.13-rootJVM | ||
|
||
- name: Inflate target directories (2.13, rootJVM) | ||
run: | | ||
tar xf targets.tar | ||
rm targets.tar | ||
- name: Download target directories (2.12, rootJVM) | ||
uses: actions/download-artifact@v4 | ||
- uses: actions/setup-java@387ac29b308b003ca37ba93a6cab5eb57c8f5f93 # v4.0.0 | ||
with: | ||
name: target-${{ matrix.os }}-${{ matrix.java }}-2.12-rootJVM | ||
distribution: "liberica" | ||
java-version: ${{ matrix.jdk }} | ||
cache: "sbt" | ||
|
||
- name: Inflate target directories (2.12, rootJVM) | ||
run: | | ||
tar xf targets.tar | ||
rm targets.tar | ||
- name: Download target directories (3, rootJVM) | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: target-${{ matrix.os }}-${{ matrix.java }}-3-rootJVM | ||
|
||
- name: Inflate target directories (3, rootJVM) | ||
run: | | ||
tar xf targets.tar | ||
rm targets.tar | ||
- name: Import signing key | ||
if: env.PGP_SECRET != '' && env.PGP_PASSPHRASE == '' | ||
env: | ||
PGP_SECRET: ${{ secrets.PGP_SECRET }} | ||
PGP_PASSPHRASE: ${{ secrets.PGP_PASSPHRASE }} | ||
run: echo $PGP_SECRET | base64 -d -i - | gpg --import | ||
|
||
- name: Import signing key and strip passphrase | ||
if: env.PGP_SECRET != '' && env.PGP_PASSPHRASE != '' | ||
env: | ||
PGP_SECRET: ${{ secrets.PGP_SECRET }} | ||
PGP_PASSPHRASE: ${{ secrets.PGP_PASSPHRASE }} | ||
run: | | ||
echo "$PGP_SECRET" | base64 -d -i - > /tmp/signing-key.gpg | ||
echo "$PGP_PASSPHRASE" | gpg --pinentry-mode loopback --passphrase-fd 0 --import /tmp/signing-key.gpg | ||
(echo "$PGP_PASSPHRASE"; echo; echo) | gpg --command-fd 0 --pinentry-mode loopback --change-passphrase $(gpg --list-secret-keys --with-colons 2> /dev/null | grep '^sec:' | cut --delimiter ':' --fields 5 | tail -n 1) | ||
- name: Publish | ||
env: | ||
SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }} | ||
SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }} | ||
SONATYPE_CREDENTIAL_HOST: ${{ secrets.SONATYPE_CREDENTIAL_HOST }} | ||
run: sbt tlCiRelease | ||
- name: Run `sbt ci-test` | ||
run: sbt ci-test |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.