[cmd] Add Commands.runStartEnd()#7931
[cmd] Add Commands.runStartEnd()#7931Spaceman113138 wants to merge 11 commits intowpilibsuite:mainfrom
Conversation
|
This PR modifies commands. Please open a corresponding PR in Python Commands and include a link to this PR. |
|
Perhaps writing it all on my phone was not the greatest idea |
KangarooKoala
left a comment
There was a problem hiding this comment.
Neat feature! I've been wanting something like this for some time too. You missed a few things, but still super duper impressive for mobile!
You'll also want to fix the formatting changes, which can be done by running ./gradlew wpilibNewCommands:spotlessApply (for Java formatting) and applying the wpiformat changes (for C++ formatting).
wpilibNewCommands/src/main/java/edu/wpi/first/wpilibj2/command/Commands.java
Outdated
Show resolved
Hide resolved
wpilibNewCommands/src/main/java/edu/wpi/first/wpilibj2/command/Commands.java
Show resolved
Hide resolved
wpilibNewCommands/src/main/java/edu/wpi/first/wpilibj2/command/Subsystem.java
Outdated
Show resolved
Hide resolved
wpilibNewCommands/src/main/java/edu/wpi/first/wpilibj2/command/Subsystem.java
Show resolved
Hide resolved
wpilibNewCommands/src/main/native/include/frc2/command/Commands.h
Outdated
Show resolved
Hide resolved
wpilibNewCommands/src/main/native/include/frc2/command/Subsystem.h
Outdated
Show resolved
Hide resolved
wpilibNewCommands/src/main/native/include/frc2/command/Subsystem.h
Outdated
Show resolved
Hide resolved
|
added the missing return in the docs and fixed the formatting so should be good now |
KangarooKoala
left a comment
There was a problem hiding this comment.
Looks good to me! I'm not an official maintainer (just another person reviewing and contributing PRs), so I unfortunately can't approve the CI run. (An official maintainer will also need to approve the PR before it gets merged.)
Adds a method like startRun or runEnd to Commands and Subsystem to make it easier to write commands that have a start, running, and end actions. I’ve seen this mentioned in a few places so I figured I might as well write it.