diff --git a/.github/workflows/bin.yaml b/.github/workflows/bin.yaml index 35a10c1f..76a23aa0 100644 --- a/.github/workflows/bin.yaml +++ b/.github/workflows/bin.yaml @@ -45,6 +45,7 @@ jobs: # needs: ['create-release'] runs-on: ${{ matrix.os }} env: + PROJECT_NAME: buffrs # For some builds, we use cross to test on 32-bit and big-endian # systems. CARGO: cargo @@ -157,9 +158,9 @@ jobs: run: | ${{ env.CARGO }} build --verbose --release if [ "${{ matrix.os }}" = "windows-latest" ]; then - bin="target/${{ matrix.target }}/release/rg.exe" + bin="target/${{ matrix.target }}/release/${{ env.PROJECT_NAME }}.exe" else - bin="target/${{ matrix.target }}/release/rg" + bin="target/${{ matrix.target }}/release/${{ env.PROJECT_NAME }}" fi echo "BIN=$bin" >> $GITHUB_ENV @@ -176,7 +177,7 @@ jobs: "$PWD/target:/target:Z" \ "rustembedded/cross:${{ matrix.target }}" \ "${{ matrix.strip }}" \ - "/target/${{ matrix.target }}/release/rg" + "/target/${{ matrix.target }}/release/${{ env.PROJECT_NAME }}" - name: Determine archive name shell: bash @@ -198,11 +199,11 @@ jobs: # shell: bash # run: | # "$BIN" --version - # "$BIN" --generate complete-bash > "$ARCHIVE/complete/rg.bash" - # "$BIN" --generate complete-fish > "$ARCHIVE/complete/rg.fish" - # "$BIN" --generate complete-powershell > "$ARCHIVE/complete/_rg.ps1" - # "$BIN" --generate complete-zsh > "$ARCHIVE/complete/_rg" - # "$BIN" --generate man > "$ARCHIVE/doc/rg.1" + # "$BIN" --generate complete-bash > "$ARCHIVE/complete/${{ env.PROJECT_NAME }}.bash" + # "$BIN" --generate complete-fish > "$ARCHIVE/complete/${{ env.PROJECT_NAME }}.fish" + # "$BIN" --generate complete-powershell > "$ARCHIVE/complete/_${{ env.PROJECT_NAME }}.ps1" + # "$BIN" --generate complete-zsh > "$ARCHIVE/complete/_${{ env.PROJECT_NAME }}" + # "$BIN" --generate man > "$ARCHIVE/doc/${{ env.PROJECT_NAME }}.1" # - name: Generate man page and completions (emulation) # if: matrix.qemu != '' @@ -216,27 +217,27 @@ jobs: # "$PWD/target:/target:Z" \ # "rustembedded/cross:${{ matrix.target }}" \ # "${{ matrix.qemu }}" "/$BIN" \ - # --generate complete-bash > "$ARCHIVE/complete/rg.bash" + # --generate complete-bash > "$ARCHIVE/complete/${{ env.PROJECT_NAME }}.bash" # docker run --rm -v \ # "$PWD/target:/target:Z" \ # "rustembedded/cross:${{ matrix.target }}" \ # "${{ matrix.qemu }}" "/$BIN" \ - # --generate complete-fish > "$ARCHIVE/complete/rg.fish" + # --generate complete-fish > "$ARCHIVE/complete/${{ env.PROJECT_NAME }}.fish" # docker run --rm -v \ # "$PWD/target:/target:Z" \ # "rustembedded/cross:${{ matrix.target }}" \ # "${{ matrix.qemu }}" "/$BIN" \ - # --generate complete-powershell > "$ARCHIVE/complete/_rg.ps1" + # --generate complete-powershell > "$ARCHIVE/complete/_${{ env.PROJECT_NAME }}.ps1" # docker run --rm -v \ # "$PWD/target:/target:Z" \ # "rustembedded/cross:${{ matrix.target }}" \ # "${{ matrix.qemu }}" "/$BIN" \ - # --generate complete-zsh > "$ARCHIVE/complete/_rg" + # --generate complete-zsh > "$ARCHIVE/complete/_${{ env.PROJECT_NAME }}" # docker run --rm -v \ # "$PWD/target:/target:Z" \ # "rustembedded/cross:${{ matrix.target }}" \ # "${{ matrix.qemu }}" "/$BIN" \ - # --generate man > "$ARCHIVE/doc/rg.1" + # --generate man > "$ARCHIVE/doc/${{ env.PROJECT_NAME }}.1" - name: Build archive (Windows) shell: bash @@ -302,7 +303,7 @@ jobs: shell: bash run: | cargo build --target ${{ env.TARGET }} - bin="target/${{ env.TARGET }}/debug/rg" + bin="target/${{ env.TARGET }}/debug/${{ env.PROJECT_NAME }}" echo "BIN=$bin" >> $GITHUB_ENV - name: Create deployment directory @@ -315,14 +316,14 @@ jobs: - name: Generate man page shell: bash run: | - "$BIN" --generate man > "$DEPLOY_DIR/rg.1" + "$BIN" --generate man > "$DEPLOY_DIR/${{ env.PROJECT_NAME }}.1" - name: Generate shell completions shell: bash run: | - "$BIN" --generate complete-bash > "$DEPLOY_DIR/rg.bash" - "$BIN" --generate complete-fish > "$DEPLOY_DIR/rg.fish" - "$BIN" --generate complete-zsh > "$DEPLOY_DIR/_rg" + "$BIN" --generate complete-bash > "$DEPLOY_DIR/${{ env.PROJECT_NAME }}.bash" + "$BIN" --generate complete-fish > "$DEPLOY_DIR/${{ env.PROJECT_NAME }}.fish" + "$BIN" --generate complete-zsh > "$DEPLOY_DIR/_${{ env.PROJECT_NAME }}" - name: Build release binary shell: bash