Skip to content

Commit

Permalink
comment out unneccassary steps
Browse files Browse the repository at this point in the history
  • Loading branch information
bilalcaliskan committed Jan 3, 2022
1 parent e02bcd2 commit b910054
Show file tree
Hide file tree
Showing 2 changed files with 92 additions and 90 deletions.
181 changes: 92 additions & 89 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,42 +6,42 @@ on:
types: [opened, synchronize, reopened]

jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: 1.16.x
- name: Lint
run: |
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.42.1
make lint
vet:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: 1.16.x
- name: Vet
run: make vet

ineffassign:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: 1.16.x
- name: Lint
run: make ineffassign
# lint:
# runs-on: ubuntu-latest
# steps:
# - name: Checkout
# uses: actions/checkout@v2
# - name: Install Go
# uses: actions/setup-go@v2
# with:
# go-version: 1.16.x
# - name: Lint
# run: |
# curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.42.1
# make lint
# vet:
# runs-on: ubuntu-latest
# steps:
# - name: Checkout
# uses: actions/checkout@v2
# - name: Install Go
# uses: actions/setup-go@v2
# with:
# go-version: 1.16.x
# - name: Vet
# run: make vet
#
# ineffassign:
# runs-on: ubuntu-latest
# steps:
# - name: Checkout
# uses: actions/checkout@v2
# - name: Install Go
# uses: actions/setup-go@v2
# with:
# go-version: 1.16.x
# - name: Lint
# run: make ineffassign

test:
runs-on: ubuntu-latest
Expand All @@ -53,57 +53,60 @@ jobs:
with:
go-version: 1.16.x
- name: Test
run: make test

codeql:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
language: [ 'go' ]
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: ${{ matrix.language }}
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v1
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1

sonarcloud:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: 1.16.x
- name: Coverage Test
run: sudo go test ./... -race -coverprofile=coverage.txt -covermode=atomic
- name: SonarCloud Scan
uses: SonarSource/sonarcloud-github-action@master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
run: |
sh -c "ulimit -Sn 1048576"
sh -c "ulimit -Hn 1048576"
make test
build:
strategy:
matrix:
os: [ ubuntu-latest, macos-latest ]
runs-on: ${{ matrix.os }}
steps:
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: 1.16.x
- name: Checkout code
uses: actions/checkout@v2
- name: Test
run: make build
# codeql:
# runs-on: ubuntu-latest
# strategy:
# fail-fast: false
# matrix:
# language: [ 'go' ]
# steps:
# - name: Checkout code
# uses: actions/checkout@v2
# - name: Initialize CodeQL
# uses: github/codeql-action/init@v1
# with:
# languages: ${{ matrix.language }}
# # Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# # If this step fails, then you should remove it and run the build manually (see below)
# - name: Autobuild
# uses: github/codeql-action/autobuild@v1
# - name: Perform CodeQL Analysis
# uses: github/codeql-action/analyze@v1
#
# sonarcloud:
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v2
# with:
# fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
# - name: Install Go
# uses: actions/setup-go@v2
# with:
# go-version: 1.16.x
# - name: Coverage Test
# run: sudo go test ./... -race -coverprofile=coverage.txt -covermode=atomic
# - name: SonarCloud Scan
# uses: SonarSource/sonarcloud-github-action@master
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
#
# build:
# strategy:
# matrix:
# os: [ ubuntu-latest, macos-latest ]
# runs-on: ${{ matrix.os }}
# steps:
# - name: Install Go
# uses: actions/setup-go@v2
# with:
# go-version: 1.16.x
# - name: Checkout code
# uses: actions/checkout@v2
# - name: Test
# run: make build
1 change: 0 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ test:
sudo sysctl -p
sudo go test ./... -v


build:
go build -o bin/main main.go

Expand Down

0 comments on commit b910054

Please sign in to comment.