Fix versions #45
This file contains 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
name: Go | |
on: | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master ] | |
jobs: | |
build: | |
name: Build | |
runs-on: macos-latest | |
steps: | |
- name: Install libusb by homebrew | |
run: brew install libusb | |
- name: Install pkg-config by homebrew | |
run: brew install pkg-config | |
- name: Install ffmpeg by homebrew | |
run: brew install ffmpeg@4 | |
- name: Install librarys by homebrew | |
run: brew install gstreamer gst-plugins-bad gst-plugins-good gst-plugins-base gst-plugins-ugly | |
- name: Set up Go 1.x | |
uses: actions/setup-go@v2 | |
with: | |
go-version: ^1.14.4 | |
id: go | |
- name: Check out code into the Go module directory | |
uses: actions/checkout@v2 | |
- name: Set PKG_CONFIG_PATH | |
run: echo "PKG_CONFIG_PATH=$(brew --prefix ffmpeg@4)/lib/pkgconfig:$PKG_CONFIG_PATH" >> $GITHUB_ENV | |
- name: Get dependencies | |
run: | | |
go get -v -t -d ./... | |
if [ -f Gopkg.toml ]; then | |
curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh | |
dep ensure | |
fi | |
- name: Build | |
run: go build -v -o ios-screen-mirror | |
- name: Test | |
run: go test -v . | |
- run: ls -al | |
- uses: actions/checkout@v2 | |
- uses: actions/upload-artifact@v2 | |
with: | |
name: ios-screen-mirror | |
path: "ios-screen-mirror" |