initial cleanup and JSON definitions #32
  
    
      This file contains hidden or 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
    
  
  
    
  | # yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json | |
| --- | |
| name: Clojure SDK | |
| on: | |
| push: | |
| branches: develop | |
| paths: | |
| - sdk/clojure/** | |
| - .github/workflows/clojure-sdk.yml | |
| pull_request: | |
| paths: | |
| - sdk/clojure/** | |
| - .github/workflows/clojure-sdk.yml | |
| workflow_dispatch: | |
| inputs: | |
| publish: | |
| description: "Publish artifacts to Clojars" | |
| required: true | |
| type: boolean | |
| default: false | |
| jobs: | |
| build-clojure: | |
| runs-on: ubuntu-24.04 | |
| defaults: | |
| run: | |
| working-directory: ./sdk/clojure | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # tag: v4.22 | |
| - name: Setup java 21 as default java | |
| run: | | |
| echo "JAVA_HOME=$JAVA_HOME_21_X64" >> $GITHUB_ENV | |
| echo "$JAVA_HOME_21_X64/bin" >> $GITHUB_PATH | |
| shell: bash | |
| - name: Install clojure + tools | |
| uses: DeLaGuardo/setup-clojure@ada62bb3282a01a296659d48378b812b8e097360 # tag 13.2 | |
| with: | |
| cli: latest | |
| bb: latest | |
| - name: Cache clojure dependencies | |
| uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # tag: v4.2.3 | |
| with: | |
| path: | | |
| ~/.m2/repository | |
| ~/.gitlibs | |
| ~/.deps.clj | |
| key: cljdeps-${{ hashFiles('**/deps.edn') }} | |
| restore-keys: cljdeps- | |
| - name: Run test suite | |
| run: bb test:all | |
| - name: Build jar artifacts | |
| run: bb jar:all | |
| - uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # tag: v4.6.2 | |
| with: | |
| name: sdk.jar | |
| path: sdk/clojure/sdk/target/*.jar | |
| if-no-files-found: error | |
| compression-level: 0 | |
| - uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # tag: v4.6.2 | |
| with: | |
| name: adapter-http-kit.jar | |
| path: sdk/clojure/adapter-http-kit/target/*.jar | |
| if-no-files-found: error | |
| compression-level: 0 | |
| - uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # tag: v4.6.2 | |
| with: | |
| name: adapter-ring.jar | |
| path: sdk/clojure/adapter-ring/target/*.jar | |
| if-no-files-found: error | |
| compression-level: 0 | |
| - name: Publish artifacts to clojars | |
| if: github.event_name == 'workflow_dispatch' && github.event.inputs.publish == 'true' | |
| run: bb publish:all |