Skip to content

Commit

Permalink
Merge pull request #9 from PelionIoT/clean-up-gitconfig
Browse files Browse the repository at this point in the history
Remove .gitconfig, upgrade actions
  • Loading branch information
JanneKiiskila authored Apr 4, 2024
2 parents 0cbfc38 + 3773054 commit 653d97e
Showing 1 changed file with 18 additions and 12 deletions.
30 changes: 18 additions & 12 deletions .github/workflows/PR-checker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,37 +19,43 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Set up golang
uses: actions/setup-go@v3
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.golang-ver }}
- name: Golang version
run: go version
- name: Set GitHub access token via git config
run: |
git config --global url."https://${{ secrets.ACCESS_TOKEN }}@github.com/".insteadOf "[email protected]:"
git config --global url."https://${{ secrets.ACCESS_TOKEN }}@github".insteadOf "https://github"
- name: Set access token for internal repo access
uses: PelionIoT/actions/.github/actions/git-config@main
with:
github_token: ${{ secrets.ACCESS_TOKEN }}
- run: sudo apt install golint
- run: git clone [email protected]:PelionIoT/scripts-internal.git
- name: Build all
run: scripts-internal/golang/go_build_script.sh --all
- name: Run make.sh test (go vet + go test)
run: ./make.sh test
- name: Cleanup .gitconfig
if: always()
run: rm -f ~/.gitconfig

pysh-check:
runs-on: ubuntu-latest
steps:
- name: Set GitHub access token via git config
run: |
git config --global url."https://${{ secrets.ACCESS_TOKEN }}@github.com/".insteadOf "[email protected]:"
git config --global url."https://${{ secrets.ACCESS_TOKEN }}@github".insteadOf "https://github"
- name: Set access token for internal repo access
uses: PelionIoT/actions/.github/actions/git-config@main
with:
github_token: ${{ secrets.ACCESS_TOKEN }}
- name: Check out code
uses: actions/checkout@v3
uses: actions/checkout@v4
- run: git clone [email protected]:PelionIoT/scripts-internal.git
- name: Run pysh-check
run: |
sudo apt install pycodestyle pydocstyle black
echo "." >scripts-internal/.nopyshcheck
echo "." >vendor/.nopyshcheck
scripts-internal/pysh-check/pysh-check.sh --workdir .
scripts-internal/pysh-check/pysh-check.sh --workdir .
- name: Cleanup .gitconfig
if: always()
run: rm -f ~/.gitconfig

0 comments on commit 653d97e

Please sign in to comment.