Skip to content

Instantly share code, notes, and snippets.

@jschpp
Last active February 26, 2016 11:46
Show Gist options
  • Save jschpp/616a62dc0261668cd2ba to your computer and use it in GitHub Desktop.
Save jschpp/616a62dc0261668cd2ba to your computer and use it in GitHub Desktop.
silver searcher test
FROM ubuntu:precise
# essentials
RUN apt-get update -q
RUN apt-get install -y python-software-properties curl build-essential
# ag specific
RUN add-apt-repository -y 'ppa:ubuntu-toolchain-r/test'
RUN add-apt-repository -y 'deb http://llvm.org/apt/precise/ llvm-toolchain-precise-3.6 main'
RUN curl http://llvm.org/apt/llvm-snapshot.gpg.key | apt-key add -
RUN apt-get update -q
RUN apt-get install -q -y automake pkg-config libpcre3-dev zlib1g-dev liblzma-dev
RUN apt-get install -y clang-format-3.6
# pip, git and cram for testing
RUN apt-get install -y python-pip git
RUN pip install cram
# mercurial and libtool for libzip
RUN apt-get install -y mercurial libtool
# libzip >= 1.0 is needed to search zip files
RUN hg clone -u rel-1-1-2 http://hg.nih.at/libzip/ /tmp/libzip
RUN cd /tmp/libzip && autoreconf -fi && ./configure --prefix=/usr && make && make install
# args can be switched to work with ggreers version an not just my fork
ARG repo="https://github.com/jschpp/the_silver_searcher"
ARG branch=zip
# build ag and test it
RUN git clone -b $branch $repo /tmp/the_silver_searcher
RUN cd /tmp/the_silver_searcher && ./build.sh --enable-libzip && make test
@jschpp
Copy link
Author

jschpp commented Feb 26, 2016

This is mostly for myself. With this I can test my silver searcher repo without using travis which is simpler for me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment