Skip to content

Commit

Permalink
update cicd (facebookincubator#7)
Browse files Browse the repository at this point in the history
  • Loading branch information
YantingTao1315 authored and ZJie1 committed Oct 18, 2022
1 parent bc8e382 commit 56905c1
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 16 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,11 @@ name: build and test
on:
push:
branches:
- BDTK
- WW*
pull_request:
branches:
- developer
- BDTK
- WW*

jobs:
Expand All @@ -40,13 +41,12 @@ jobs:
- name: Build
run: |
make release NUM_THREADS=16 MAX_HIGH_MEM_JOBS=8 MAX_LINK_JOBS=8
make release NUM_THREADS=32 MAX_HIGH_MEM_JOBS=16 MAX_LINK_JOBS=16
- name: Run Unit Tests
run: |
cd _build/release && ctest -j 16
cd _build/release && ctest -j 32
# cd _build/release && ctest -j 16 -VV --output-on-failure
- name: Run Fuzzer Tests
run: |
_build/release/velox/expression/tests/velox_expression_fuzzer_test --seed 123456 --duration_sec 60 --logtostderr=1 --minloglevel=0
Expand Down
6 changes: 2 additions & 4 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,11 @@ name: check
on:
push:
branches:
- BDTK
- WW*
pull_request:
branches:
- developer
- BDTK
- WW*


Expand All @@ -39,9 +40,6 @@ jobs:
- name: format-check
if: ${{github.event.pull_request.base.ref}}
run: |
ls
pwd
echo ${{github.event.pull_request.base.ref}}
if ! make format-check BRANCH=${{github.event.pull_request.base.ref}}; then
make format-fix BRANCH=${{github.event.pull_request.base.ref}}
echo -e "\n==== Apply using:"
Expand Down
10 changes: 5 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ CPU_TARGET ?= "avx"
FUZZER_SEED ?= 123456
FUZZER_DURATION_SEC ?= 60

BRANCH ?= "developer"
BRANCH ?= "BDTK"

all: release #: Build the release version

Expand Down Expand Up @@ -113,20 +113,20 @@ fuzzertest: debug
--logtostderr=1 \
--minloglevel=0

format-fix: #: Fix formatting issues in the specified branch, default main
format-fix: #: Fix formatting issues in the specified branch, default BDTK
@echo "format-fix base branch is : $(BRANCH)"
scripts/check.py format $(BRANCH) --fix

format-check: #: Check for formatting issues on the specified branch, default main
format-check: #: Check for formatting issues on the specified branch, default BDTK
clang-format --version
@echo "format-check base branch is : $(BRANCH)"
scripts/check.py format $(BRANCH)

header-fix: #: Fix license header issues in the specified branch, default main
header-fix: #: Fix license header issues in the specified branch, default BDTK
@echo "header-fix base branch is : $(BRANCH)"
scripts/check.py header $(BRANCH) --fix

header-check: #: Check for license header issues on the specified branch, default main
header-check: #: Check for license header issues on the specified branch, default BDTK
@echo "header-check base branch is : $(BRANCH)"
scripts/check.py header $(BRANCH)

Expand Down
11 changes: 8 additions & 3 deletions scripts/check.py
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,12 @@ def get_commit(files):
if files == "commit":
return "HEAD^"

if files == "main" or files == "master" or files.startswith("WW"):
if (
files == "main"
or files == "master"
or files == "BDTK"
or files.startswith("WW")
):
return util.run(f"git merge-base origin/{files} HEAD")[1]

return ""
Expand Down Expand Up @@ -224,9 +229,9 @@ def add_options(parser):

branch_parser = add_check_options(files, "main")
branch_parser = add_check_options(files, "master")
for week_num in range(30, 100):
for week_num in range(1, 60):
branch_parser = add_check_options(files, f"WW{week_num}")
branch_parser = add_check_options(files, "deceloper")
branch_parser = add_check_options(files, "BDTK")
commit_parser = add_check_options(files, "commit")


Expand Down

0 comments on commit 56905c1

Please sign in to comment.