-
Notifications
You must be signed in to change notification settings - Fork 819
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: migrate build scripts to Gradle
- Loading branch information
Showing
35 changed files
with
1,265 additions
and
704 deletions.
There are no files selected for viewing
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,11 +1,46 @@ | ||
root = true | ||
|
||
[*] | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
charset = utf-8 | ||
indent_style = space | ||
|
||
[{*.sh,gradlew}] | ||
end_of_line = lf | ||
|
||
[{*.bat,*.cmd}] | ||
end_of_line = crlf | ||
|
||
[{*.kts,*.kt}] | ||
ij_kotlin_code_style_defaults = KOTLIN_OFFICIAL | ||
ij_kotlin_name_count_to_use_star_import = 99 | ||
ij_kotlin_name_count_to_use_star_import_for_members = 99 | ||
ij_java_use_single_class_imports = true | ||
max_line_length = 100 | ||
ij_any_wrap_long_lines = true | ||
|
||
[*.java] | ||
indent_style = space | ||
# Doc: https://youtrack.jetbrains.com/issue/IDEA-170643#focus=streamItem-27-3708697.0-0 | ||
# $ means "static" | ||
ij_java_imports_layout = $*,|,org.postgresql.**,|,*,|,java | ||
indent_size = 2 | ||
charset = utf-8 | ||
end_of_line = lf | ||
trim_trailing_whitespace = true | ||
tab_width = 2 | ||
max_line_length = 100 | ||
ij_any_spaces_around_additive_operators = true | ||
ij_any_spaces_around_assignment_operators = true | ||
ij_any_spaces_around_bitwise_operators = true | ||
ij_any_spaces_around_equality_operators = true | ||
ij_any_spaces_around_lambda_arrow = true | ||
ij_any_spaces_around_logical_operators = true | ||
ij_any_spaces_around_multiplicative_operators = true | ||
ij_any_spaces_around_relational_operators = true | ||
ij_any_spaces_around_shift_operators = true | ||
ij_continuation_indent_size = 4 | ||
ij_java_if_brace_force = always | ||
ij_java_indent_case_from_switch = false | ||
ij_java_space_after_colon = true | ||
ij_java_space_before_colon = true | ||
ij_java_ternary_operation_signs_on_next_line = true | ||
ij_java_use_single_class_imports = true | ||
ij_java_wrap_long_lines = true |
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,10 @@ | ||
#!/bin/bash | ||
set -e | ||
|
||
whoami | ||
|
||
psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" <<-EOSQL | ||
CREATE USER test; | ||
CREATE DATABASE test OWNER test; | ||
CREATE USER root; | ||
EOSQL |
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,58 @@ | ||
name: CI | ||
|
||
on: | ||
push: | ||
branches: | ||
- '*' | ||
pull_request: | ||
branches: | ||
- '*' | ||
|
||
# https://help.github.com/en/actions/automating-your-workflow-with-github-actions/software-installed-on-github-hosted-runners | ||
# GitHub Actions does not support Docker, PostgreSQL server on Windows, macOS :( | ||
|
||
jobs: | ||
ubuntu-latest: | ||
name: 'Ubuntu, PG latest (JDK 8)' | ||
runs-on: ubuntu-latest | ||
services: | ||
postgres: | ||
image: postgres:latest | ||
env: | ||
POSTGRES_USER: postgres | ||
# Empty password | ||
# POSTGRES_PASSWORD: postgres | ||
POSTGRES_DB: postgres | ||
ports: | ||
- 5432:5432 | ||
# needed because the postgres container does not provide a healthcheck | ||
options: >- | ||
--name db | ||
--health-cmd pg_isready | ||
--health-interval 10s | ||
--health-timeout 5s | ||
--health-retries 5 | ||
steps: | ||
- name: Setup Users | ||
uses: docker://docker | ||
with: | ||
args: docker exec -t db psql -U postgres -c "set password_encryption='scram-sha-256'; create user test with password 'test';" | ||
- name: Create DB | ||
uses: docker://docker | ||
with: | ||
args: docker exec -t db psql -U postgres -c "create database test owner test;" | ||
- uses: actions/checkout@master | ||
with: | ||
fetch-depth: 50 | ||
- name: 'Set up JDK 8' | ||
uses: actions/setup-java@v1 | ||
with: | ||
java-version: 8 | ||
# - name: 'Setup DB' | ||
# run: | | ||
# psql -U postgres -c "set password_encryption='scram-sha-256'; create user test with password 'test';" | ||
# psql -U postgres -c 'create database test owner test;' | ||
# psql -U postgres test -c 'CREATE EXTENSION hstore;' | ||
- name: 'Test' | ||
run: | | ||
./gradlew --no-parallel --no-daemon -PskipReplicationTests test javadoc -Pport=${{ job.services.postgres.ports['5432'] }} |
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
Empty file.
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
Oops, something went wrong.