Skip to content

Commit

Permalink
refactor for main branch
Browse files Browse the repository at this point in the history
  • Loading branch information
kaihendry committed Sep 20, 2024
1 parent 301f021 commit f68ee6f
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 17 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/gosec.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
name: Run Gosec
name: Run security checks
on:
push:
branches:
- master
- main
pull_request:
branches:
- master
- main
jobs:
tests:
runs-on: ubuntu-latest
Expand Down
14 changes: 2 additions & 12 deletions .github/workflows/sam-pipeline.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
on:
workflow_dispatch:
push:
branches: [master]
branches: [main]
permissions:
id-token: write
contents: read
Expand All @@ -15,8 +15,7 @@ jobs:
check-latest: true
go-version: 'stable'
- uses: golangci/golangci-lint-action@v4
- name: Test
run: go test -v .
- run: go test -v .
- uses: aws-actions/setup-sam@v2
with:
use-installer: true
Expand All @@ -30,12 +29,3 @@ jobs:
ACCOUNTKEY: ${{ secrets.ACCOUNTKEY }}
- run: git status
- run: make deploy
- name: Get the lines of code.
id: scc
uses: Adapt-API/scc-docker-action@master
with:
args: ${{ env.workspace }} -i js,go,html,css
- name: Echo scc output
run: |
echo
echo -n "${{ steps.scc.outputs.scc }}"
2 changes: 1 addition & 1 deletion .github/workflows/sloc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Create a Less Hero SLOC chart
on:
push:
branches:
- master
- main
workflow_dispatch:

# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
Expand Down
1 change: 0 additions & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,6 @@ func (p Point) distance(p2 Point) float64 {
return latd*latd + lngd*lngd
}

// Inspired by shttps://github.com/spotlightpa/almanack/blob/master/pkg/almlog/middleware.go
func logRequest(next http.Handler) http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
start := time.Now()
Expand Down

0 comments on commit f68ee6f

Please sign in to comment.