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

Update template #141

Open
wants to merge 118 commits into
base: 2.3.x
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
118 commits
Select commit Hold shift + click to select a range
996ce99
Use SECRET_GIST instead of GITHUB_PERSONAL_ACCESS_TOKEN
Atry Jun 5, 2019
d95f4b8
Update .travis.yml
Atry Jun 5, 2019
3b875bf
Update plugins.sbt
Atry Jun 11, 2019
9e30edb
Merge commit '3b875bff5977a95269326d92cdee7c5a8c147e9d' into template
Atry Jun 12, 2019
9c3a0d3
Upgrade sbt-dynver
Atry Jun 20, 2019
8442fd7
Merge branch 'upstream-template' into template
Atry Jun 20, 2019
3aebc15
Merge branch 'upstream-template' into template
Atry Jun 23, 2019
fa2d834
Upgrade sbt
Atry Sep 5, 2019
75bfab0
Use publish / skip
Atry Sep 5, 2019
e537cb4
Merge commit 'fdc190cb16b03e4a4a617965cc5ba97a461907fa' into template
Atry Sep 6, 2019
880b43f
Update sbt-sonatype to 3.6
scala-steward Sep 6, 2019
5300633
Merge branch 'upstream-template' into template
Atry Sep 9, 2019
cb8bc64
Merge pull request #1 from ThoughtWorksInc/template
Atry Sep 11, 2019
073623c
Upgrade sbt-sonatype
Atry Oct 4, 2019
94df716
Update build.properties
Atry Oct 4, 2019
819d9f0
Merge branch 'template' of github.com:ThoughtWorksInc/scala-project-t…
Atry Oct 4, 2019
d80070d
Create .gitpod.yml
Atry Nov 22, 2019
98e0ca3
Merge pull request #2 from ThoughtWorksInc/template
Atry Nov 22, 2019
bd2c2aa
Ignore Metals files
Atry Nov 22, 2019
9b2c0b0
Merge pull request #3 from ThoughtWorksInc/template
Atry Nov 22, 2019
7d7fcc8
Switch to a docker image that supports Node.js
Atry Nov 22, 2019
f6b6738
Merge commit '9b2c0b0f86c0548c5756404a14f1e3e8e1eede17' into template
Atry Nov 22, 2019
ad26ea5
Update .scalafmt.conf
Atry Nov 24, 2019
50a8a9c
Merge pull request #4 from ThoughtWorksInc/template
Atry Nov 24, 2019
4490421
Upgrade metals
Atry Nov 24, 2019
eadea3d
Merge pull request #5 from ThoughtWorksInc/template
Atry Nov 24, 2019
c682fef
Update sbt-example
Atry Dec 3, 2019
b420caf
Merge pull request #6 from ThoughtWorksInc/template
Atry Dec 3, 2019
50a2486
Ignore more Metals files
Atry Apr 19, 2020
5c3d919
Merge pull request #7 from ThoughtWorksInc/template
Atry Apr 19, 2020
f863c3a
Update JDK version
Atry Apr 19, 2020
48a409a
Merge pull request #8 from ThoughtWorksInc/template
Atry Apr 19, 2020
9b1fde0
Clear cache according to https://www.scala-sbt.org/1.x/docs/Travis-CI…
Atry Apr 25, 2020
b8bc077
Merge pull request #9 from ThoughtWorksInc/template
Atry Apr 25, 2020
680293c
Migrate deprecated Travis CI settings
Atry Apr 25, 2020
9fcb079
Merge pull request #10 from ThoughtWorksInc/template
Atry Apr 25, 2020
03cedbf
Update cache directory according to https://www.scala-sbt.org/1.x/doc…
Atry Apr 25, 2020
1edd706
Merge pull request #11 from ThoughtWorksInc/template
Atry Apr 25, 2020
b947e2d
Switch to dpl v2
Atry Apr 25, 2020
0fd971f
Merge pull request #12 from ThoughtWorksInc/template
Atry Apr 25, 2020
6447059
Update Metals
Atry May 29, 2020
e35ecd9
Merge pull request #23 from Atry/update-metals
Atry May 29, 2020
f109a82
Merge pull request #13 from Atry/update-metals
Atry May 29, 2020
ccbecaa
Also ignore project/project/metals.sbt
Atry Nov 2, 2021
24038c5
Add .vscode/
Atry Nov 2, 2021
bd7a8d7
Set up Github Actions
Atry Nov 2, 2021
c77da29
Upgrade sbt-best-practice
Atry Nov 2, 2021
4536453
Remove Travis CI configuration
Atry Nov 2, 2021
5d87b7d
Upgrade sbt to 1.5.5
Atry Nov 2, 2021
aea68e9
Ignore .bsp/sbt.json
Atry Nov 3, 2021
9b74ae3
Merge commit 'aea68e93d24296195ffccc3b81dba80734f1320f' into template
Atry Nov 3, 2021
68d0576
Don't fail fast
Atry Nov 6, 2021
5e3c91e
Add a random number into sonatypeSessionName
Atry Nov 12, 2021
b8e8c87
Cache ~/.ivy/local for Github Actions
Atry Nov 13, 2021
b4969d0
Add runner.dialect and update scalafmt version
Atry Nov 17, 2021
a29a0e3
Update sbt-best-practice to 8.2.1
Atry Dec 6, 2021
9f9cf58
Set maxColumn to 80
Atry Dec 7, 2021
a353ce6
Update .gitignore
Atry Dec 8, 2021
078e700
Merge branch 'template' into template
Atry Dec 16, 2021
74ed2d7
Update Scala to 2.12.15
Atry Dec 27, 2021
e28acdb
Ignore *.scala.semanticdb
Atry Feb 6, 2022
1002275
Update .gitignore
Atry Mar 17, 2022
5ece74c
Use Temurin JDK
Atry Mar 19, 2022
d93376a
Update sbt to 1.7.3
Atry Jan 9, 2023
e4b2a1a
Update sbt-best-practice to 8.2.4
Atry Jan 9, 2023
0bb0dcd
Set default Scalafmt dialect to scala212source3
Atry Jan 9, 2023
9a891e1
Update GitHub Action versions
Atry Jan 9, 2023
6f76452
Merge branch 'ThoughtWorksInc:template' into template
Atry Jan 9, 2023
0647cdd
Create scala-steward.yml
Atry Jan 10, 2023
e27f684
Let scala-steward update the current branch
Atry Jan 10, 2023
cb5b02b
Update scalafmt-core to 3.1.2 in template
github-actions[bot] Jan 10, 2023
fb6cfb8
Reformat with scalafmt 3.1.2
github-actions[bot] Jan 10, 2023
32568fb
Add 'Reformat with scalafmt 3.1.2' to .git-blame-ignore-revs
github-actions[bot] Jan 10, 2023
d5b311a
Merge pull request #28 from ThoughtWorksInc/update/template/scalafmt-…
Atry Jan 10, 2023
a76dee3
Update scalafmt-core to 3.6.1 in template (#30)
Atry Jan 10, 2023
94992e0
Update sbt-sonatype to 3.9.15 in template (#29)
github-actions[bot] Jan 10, 2023
01e962f
Update sbt to 1.8.2 in template (#27)
github-actions[bot] Jan 10, 2023
b1c6eed
Update sbt-example to 7.0.1 in template (#26)
github-actions[bot] Jan 10, 2023
ac53026
Update sbt-pgp to 1.1.2-1 in template (#25)
github-actions[bot] Jan 10, 2023
75fd5ee
Update sbt-dynver to 4.1.1 in template (#24)
github-actions[bot] Jan 10, 2023
5240d42
Update sbt-example to 9.2.1 in template (#32)
Atry Jan 10, 2023
ec457ef
Update sbt-pgp to 2.1.1 in template (#31)
Atry Jan 10, 2023
7846934
Update sbt-pgp to 2.1.2 in template (#33)
Atry Jan 10, 2023
b531301
Update sbt-pgp to 2.2.1 in template (#34)
Atry Jan 10, 2023
8bd4b57
Update scala-steward.yml
Atry Jan 10, 2023
2d4d899
Update scala.yml
Atry Jan 10, 2023
b78f28d
Update scala.yml
Atry Jan 10, 2023
26b2258
Merge branch 'template' of github.com:ThoughtWorksInc/scala-project-t…
Atry Jan 11, 2023
5b86d12
ci(scala-steward): Allow for workflow_dispatch event
Atry Jan 26, 2023
d7474b5
Merge branch 'ThoughtWorksInc:template' into template
Atry Jan 26, 2023
f217fc9
Update sbt-best-practice to 8.2.5 in template (#35)
github-actions[bot] Jan 26, 2023
14fb063
Update scalafmt-core to 3.7.1 in template (#36)
github-actions[bot] Jan 26, 2023
c065799
Merge branch 'ThoughtWorksInc:template' into template
Atry Jan 26, 2023
d80d76a
scala.yml should be triggered when pushing a release tag
Atry Jan 27, 2023
8b1f0fd
Merge branch 'ThoughtWorksInc:template' into template
Atry Jan 27, 2023
43ef7e9
Update sbt-sonatype to 3.9.16 in template (#37)
github-actions[bot] Jan 27, 2023
9668383
Merge branch 'ThoughtWorksInc:template' into template
Atry Jan 27, 2023
2525e59
Pass ${{matrix.sbt-args}} to sbt commands
Atry Jan 27, 2023
1cb728c
Merge branch 'ThoughtWorksInc:template' into template
Atry Jan 27, 2023
a2bcfde
Add matrix.sbt-args to sbt cache keys
Atry Jan 27, 2023
805e013
Merge branch 'ThoughtWorksInc:template' into template
Atry Jan 27, 2023
a5f7afa
Format YAML files
Atry Jan 27, 2023
855d12b
Merge branch 'ThoughtWorksInc:template' into template
Atry Jan 27, 2023
5aba73d
Update sbt-sonatype to 3.9.17 in template (#39)
github-actions[bot] Jan 30, 2023
d72c5e9
Merge branch 'ThoughtWorksInc:template' into template
Atry Jan 30, 2023
fc08ba2
Update and rename plugins.sbt to sbt-best-practice.sbt
Atry Feb 14, 2023
0ff30d8
Update scalafmt-core to 3.7.1 in template (#16)
github-actions[bot] Jul 1, 2023
9ec37b4
Merge branch 'template' of https://github.com/thoughtworksinc/scala-p…
Atry Jul 1, 2023
dc8b239
Merge branch 'template' of github.com:Atry/scala-project-template int…
Atry Jul 1, 2023
421e174
Update scalafmt-core to 3.7.5 in template (#22)
github-actions[bot] Jul 1, 2023
4614ec7
Update sbt to 1.8.3 in template (#21)
github-actions[bot] Jul 1, 2023
08fb755
Add GitHub Action to pull scala-project-template
Atry Jul 1, 2023
fa38523
Update sbt to 1.9.1 in template (#24)
github-actions[bot] Jul 1, 2023
744999e
Update scala-project-template.yml
Atry Jul 1, 2023
418b18d
Update scala-project-template.yml
Atry Jul 1, 2023
c31f513
Update scala-project-template.yml
Atry Jul 1, 2023
885406c
Delete .gitpod.yml
Atry Jul 1, 2023
a335404
Update scala-project-template.yml
Atry Jul 1, 2023
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
2 changes: 2 additions & 0 deletions .git-blame-ignore-revs
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Scala Steward: Reformat with scalafmt 3.1.2
fb6cfb8aea15a1b339e3ed69e1e96acd7df4cae6
31 changes: 31 additions & 0 deletions .github/workflows/scala-project-template.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
on:
push:
branches-ignore:
- "update/**"
schedule:
- cron: "0 0 * * 0"
workflow_dispatch:

name: Update Scala project template

jobs:
update-scala-project-template:
permissions:
# for aws-actions/configure-aws-credentials to assume an AWS role
id-token: write
# for peter-evans/create-pull-request to create branch
contents: write
# for peter-evans/create-pull-request to create a PR
pull-requests: write
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- run: git fetch https://github.com/Atry/scala-project-template.git template
- run: git reset --hard FETCH_HEAD
- uses: peter-evans/create-pull-request@v5
with:
delete-branch: true
base: ${{github.ref_name}}
branch: update/${{github.ref_name}}/scala-project-template
title: Update scala-project-template
token: ${{ secrets.PERSONAL_ACCESS_TOKEN || github.token }}
20 changes: 20 additions & 0 deletions .github/workflows/scala-steward.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
on:
push:
branches-ignore:
- "update/**"
schedule:
- cron: "0 0 * * 0"
workflow_dispatch:

name: Launch Scala Steward

jobs:
scala-steward:
runs-on: ubuntu-22.04
name: Launch Scala Steward
steps:
- name: Launch Scala Steward
uses: scala-steward-org/scala-steward-action@v2
with:
github-token: ${{ secrets.PERSONAL_ACCESS_TOKEN || github.token }}
branches: ${{ github.ref_name }}
48 changes: 48 additions & 0 deletions .github/workflows/scala.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: Scala CI

on:
push:
branches-ignore:
- "update/**"
tags:
- "v*"
pull_request:

jobs:
build:
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
scala:
- 2.12.15

steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0 # Need the git history for sbt-dynver to determine the version
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: "11"
distribution: temurin
- name: Cache SBT
uses: actions/cache@v3
with:
path: |
~/.ivy2/local/
~/.ivy2/cache/
~/.sbt/
~/.coursier/
key: |
${{runner.os}}-${{matrix.scala}}-${{hashFiles('**/*.sbt')}}-${{matrix.sbt-args}}
${{runner.os}}-${{matrix.scala}}-${{hashFiles('**/*.sbt')}}-
${{runner.os}}-${{matrix.scala}}-
- name: Run tests
run: sbt ${{matrix.sbt-args}} ++${{ matrix.scala }} test
- name: Publish to Maven Central Repository
env:
GITHUB_PERSONAL_ACCESS_TOKEN: ${{secrets.PERSONAL_ACCESS_TOKEN}}
if: ${{ env.GITHUB_PERSONAL_ACCESS_TOKEN != '' && github.event_name != 'pull_request' }}
run: sbt ${{matrix.sbt-args}} ++${{ matrix.scala }} "set every Seq(sonatypeSessionName := \"${{github.workflow}} ${{github.run_id}}-${{github.run_number}}-${{github.run_attempt}}-$$ ${{ matrix.scala }}\", publishTo := sonatypePublishToBundle.value)" publishSigned sonatypeBundleRelease
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
target/
local.sbt
secret/
.metals/
.bloop/
metals.sbt
.bsp/
.vscode/launch.json
*.scala.semanticdb
5 changes: 3 additions & 2 deletions .scalafmt.conf
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
version = "1.5.1"
maxColumn = 120
runner.dialect = scala212source3
version = "3.7.5"
maxColumn = 80
36 changes: 0 additions & 36 deletions .travis.yml

This file was deleted.

5 changes: 5 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"files.watcherExclude": {
"**/target": true
}
}
2 changes: 1 addition & 1 deletion project/build.properties
Original file line number Diff line number Diff line change
@@ -1 +1 @@
sbt.version=1.3.2
sbt.version=1.9.1
11 changes: 0 additions & 11 deletions project/plugins.sbt

This file was deleted.

3 changes: 3 additions & 0 deletions project/sbt-best-practice.sbt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
addSbtPlugin(
"com.thoughtworks.sbt-best-practice" % "sbt-best-practice" % "8.3.0"
)
9 changes: 7 additions & 2 deletions secret.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,15 @@ lazy val secret = {
IO.delete(secretDirectory)
org.eclipse.jgit.api.Git
.cloneRepository()
.setURI("https://github.com/ThoughtWorksInc/tw-data-china-continuous-delivery-password.git")
.setURI(
"https://github.com/Atry/secrets.git"
)
.setDirectory(secretDirectory)
.setCredentialsProvider(
new org.eclipse.jgit.transport.UsernamePasswordCredentialsProvider(token, "")
new org.eclipse.jgit.transport.UsernamePasswordCredentialsProvider(
token,
""
)
)
.call()
.close()
Expand Down