Fix macOS CI #115
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: macOS | |
on: [push, pull_request] | |
jobs: | |
install: | |
runs-on: macos-latest | |
if: github.ref == 'refs/heads/master' | |
strategy: | |
matrix: | |
compiler: [clang, gcc] | |
steps: | |
- name: Patch | |
run: | | |
HOMEBREW_NO_INSTALL_FROM_API=1 HOMEBREW_EDITOR=touch brew edit tig | |
cd "$(brew --prefix)"/opt/tig/.brew && patch -p1 <<\EOF | |
--- a/tig.rb | |
+++ b/tig.rb | |
@@ -21,9 +21,11 @@ class Tig < Formula | |
depends_on "readline" | |
def install | |
+ ENV.deparallelize | |
system "./autogen.sh" if build.head? | |
system "./configure", "--prefix=#{prefix}", "--sysconfdir=#{etc}" | |
system "make" | |
+ system "make", "test" | |
# Ensure the configured `sysconfdir` is used during runtime by | |
# installing in a separate step. | |
system "make", "install", "sysconfdir=#{pkgshare}/examples" | |
EOF | |
- name: Install latest Tig | |
shell: 'script -q typescript sh {0}' # Workaround to get a TTY, see https://github.com/gfx/example-github-actions-with-tty | |
run: HOMEBREW_CC=${{ matrix.compiler }} HOMEBREW_NO_AUTO_UPDATE=1 brew install --HEAD tig | |
ci: | |
runs-on: macos-latest | |
if: github.ref != 'refs/heads/master' | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Test Tig | |
shell: 'script -q typescript sh {0}' # Workaround to get a TTY, see https://github.com/gfx/example-github-actions-with-tty | |
run: | | |
brew install asciidoc autoconf automake coreutils gnu-sed ncurses xmlto | |
TIG_BUILD=autoconf tools/travis.sh |