Tell Ollama to not unload models automatically #25
Workflow file for this run
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
name: build | |
on: [push] | |
jobs: | |
build: | |
strategy: | |
fail-fast: false | |
matrix: | |
os: | |
- os: ubuntu-20.04 | |
build-name: llm-multitool | |
exe-name: llm-multitool-linux-amd64 | |
- os: windows-latest | |
build-name: llm-multitool.exe | |
exe-name: llm-multitool-windows-amd64.exe | |
- os: macos-latest | |
build-name: llm-multitool | |
exe-name: llm-multitool-macos | |
runs-on: ${{ matrix.os.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version: 1.21.1 | |
- name: Prepare backend | |
run: | | |
cd backend | |
go install -v github.com/searKing/golang/tools/go-enum | |
- name: Prepare frontend | |
working-directory: frontend | |
run: npm install | |
- name: Build frontend | |
working-directory: frontend | |
run: npm run build | |
- name: Move frontend artifacts | |
run: cp -r ./frontend/dist ./backend/resources | |
- name: Build Backend | |
working-directory: backend | |
run: | | |
go generate -v -x ./... | |
go build . | |
- name: Test backend | |
working-directory: backend | |
run: | |
go test ./... | |
- name: Rename executable | |
run: mv backend/${{ matrix.os.build-name }} ${{ matrix.os.exe-name }} | |
- name: Keep the executable | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ${{ matrix.os.exe-name }} | |
path: ${{ matrix.os.exe-name }} | |
release-tag-as-draft: | |
name: Release tag as a draft release | |
runs-on: ubuntu-latest | |
needs: [build] | |
if: startsWith(github.ref, 'refs/tags/') | |
steps: | |
- name: Download Linux executable | |
uses: actions/download-artifact@v2 | |
with: | |
name: llm-multitool-linux-amd64 | |
- name: Download MacOS executable | |
uses: actions/download-artifact@v2 | |
with: | |
name: llm-multitool-macos | |
- name: Download Windows executable | |
uses: actions/download-artifact@v2 | |
with: | |
name: llm-multitool-windows-amd64.exe | |
- name: Create GH release | |
uses: softprops/action-gh-release@v1 | |
with: | |
files: | | |
llm-multitool-linux-amd64 | |
llm-multitool-macos | |
llm-multitool-windows-amd64.exe | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |