Skip to content

Commit

Permalink
Extract common bazelrc to a shared file
Browse files Browse the repository at this point in the history
  • Loading branch information
alexeagle committed May 22, 2019
1 parent 37e058e commit 63d1c04
Show file tree
Hide file tree
Showing 36 changed files with 89 additions and 455 deletions.
16 changes: 2 additions & 14 deletions .bazelrc
Original file line number Diff line number Diff line change
@@ -1,17 +1,5 @@
# Print test logs for failed tests
test --test_output=errors
# Import shared settings first so we can override below
import common.bazelrc

# Mock versioning command to test the --stamp behavior
build --workspace_status_command="echo BUILD_SCM_VERSION 1.2.3"

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
4 changes: 2 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ var_8: &use_legacy_runfiles
run:
name: Use legacy runfiles
command: |
sed -i -e 's/run --nolegacy_external_runfiles//' .bazelrc
sed -i -e 's/test --nolegacy_external_runfiles//' .bazelrc
echo 'run --legacy_external_runfiles' >> .bazelrc
echo 'test --legacy_external_runfiles' >> .bazelrc
var_9: &job_defaults
working_directory: ~/rules_nodejs
Expand Down
16 changes: 16 additions & 0 deletions common.bazelrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Common Bazel settings
# These are imported into the .bazelrc files in each workspace in this repo

# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
16 changes: 2 additions & 14 deletions e2e/bazel_bin/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions e2e/define_var/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions e2e/jasmine/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions e2e/karma/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions e2e/karma_stack_trace/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions e2e/karma_typescript/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions e2e/ts_auto_deps/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import %workspace%/../../common.bazelrc
16 changes: 2 additions & 14 deletions e2e/ts_devserver/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions e2e/ts_library/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions e2e/tsconfig_extends/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions e2e/typescript_2.7/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions e2e/typescript_2.8/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions e2e/typescript_2.9/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions e2e/typescript_3.0/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions e2e/typescript_3.1/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions e2e/webpack/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions examples/app/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions examples/bazel_managed_deps/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
16 changes: 2 additions & 14 deletions examples/parcel/.bazelrc
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
# Print test logs for failed tests
test --test_output=errors

# Enable debugging tests with --config=debug
test:debug --test_arg=--node_options=--inspect-brk --test_output=streamed --test_strategy=exclusive --test_timeout=9999 --nocache_test_results

# Turn off legacy external runfiles
run --nolegacy_external_runfiles
test --nolegacy_external_runfiles

# Turn on managed_directories
build --experimental_allow_incremental_repository_updates
test --experimental_allow_incremental_repository_updates
run --experimental_allow_incremental_repository_updates
# Import shared settings first so we can override below
import ../../common.bazelrc
Loading

0 comments on commit 63d1c04

Please sign in to comment.