Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into internal-package-parsing-support
- Loading branch information
Showing
49 changed files
with
3,559 additions
and
3,143 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 |
---|---|---|
@@ -0,0 +1,14 @@ | ||
FROM ruby:2.6 | ||
|
||
LABEL "com.github.actions.name"="Danger" | ||
LABEL "com.github.actions.description"="Run Danger" | ||
LABEL "com.github.actions.icon"="alert-triangle" | ||
LABEL "com.github.actions.color"="yellow" | ||
|
||
RUN apt-get update -qq && apt-get install -y build-essential p7zip unzip | ||
|
||
RUN gem install danger -v '>= 5.10.3' | ||
RUN gem install danger-checkstyle_format | ||
|
||
ENTRYPOINT "danger" | ||
CMD "--verbose" |
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,9 @@ | ||
workflow "DangerPullRequest" { | ||
on = "pull_request" | ||
resolves = ["Danger"] | ||
} | ||
|
||
action "Danger" { | ||
uses = "pei0804/GithubActions/danger@master" | ||
secrets = ["GITHUB_TOKEN"] | ||
} |
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,40 @@ | ||
on: push | ||
jobs: | ||
test: | ||
strategy: | ||
matrix: | ||
go: [ '1.13.x', '1.14.x' ] | ||
platform: [ubuntu-latest, macos-latest] | ||
runs-on: ${{ matrix.platform }} | ||
steps: | ||
- uses: actions/checkout@master | ||
with: | ||
path: ./src/github.com/${{ github.repository }} | ||
- name: Set up Go | ||
uses: actions/setup-go@v1 | ||
with: | ||
go-version: ${{ matrix.go }} | ||
- name: deps | ||
working-directory: ./src/github.com/${{ github.repository }} | ||
run: make deps | ||
env: | ||
GOPATH: ${{ runner.workspace }} | ||
- name: static program analysis | ||
working-directory: ./src/github.com/${{ github.repository }} | ||
run: | | ||
export PATH=$PATH:$(go env GOPATH)/bin # https://github.com/actions/setup-go/issues/14 | ||
mkdir -p $(go env GOPATH)/src/github.com/swaggo | ||
ln -s $(pwd) $(go env GOPATH)/src/github.com/swaggo/swag | ||
make fmt-check lint vet | ||
env: | ||
GOPATH: ${{ runner.workspace }} | ||
- name: build | ||
run: make build | ||
working-directory: ./src/github.com/${{ github.repository }} | ||
env: | ||
GOPATH: ${{ runner.workspace }} | ||
- name: test | ||
working-directory: ./src/github.com/${{ github.repository }} | ||
run: make test | ||
env: | ||
GOPATH: ${{ runner.workspace }} |
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 |
---|---|---|
|
@@ -15,3 +15,6 @@ cover.out | |
|
||
# Etc | ||
.DS_Store | ||
|
||
swag | ||
swag.exe |
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,10 +1,8 @@ | ||
language: go | ||
sudo: false | ||
|
||
go: | ||
- 1.10.x | ||
- 1.11.x | ||
- 1.12.x | ||
- 1.13.x | ||
- 1.14.x | ||
|
||
install: | ||
- make deps | ||
|
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,29 @@ | ||
# Dockerfile References: https://docs.docker.com/engine/reference/builder/ | ||
|
||
# Start from the latest golang base image | ||
FROM golang:1.14-alpine as builder | ||
|
||
# Set the Current Working Directory inside the container | ||
WORKDIR /app | ||
|
||
# Copy go mod and sum files | ||
COPY go.mod go.sum ./ | ||
|
||
# Download all dependencies. Dependencies will be cached if the go.mod and go.sum files are not changed | ||
RUN go mod download | ||
|
||
# Copy the source from the current directory to the Working Directory inside the container | ||
COPY . . | ||
|
||
# Build the Go app | ||
RUN CGO_ENABLED=0 GOOS=linux go build -v -a -installsuffix cgo -o swag cmd/swag/main.go | ||
|
||
|
||
######## Start a new stage from scratch ####### | ||
FROM scratch | ||
|
||
WORKDIR /root/ | ||
|
||
# Copy the Pre-built binary file from the previous stage | ||
COPY --from=builder /app/swag . | ||
|
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 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
Oops, something went wrong.