Hi,
Trying to make a pipeline through a tutorial(1) about cucumber testing. He is using Mac, I’m using Windows so there is some issues.
Hey @Stephanie!
Thanks for your post and welcome to the Buildkite community! The course you’ve linked to is a paid course, so we can’t see the content of it. Are you able to share the contents of your .buildkite/pipeline.sh
file? Or would you be able to email us at support@buildkite.com if the contents are something you’d rather not share?
Additionally, have you followed our set up guide for installing the agent on a Windows machine?
Cheers,
Ben
My issue is I dont know how to write the powershell script. Error Im getting.
> ./buildkite/pipeline.sh | buildkite-agent pipeline upload
./buildkite/pipeline.sh : The term './buildkite/pipeline.sh' is not recognized as the
name of a cmdlet, function, script file, or operable program. Check the spelling of the
name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ ./buildkite/pipeline.sh | buildkite-agent pipeline upload
+ ~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (./buildkite/pipeline.sh:String) [], Comman
dNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
More info…
File location
File content (pipeline.sh)
#!/bin/bash
set -euo pipefail
PIPELINE=${PIPELINE:-build}
function build() {
cat <<EOF
steps:
- name: ":desktop_computer: Automation"
- command: "./scripts/buildkite-automation.sh"
EOF
}
$PIPELINE
Hey @Stephanie!
Thanks for the follow up information!
I believe this might be a Windows file referencing quirk; Windows prefers \
over /
, so you’d need to change your referencing to .\buildkite\pipeline.sh
, I also think that PowerShell requires a leading .
to mount the file and possibly a call to Bash.
I think if you change your command to be the following, it might help resolve the issue:
bash . .\buildkite\pipeline.sh | buildkite-agent upload
Cheers,
Ben