Repository navigation
Add self-update and subcommands - #5
Merged
Merged
Conversation
- Move the process monitor into `procplot exec` - Add `procplot upgrade` (with `--check`) using self_update against alshlabs/procplot GitHub releases - Add `procplot version` - Update README and test/run.bash
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Based on the reference in template-rust-cli's
src/cmd/upgrade/main.rs.Changes
procplot exec: the previous top-level behaviour moved underexec;args.rsandreporter.rsmoved tosrc/cmd/exec/. All existing options (-r,-i,-m,-t,-o,--no-*) andPM_*env vars are unchanged; the command is still passed after--(procplot exec -- node script.mjs).procplot upgrade: ported from the template — usesself_update(rustls) against GitHub releases ofalshlabs/procplot, selects the asset matching OS/arch, and is skipped for prerelease versions.--checkreports whether a newer release exists. Failures now propagate to the exit code instead of printing and returning 0.procplot version: printsCARGO_PKG_VERSION(the top level also has--version).self_update(github, reqwest, rustls, tar.gz, checksums) andsemver.test/run.bashrunscargo run -- exec.Notes for reviewers
procplot -- node ...no longer works; it must beprocplot exec -- node ....0.0.x), soprocplot upgradewill report "already on the latest version" until a release built by the new workflow is the latest.Verification (local)
cargo clippy --all-targets --workspace -- -D warningsandcargo xfmt --checkpasscargo build --release;procplot --help,procplot exec --help,procplot versionbehave as documentedprocplot exec -- node ...produces the expected CSVprocplot upgrade --checkqueries GitHub correctly (reports 0.2.0 as latest, as no newer release exists)