Merge pull request #31605 from Mic92/disable-travis
travis: disable for pull requests
This commit is contained in:
commit
a8a2c22a23
35
.travis.yml
35
.travis.yml
@ -1,35 +0,0 @@
|
||||
language: nix
|
||||
sudo: true
|
||||
# 'sudo: false' == containers that start fast, but only get 4G ram;
|
||||
# 'sudo: true' == VMs that start slow, but with 8G
|
||||
# ..as per: https://docs.travis-ci.com/user/ci-environment/#Virtualization-environments
|
||||
# Nixpkgs PR tests OOM with 4G: https://github.com/NixOS/nixpkgs/issues/24200
|
||||
|
||||
matrix:
|
||||
include:
|
||||
- os: linux
|
||||
sudo: required
|
||||
script:
|
||||
- ./maintainers/scripts/travis-nox-review-pr.sh nixpkgs-verify nixpkgs-manual nixpkgs-tarball nixpkgs-unstable
|
||||
- ./maintainers/scripts/travis-nox-review-pr.sh nixos-options nixos-manual
|
||||
env:
|
||||
- BUILD_TYPE="Test Nixpkgs evaluation & NixOS manual build"
|
||||
- os: linux
|
||||
sudo: required
|
||||
dist: trusty
|
||||
before_script:
|
||||
- sudo mount -o remount,exec,size=2G,mode=755 /run/user
|
||||
script: ./maintainers/scripts/travis-nox-review-pr.sh nox pr
|
||||
env:
|
||||
- BUILD_TYPE="Build affected packages (Linux)"
|
||||
- os: osx
|
||||
osx_image: xcode7.3
|
||||
script: ./maintainers/scripts/travis-nox-review-pr.sh nox pr
|
||||
env:
|
||||
- BUILD_TYPE="Build affected packages (macOS)"
|
||||
env:
|
||||
global:
|
||||
- GITHUB_TOKEN=5edaaf1017f691ed34e7f80878f8f5fbd071603f
|
||||
|
||||
notifications:
|
||||
email: false
|
@ -1,82 +0,0 @@
|
||||
#! /usr/bin/env bash
|
||||
set -e
|
||||
|
||||
while test -n "$1"; do
|
||||
|
||||
# tell Travis to use folding
|
||||
echo -en "travis_fold:start:$1\r"
|
||||
|
||||
case $1 in
|
||||
|
||||
nixpkgs-verify)
|
||||
echo "=== Verifying that nixpkgs evaluates..."
|
||||
|
||||
nix-env --file $TRAVIS_BUILD_DIR --query --available --json > /dev/null
|
||||
;;
|
||||
|
||||
nixos-options)
|
||||
echo "=== Checking NixOS options"
|
||||
|
||||
nix-build $TRAVIS_BUILD_DIR/nixos/release.nix --attr options --show-trace
|
||||
;;
|
||||
|
||||
nixos-manual)
|
||||
echo "=== Checking NixOS manuals"
|
||||
|
||||
nix-build $TRAVIS_BUILD_DIR/nixos/release.nix --attr manual --show-trace
|
||||
;;
|
||||
|
||||
nixpkgs-manual)
|
||||
echo "=== Checking nixpkgs manuals"
|
||||
|
||||
nix-build $TRAVIS_BUILD_DIR/pkgs/top-level/release.nix --attr manual --show-trace
|
||||
;;
|
||||
|
||||
nixpkgs-tarball)
|
||||
echo "=== Checking nixpkgs tarball creation"
|
||||
|
||||
nix-build $TRAVIS_BUILD_DIR/pkgs/top-level/release.nix --attr tarball --show-trace
|
||||
;;
|
||||
|
||||
nixpkgs-unstable)
|
||||
echo "=== Checking nixpkgs unstable job"
|
||||
|
||||
nix-instantiate $TRAVIS_BUILD_DIR/pkgs/top-level/release.nix --attr unstable --show-trace
|
||||
;;
|
||||
|
||||
nixpkgs-lint)
|
||||
echo "=== Checking nixpkgs lint"
|
||||
|
||||
nix-shell --packages nixpkgs-lint --run "nixpkgs-lint -f $TRAVIS_BUILD_DIR"
|
||||
;;
|
||||
|
||||
nox)
|
||||
echo "=== Fetching Nox from binary cache"
|
||||
|
||||
# build nox (+ a basic nix-shell env) silently so it's not in the log
|
||||
nix-shell -p nox stdenv --command true
|
||||
;;
|
||||
|
||||
pr)
|
||||
if [ "$TRAVIS_PULL_REQUEST" == "false" ]; then
|
||||
echo "=== No pull request found"
|
||||
else
|
||||
echo "=== Building pull request #$TRAVIS_PULL_REQUEST"
|
||||
|
||||
token=""
|
||||
if [ -n "$GITHUB_TOKEN" ]; then
|
||||
token="--token $GITHUB_TOKEN"
|
||||
fi
|
||||
|
||||
nix-shell --packages nox --run "nox-review pr --slug $TRAVIS_REPO_SLUG $token $TRAVIS_PULL_REQUEST"
|
||||
fi
|
||||
;;
|
||||
|
||||
*)
|
||||
echo "Skipping unknown option $1"
|
||||
;;
|
||||
esac
|
||||
|
||||
echo -en "travis_fold:end:$1\r"
|
||||
shift
|
||||
done
|
Loading…
Reference in New Issue
Block a user