-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
added build for programming languages
- Loading branch information
madhuredra
committed
Sep 23, 2023
1 parent
73e547c
commit 4445701
Showing
7 changed files
with
133 additions
and
74 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,24 @@ | ||
on: pull_request_review | ||
name: Label approved pull requests | ||
name: Add "approved" label when approved | ||
|
||
on: | ||
pull_request_review: | ||
types: | ||
- submitted | ||
|
||
jobs: | ||
labelWhenApproved: | ||
name: Label when approved | ||
add_label: | ||
name: Add "approved" label when approved | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Label when approved | ||
uses: abinoda/label-when-approved-action@1.0.5 | ||
env: | ||
APPROVALS: "2" | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
ADD_LABEL: "approved" | ||
REMOVE_LABEL: "awaiting%20review" | ||
- name: Check for approval | ||
id: check_approval | ||
run: echo "::set-output name=approved::${{ github.event.review.state == 'approved' }}" | ||
|
||
- name: Add "approved" label | ||
if: steps.check_approval.outputs.approved == 'true' | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
echo "Adding 'approved' label" | ||
gh pr edit ${{ github.event.pull_request.number }} --add-label approved |
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
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
# https://github.com/golangci/golangci-lint | ||
name: Continuous Integration | ||
on: | ||
push: | ||
# prevent duplication of tests with | ||
# `pull_request` event | ||
branches: | ||
- main | ||
paths: | ||
- "Golang/**" | ||
- ".github/workflows/goBuild.yml" | ||
|
||
pull_request: | ||
|
||
jobs: | ||
golang_lint_and_test: | ||
name: Code style and tests | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Setup Go | ||
uses: actions/setup-go@v4 | ||
with: | ||
go-version: '^1.18' | ||
- name: Run Golang CI Lint | ||
uses: golangci/golangci-lint-action@v3 | ||
with: | ||
version: latest | ||
args: -E gofmt | ||
- name: Run tests | ||
run: go test ./... | ||
codespell: | ||
name: Check for spelling errors | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: codespell-project/actions-codespell@master | ||
with: | ||
ignore_words_list: "actualy,nwe" | ||
skip: "go.mod,go.sum" |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
name: Clang format linter | ||
|
||
on: | ||
push: | ||
paths: | ||
- 'Java/**' # This restricts the workflow to changes in the 'Java' folder | ||
- '.github/workflows/javaBuild.yml' | ||
pull_request: | ||
paths: | ||
- 'Java/**' # This restricts the workflow to changes in the 'Java' folder | ||
- '.github/workflows/javaBuild.yml' | ||
|
||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: DoozyX/clang-format-lint-action@v0.16.2 | ||
with: | ||
source: './src' | ||
extensions: 'java' | ||
clangFormatVersion: 16 |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,51 @@ | ||
name: Build | ||
name: Continuous Integration | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- "JavaScript/**" | ||
- ".github/workflows/jsBuild.yml" | ||
- 'JavaScript/**' # Include the JavaScript folder and its subdirectories | ||
- 'TypeScript/**' # Include the TypeScript folder and its subdirectories | ||
- '.github/workflows/jsBuild.yml' | ||
pull_request: | ||
types: [opened, synchronize, reopened] | ||
paths: | ||
- 'JavaScript/**' # Include the JavaScript folder and its subdirectories | ||
- 'TypeScript/**' # Include the TypeScript folder and its subdirectories | ||
- '.github/workflows/jsBuild.yml' | ||
|
||
|
||
jobs: | ||
sonarcloud: | ||
name: SonarCloud | ||
build: | ||
name: Code style and tests | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: 16 | ||
cache: npm | ||
|
||
- name: 📦 Install dependencies | ||
run: npm ci | ||
|
||
- name: 🧪 Run all tests | ||
if: ${{ github.event_name == 'push' }} | ||
run: npm run test | ||
|
||
- name: 🧪 Run tests for changed files only | ||
if: ${{ github.event_name == 'pull_request' }} | ||
run: npm run test-changed | ||
|
||
- name: 💄 Code style | ||
run: npm run style | ||
|
||
codespell: | ||
name: Check for spelling errors | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: codespell-project/actions-codespell@master | ||
with: | ||
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis | ||
- name: SonarCloud Scan | ||
uses: SonarSource/sonarcloud-github-action@master | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any | ||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | ||
# file types to ignore | ||
skip: "*.json,*.yml,DIRECTORY.md" | ||
ignore_words_list: "ba,esy,yse,falsy" |
This file was deleted.
Oops, something went wrong.