@@ -20,78 +20,78 @@ inputs:
2020runs :
2121 using : " composite"
2222 steps :
23- - uses : actions/checkout@v7
23+ - uses : actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # ratchet: actions/checkout@v7
2424
25- - uses : Swatinem/rust-cache@82a92a6e8fbeee089604da2575dc567ae9ddeaab # ratchet:Swatinem/rust-cache@v2
26- if : ${{ inputs.container == null }}
25+ - uses : Swatinem/rust-cache@6323deb102c322ba6fcbdcafc7e3dddab59af2b6 # ratchet:Swatinem/rust-cache@v2
26+ if : ${{ inputs.container == null }}
2727
28- - uses : dtolnay/rust-toolchain@7b1c307e0dcbda6122208f10795a713336a9b35a # ratchet:dtolnay/rust-toolchain@master
29- if : ${{ inputs.container == null }}
30- with :
31- targets : ${{ inputs.rust_target }}
32- toolchain : " 1.85.0"
28+ - uses : dtolnay/rust-toolchain@6c977a6ca4077a0ceb28ffbe03f59d46e9ac8772 # ratchet:dtolnay/rust-toolchain@master
29+ if : ${{ inputs.container == null }}
30+ with :
31+ targets : ${{ inputs.rust_target }}
32+ toolchain : " 1.85.0"
3333
34- - name : Install Nix
35- if : ${{ inputs.os_name != 'windows' }}
36- uses : DeterminateSystems/nix-installer-action@v16
34+ - name : Install Nix
35+ if : ${{ inputs.os_name != 'windows' }}
36+ uses : DeterminateSystems/nix-installer-action@ef8a148080ab6020fd15196c2084a2eea5ff2d25 # ratchet:DeterminateSystems/nix-installer-action@v22
3737
38- - name : Build all crates (Linux/MacOS)
39- shell : bash
40- if : ${{ inputs.container == null && inputs.os_name != 'windows' }}
41- run : |
42- # TODO reproduce packpath folder
43- # ./scripts/setup-deps.sh clone "deps/start"
38+ - name : Build all crates (Linux/MacOS)
39+ shell : bash
40+ if : ${{ inputs.container == null && inputs.os_name != 'windows' }}
41+ run : |
42+ # TODO reproduce packpath folder
43+ # ./scripts/setup-deps.sh clone "deps/start"
4444
45- set -x
46- mkdir -p ~/.cache/nvim
47- nix develop .#ci --command nvim -V3nvim.log --headless -u NONE --cmd "set rtp^=." -c "runtime plugin/avante.lua" -c "lua vim.g.avante = { debug= vim.log.levels.INFO }" -c "AvanteBuild source=true" +quit!
45+ set -x
46+ mkdir -p ~/.cache/nvim
47+ nix develop .#ci --command nvim -V3nvim.log --headless -u NONE --cmd "set rtp^=." -c "runtime plugin/avante.lua" -c "lua vim.g.avante = { debug= vim.log.levels.INFO }" -c "AvanteBuild source=true" +quit!
4848
49- # to help diagnose failures
50- cat nvim.log
51- ls -lRa lua
49+ # to help diagnose failures
50+ cat nvim.log
51+ ls -la lua
5252
5353
54- - name : Build all crates (Windows)
55- if : ${{ inputs.os_name == 'windows' }}
56- shell : bash
57- run : |
58- # TODO run AvanteBuild instead
59- cargo build --release --features ${{ matrix.feature }} --target ${{ inputs.rust_target }}
54+ - name : Build all crates (Windows)
55+ if : ${{ inputs.os_name == 'windows' }}
56+ shell : bash
57+ run : |
58+ # TODO run AvanteBuild instead
59+ cargo build --release --features ${{ matrix.feature }} --target ${{ inputs.rust_target }}
6060
61- - name : Build all crates (Linux) with glibc 2.17 # for glibc 2.17
62- shell : bash
63- if : ${{ inputs.container != null }}
64- run : |
65- # sudo apt-get install -y qemu qemu-user-static
66- docker run \
67- --rm \
68- -v $(pwd):/workspace \
69- -w /workspace \
70- --platform ${{ inputs.docker_platform }} \
71- ${{ inputs.container }} \
72- bash -c "yum install -y perl-IPC-Cmd openssl-devel && curl --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal && . /root/.cargo/env && make ${{ matrix.feature }} BUILD_FROM_SOURCE=true"
61+ - name : Build all crates (Linux) with glibc 2.17 # for glibc 2.17
62+ shell : bash
63+ if : ${{ inputs.container != null }}
64+ run : |
65+ # sudo apt-get install -y qemu qemu-user-static
66+ docker run \
67+ --rm \
68+ -v $(pwd):/workspace \
69+ -w /workspace \
70+ --platform ${{ inputs.docker_platform }} \
71+ ${{ inputs.container }} \
72+ bash -c "yum install -y perl-IPC-Cmd openssl-devel && curl --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal && . /root/.cargo/env && make ${{ matrix.feature }} BUILD_FROM_SOURCE=true"
7373
74- - name : Handle binaries (Linux/MacOS)
75- if : ${{ inputs.os_name != 'windows' }}
76- shell : bash
77- run : |
78- mkdir -p results
79- cp -v lua/avante_*.so results/
80- tar zcvf avante_lib-${{ inputs.os_name }}-${{ inputs.arch }}-${{ matrix.feature }}.tar.gz results/*.so
74+ - name : Handle binaries (Linux/MacOS)
75+ if : ${{ inputs.os_name != 'windows' }}
76+ shell : bash
77+ run : |
78+ mkdir -p results
79+ cp -v lua/avante_*.so results/
80+ tar zcvf avante_lib-${{ inputs.os_name }}-${{ inputs.arch }}-${{ matrix.feature }}.tar.gz results/*.so
8181
82- - name : Handle binaries (Windows)
83- if : ${{ inputs.os_name == 'windows' }}
84- shell : pwsh
85- run : |
86- New-Item -ItemType Directory -Force -Path results
82+ - name : Handle binaries (Windows)
83+ if : ${{ inputs.os_name == 'windows' }}
84+ shell : pwsh
85+ run : |
86+ New-Item -ItemType Directory -Force -Path results
8787
88- $TargetDir = "target\${{ inputs.rust_target }}\release"
89- Copy-Item -Path "$TargetDir\avante_templates.dll" -Destination "results\avante_templates.dll"
90- Copy-Item -Path "$TargetDir\avante_tokenizers.dll" -Destination "results\avante_tokenizers.dll"
91- Copy-Item -Path "$TargetDir\avante_repo_map.dll" -Destination "results\avante_repo_map.dll"
92- Copy-Item -Path "$TargetDir\avante_html2md.dll" -Destination "results\avante_html2md.dll"
88+ $TargetDir = "target\${{ inputs.rust_target }}\release"
89+ Copy-Item -Path "$TargetDir\avante_templates.dll" -Destination "results\avante_templates.dll"
90+ Copy-Item -Path "$TargetDir\avante_tokenizers.dll" -Destination "results\avante_tokenizers.dll"
91+ Copy-Item -Path "$TargetDir\avante_repo_map.dll" -Destination "results\avante_repo_map.dll"
92+ Copy-Item -Path "$TargetDir\avante_html2md.dll" -Destination "results\avante_html2md.dll"
9393
94- Set-Location -Path results
94+ Set-Location -Path results
9595
96- $dllFiles = Get-ChildItem -Filter "*.dll" | Select-Object -ExpandProperty Name
97- Compress-Archive -Path $dllFiles -DestinationPath "avante_lib-${{ inputs.os_name }}-${{ inputs.arch }}-${{ matrix.feature }}.zip"
96+ $dllFiles = Get-ChildItem -Filter "*.dll" | Select-Object -ExpandProperty Name
97+ Compress-Archive -Path $dllFiles -DestinationPath "avante_lib-${{ inputs.os_name }}-${{ inputs.arch }}-${{ matrix.feature }}.zip"
0 commit comments