Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

enhancement(dev): Add dedicated helper tool #15833

Merged
merged 34 commits into from
Jan 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
a1afed9
Add dedicated dev tool
ofek Oct 26, 2022
9ebac12
refactor
ofek Oct 31, 2022
3b71558
Apply suggestions from code review
ofek Nov 1, 2022
9f44785
address
ofek Nov 1, 2022
fb2163f
add env management commands
ofek Nov 3, 2022
ec58410
add test command
ofek Nov 7, 2022
4de3c12
refactor with once_cell
ofek Nov 7, 2022
3d1ffa6
refactor sub-process handling
ofek Nov 8, 2022
9e3d6f4
improve error messages
ofek Nov 8, 2022
fd833a7
handle case of first time user
ofek Nov 8, 2022
a2e000c
reduce boilerplate with macros
ofek Nov 9, 2022
f43fb51
address
ofek Nov 9, 2022
b9d8583
Apply suggestions from code review
ofek Nov 9, 2022
9939e81
address
ofek Nov 10, 2022
f12f024
add top-level test command
ofek Nov 11, 2022
89d1892
add to CI
ofek Nov 13, 2022
25f08a8
Apply suggestions from code review
ofek Nov 16, 2022
953937b
final update
ofek Nov 19, 2022
24f37f6
Merge remote-tracking branch 'origin/master' into vdev
bruceg Dec 22, 2022
2952ffe
Fix clippy lints
bruceg Dec 22, 2022
6deaee8
Convert extensions to `process::Command` into an extension trait
bruceg Dec 22, 2022
5053beb
Add `infer_subcommands` option and unabbreviate `int` subcommand
bruceg Dec 22, 2022
5b68809
address
ofek Dec 27, 2022
df850d0
Merge remote-tracking branch 'ofek/vdev' into bruceg/vdev
bruceg Jan 3, 2023
790aa9a
Flatten out the `cli.rs` files
bruceg Jan 4, 2023
15c6d6c
Inline the used cfg options
bruceg Jan 4, 2023
a38d183
Drop unused config bits
bruceg Jan 5, 2023
5ee9df7
Turn on `clippy::pedantic` and fix issues
bruceg Jan 5, 2023
8e6cde0
Pass command args owned to allow for direct use
bruceg Jan 5, 2023
ec53996
Eliminate some silent error fallbacks
bruceg Jan 5, 2023
e998ee2
Simplify logic of `integration show`
bruceg Jan 5, 2023
c575c50
Merge remote-tracking branch 'origin/master' into bruceg/vdev
bruceg Jan 6, 2023
e21ec11
Drop some common parameters in testing functions
bruceg Jan 5, 2023
75c2f60
Fix new clippy lints
bruceg Jan 6, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 51 additions & 0 deletions .github/workflows/actions/install-vdev/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: Install vdev

inputs:
token:
required: true

runs:
using: composite

steps:
# default 2.x fails
- if: runner.os == 'Windows'
uses: ruby/setup-ruby@v1
with:
ruby-version: '3.1'

- name: Wait for build
uses: lewagon/wait-on-check-action@v1.2.0
with:
repo-token: ${{ inputs.token }}
check-name: Build executable for ${{ runner.os }}
ref: ${{ github.sha }}
wait-interval: 20

- name: Try downloading current artifact
uses: dawidd6/action-download-artifact@v2
with:
github_token: ${{ inputs.token }}
workflow: build-vdev.yml
branch: ${{ github.ref_name }}
name: vdev-${{ runner.os }}
path: vdev/bin

- if: github.event_name == 'pull_request' && failure()
name: Download latest artifact
uses: dawidd6/action-download-artifact@v2
with:
github_token: ${{ inputs.token }}
workflow: build-vdev.yml
branch: master
name: vdev-${{ runner.os }}
path: vdev/bin

- name: Add binary to PATH
run: mv vdev/bin/* "$HOME/.cargo/bin"
shell: bash

- if: runner.os != 'Windows'
name: Make binary executable
run: chmod +x "$HOME/.cargo/bin/vdev"
shell: bash
43 changes: 43 additions & 0 deletions .github/workflows/build-vdev.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Build vdev

on:
push:
branches:
- master
pull_request:
branches:
- master
paths:
- "vdev/**/*"

concurrency:
group: ${{ github.workflow }}-${{ github.event.number || github.sha }}
cancel-in-progress: true

jobs:
exe:
# Name must match runner.os https://docs.github.com/en/actions/learn-github-actions/contexts#runner-context
name: Build executable for ${{ startsWith(matrix.os, 'macos-') && 'macOS' || startsWith(matrix.os, 'windows-') && 'Windows' || 'Linux' }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]

steps:
- uses: actions/checkout@v3

- name: Build release binary
run: |
cd vdev
cargo build --release

- if: runner.os != 'Windows'
name: Strip binary
run: strip vdev/target/release/vdev

- uses: actions/upload-artifact@v3
with:
name: vdev-${{ runner.os }}
path: vdev/target/release/${{ runner.os == 'Windows' && 'vdev.exe' || 'vdev' }}
if-no-files-found: error
Loading