Created
March 6, 2018 10:27
-
-
Save amielucha/43a42791f9e9f1b9799539672ffc3983 to your computer and use it in GitHub Desktop.
PowerShell function accepting parameters
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
| # This function passes up to 9 chained params to `wpcli` on docker in the current directory. | |
| # I haven't figured out how to spread an undefined amount of parameters yet... | |
| # Simply call "wp help", "wp post list" etc. | |
| function wp($p1, $p2, $p3, $p4, $p5, $p6, $p7, $p8, $p9) { docker-compose run --rm wpcli $p1 $p2 $p3 $p4 $p5 $p6 $p7 $p8 $p9 } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment