Skip to content

Commit

Permalink
Merge branch 'master' into proper-in-tests
Browse files Browse the repository at this point in the history
  • Loading branch information
antvaset authored Nov 6, 2024
2 parents afe9392 + 6af4b68 commit ce6c8a2
Show file tree
Hide file tree
Showing 145 changed files with 2,876 additions and 2,246 deletions.
11 changes: 10 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,23 @@ jobs:
with:
distribution: 'temurin'
java-version: '21'
cache: gradle
- name: Cache SonarCloud packages
uses: actions/cache@v4
with:
path: ~/.sonar/cache
key: ${{ runner.os }}-sonar
restore-keys: ${{ runner.os }}-sonar
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
- name: Run Gradle Build
working-directory: ./Src/java
run: ./gradlew check publish
run: ./gradlew check publish sonar
env:
OSSRH_USERNAME: ${{ vars.OSSRH_USERNAME }}
OSSRH_TOKEN: ${{ secrets.OSSRH_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
- name: Publish Test Report
uses: mikepenz/action-junit-report@v4
if: success() || failure() # always run even if the previous step fails
Expand Down
11 changes: 10 additions & 1 deletion .github/workflows/check-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,20 @@ jobs:
distribution: 'temurin'
java-version: '21'
cache: gradle
- name: Cache SonarCloud packages
uses: actions/cache@v4
with:
path: ~/.sonar/cache
key: ${{ runner.os }}-sonar
restore-keys: ${{ runner.os }}-sonar
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
- name: Run Gradle Build
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
working-directory: ./Src/java
run: ./gradlew check -x spotlessCheck
run: ./gradlew check sonar -x spotlessCheck
- name: Publish Test Report
uses: mikepenz/action-junit-report@v4
if: (success() || failure()) && matrix.os == 'ubuntu-latest'
Expand Down
2 changes: 1 addition & 1 deletion Src/grammar/cql.g4
Original file line number Diff line number Diff line change
Expand Up @@ -320,14 +320,14 @@ expression
| expression 'properly'? 'between' expressionTerm 'and' expressionTerm #betweenExpression
| ('duration' 'in')? pluralDateTimePrecision 'between' expressionTerm 'and' expressionTerm #durationBetweenExpression
| 'difference' 'in' pluralDateTimePrecision 'between' expressionTerm 'and' expressionTerm #differenceBetweenExpression
| expression ('|' | 'union' | 'intersect' | 'except') expression #inFixSetExpression
| expression ('<=' | '<' | '>' | '>=') expression #inequalityExpression
| expression intervalOperatorPhrase expression #timingExpression
| expression ('=' | '!=' | '~' | '!~') expression #equalityExpression
| expression ('in' | 'contains') dateTimePrecisionSpecifier? expression #membershipExpression
| expression 'and' expression #andExpression
| expression ('or' | 'xor') expression #orExpression
| expression 'implies' expression #impliesExpression
| expression ('|' | 'union' | 'intersect' | 'except') expression #inFixSetExpression
;

dateTimePrecision
Expand Down
12 changes: 0 additions & 12 deletions Src/java-quickstart/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,18 +20,6 @@ To clean up the artifacts:

./gradlew clean

# Generating IDE Projects

You can generate an IDE project for IntelliJ IDEA:

./gradlew idea

This is preferred over having IDEA load the gradle file directly, because it (a) generates the CQL
libraries, and (b) generates the configuration for the IDEA ANTLR plugin. To open the project in
IntelliJ IDEA, launch IDEA and open the `java-quickstart.ipr` file.

See further below for installing and using the ANTLR plugin for IDEA.

# Executing the Sample Code

You can execute the sample code using the `gradlew` command or a script generated by gradle.
Expand Down
4 changes: 4 additions & 0 deletions Src/java/.sonarlint/connectedMode.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"sonarCloudOrganization": "cqframework",
"projectKey": "cqframework_clinical_quality_language"
}
6 changes: 5 additions & 1 deletion Src/java/.vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -79,5 +79,9 @@
".git",
"**/*.gradle",
"**/test/resources/**"
]
],
"sonarlint.connectedMode.project": {
"connectionId": "cqframework",
"projectKey": "cqframework_clinical_quality_language"
}
}
9 changes: 0 additions & 9 deletions Src/java/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,6 @@ To clean up the build artifacts:

./gradlew clean

# Generating IDE Projects

You can generate an IDE project for IntelliJ IDEa:

./gradlew idea

In addition to creating project modules for cql, model, quick, elm, cql-to-elm, and the tools projects, this will also import project
modules for the CQL grammar and examples.

# Executing the Sample Code

You can execute the sample code using the `gradlew` command or a script generated by gradle.
Expand Down
46 changes: 0 additions & 46 deletions Src/java/build.gradle

This file was deleted.

24 changes: 24 additions & 0 deletions Src/java/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
plugins {
kotlin("jvm") version "2.0.20"
id("org.sonarqube") version "4.4.1.3373"
}

sonar {
properties {
property("sonar.projectKey", "cqframework_clinical_quality_language")
property("sonar.organization", "cqframework")
property("sonar.host.url", "https://sonarcloud.io")
}
}

repositories {
mavenCentral()
}

dependencies {
implementation("org.jetbrains.kotlin:kotlin-stdlib-jdk8")
}

kotlin {
jvmToolchain(11)
}
15 changes: 0 additions & 15 deletions Src/java/buildSrc/build.gradle

This file was deleted.

19 changes: 19 additions & 0 deletions Src/java/buildSrc/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
plugins {
`kotlin-dsl`
}

repositories {
mavenCentral()
gradlePluginPortal()
}

dependencies {
implementation("net.ltgt.gradle:gradle-errorprone-plugin:3.1.0")
implementation("ru.vyarus:gradle-animalsniffer-plugin:1.7.0")
implementation("com.github.spotbugs.snom:spotbugs-gradle-plugin:5.0.14")
implementation("com.diffplug.spotless:spotless-plugin-gradle:6.23.3")
}

kotlin {
jvmToolchain(11)
}
31 changes: 0 additions & 31 deletions Src/java/buildSrc/src/main/groovy/cql.fhir-conventions.gradle

This file was deleted.

Loading

0 comments on commit ce6c8a2

Please sign in to comment.