Skip to content

Commit

Permalink
Adjust GitHub workflows (#1562)
Browse files Browse the repository at this point in the history
  • Loading branch information
plux authored Oct 9, 2024
1 parent f8a6ee1 commit ed1daaa
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 16 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,12 +80,16 @@ jobs:
# apps/els_lsp/doc
# overwrite: true
windows:
runs-on: windows-latest
strategy:
matrix:
platform: [windows-latest]
otp-version: [26.2.5.3]
runs-on: ${{ matrix.platform }}
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install Erlang
run: choco install -y erlang --version 26.2.5
run: choco install -y erlang --version ${{ matrix.otp-version }}
- name: Install rebar3
run: choco install -y rebar3 --version 3.23.0
- name: Compile
Expand Down
32 changes: 18 additions & 14 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ jobs:
# overwrite: true

# Make release artifacts : erlang_ls
- name: Make erlang_ls-linux.tar.gz
- name: Make erlang_ls-linux-${{ matrix.otp-version }}.tar.gz
run: 'tar -zcvf erlang_ls-linux-${{ matrix.otp-version }}.tar.gz -C _build/default/bin/ erlang_ls'
- env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
Expand All @@ -93,20 +93,24 @@ jobs:
uses: "bruceadams/[email protected]"
- env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
name: Upload release erlang_ls.-linux.tar.gz
name: Upload release erlang_ls-linux-${{ matrix.otp-version }}.tar.gz
uses: "actions/[email protected]"
with:
asset_content_type: application/octet-stream
asset_name: "erlang_ls-linux-${{ matrix.otp-version }}.tar.gz"
asset_path: "erlang_ls-linux-${{ matrix.otp-version }}.tar.gz"
upload_url: "${{ steps.get_release_url.outputs.upload_url }}"
windows:
runs-on: windows-latest
strategy:
matrix:
platform: [windows-latest]
otp-version: [26.2.5.3]
runs-on: ${{ matrix.platform }}
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install Erlang
run: choco install -y erlang --version 26.2.5
run: choco install -y erlang --version ${{ matrix.otp-version }}
- name: Install rebar3
run: choco install -y rebar3 --version 3.23.0
- name: Compile
Expand Down Expand Up @@ -141,21 +145,21 @@ jobs:
run: rebar3 edoc

# Make release artifacts : erlang_ls
- name: Make erlang_ls-win32.tar.gz
run: 'tar -zcvf erlang_ls-win32.tar.gz -C _build/default/bin/ erlang_ls'
- name: Make erlang_ls-windows-${{ matrix.otp-version }}.tar.gz
run: 'tar -zcvf erlang_ls-windows-${{ matrix.otp-version }}.tar.gz -C _build/default/bin/ erlang_ls'
- env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
id: get_release_url
name: Get release url
uses: "bruceadams/[email protected]"
- env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
name: Upload release erlang_ls.-win32.tar.gz
name: Upload release erlang_ls-windows-${{ matrix.otp-version }}.tar.gz
uses: "actions/[email protected]"
with:
asset_content_type: application/octet-stream
asset_name: erlang_ls-win32.tar.gz
asset_path: erlang_ls-win32.tar.gz
asset_name: erlang_ls-windows-${{ matrix.otp-version }}.tar.gz
asset_path: erlang_ls-windows-${{ matrix.otp-version }}.tar.gz
upload_url: "${{ steps.get_release_url.outputs.upload_url }}"
macos:
# Smaller job for MacOS to avoid excessive billing
Expand All @@ -175,19 +179,19 @@ jobs:
- name: Escriptize LSP Server
run: rebar3 escriptize
# Make release artifacts : erlang_ls
- name: Make erlang_ls-${{ matrix.otp-version }}-macos.tar.gz
run: 'tar -zcvf erlang_ls-${{ matrix.otp-version }}-macos.tar.gz -C _build/default/bin/ erlang_ls'
- name: Make erlang_ls-macos-${{ matrix.otp-version }}.tar.gz
run: 'tar -zcvf erlang_ls-macos-${{ matrix.otp-version }}.tar.gz -C _build/default/bin/ erlang_ls'
- env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
id: get_release_url
name: Get release url
uses: "bruceadams/[email protected]"
- env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
name: Upload release erlang_ls-${{ matrix.otp-version }}-macos.tar.gz
name: Upload release erlang_ls-macos-${{ matrix.otp-version }}.tar.gz
uses: "actions/[email protected]"
with:
asset_content_type: application/octet-stream
asset_name: erlang_ls-${{ matrix.otp-version }}-macos.tar.gz
asset_path: erlang_ls-${{ matrix.otp-version }}-macos.tar.gz
asset_name: erlang_ls-macos-${{ matrix.otp-version }}.tar.gz
asset_path: erlang_ls-macos-${{ matrix.otp-version }}.tar.gz
upload_url: "${{ steps.get_release_url.outputs.upload_url }}"

0 comments on commit ed1daaa

Please sign in to comment.