Skip to content

Commit

Permalink
Yaml: apply prettier (evcc-io#3023)
Browse files Browse the repository at this point in the history
  • Loading branch information
andig authored Mar 29, 2022
1 parent 7efe7c3 commit cef008f
Show file tree
Hide file tree
Showing 272 changed files with 4,417 additions and 4,562 deletions.
6 changes: 3 additions & 3 deletions .github/issue_label_bot.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
label-alias:
bug: 'bug'
feature_request: 'enhancement'
question: 'question'
bug: "bug"
feature_request: "enhancement"
question: "question"
1 change: 0 additions & 1 deletion .github/stale.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,3 @@ markComment: >
for your contributions.
# Comment to post when closing a stale issue. Set to `false` to disable
closeComment: false

149 changes: 74 additions & 75 deletions .github/workflows/default.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,95 +8,94 @@ on:
workflow_call:

jobs:

build:
name: Build
runs-on: ubuntu-latest

steps:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: ^1.18
id: go

- name: Set up Node
uses: actions/setup-node@v2
with:
node-version: '16'

- name: Cache Go modules
uses: actions/cache@v2
with:
path: |
~/go/pkg
~/.cache/go-build
key: ${{ runner.os }}-${{ matrix.go-version }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-${{ matrix.go-version }}-go-
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0

- name: gofmt
run: |
gofmt -w -l $(find . -name '*.go')
- name: Install tools
run: make install

- name: Assets
run: make assets

- name: Porcelain
run: |
go mod tidy
test -z "$(git status --porcelain)" || (git status; git diff; false)
- name: Build
run: make build

- name: Lint
uses: golangci/golangci-lint-action@v3
with:
version: latest
skip-pkg-cache: true
skip-build-cache: true

- name: Test
run: make test
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: ^1.18
id: go

- name: Set up Node
uses: actions/setup-node@v2
with:
node-version: "16"

- name: Cache Go modules
uses: actions/cache@v2
with:
path: |
~/go/pkg
~/.cache/go-build
key: ${{ runner.os }}-${{ matrix.go-version }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-${{ matrix.go-version }}-go-
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0

- name: gofmt
run: |
gofmt -w -l $(find . -name '*.go')
- name: Install tools
run: make install

- name: Assets
run: make assets

- name: Porcelain
run: |
go mod tidy
test -z "$(git status --porcelain)" || (git status; git diff; false)
- name: Build
run: make build

- name: Lint
uses: golangci/golangci-lint-action@v3
with:
version: latest
skip-pkg-cache: true
skip-build-cache: true

- name: Test
run: make test

build-ui:
name: Build UI
runs-on: ubuntu-latest

steps:
- name: Cache NPM modules
uses: actions/cache@v2
with:
path: |
**/node_modules
key: ${{ runner.os }}-npm-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-npm-
- name: Cache NPM modules
uses: actions/cache@v2
with:
path: |
**/node_modules
key: ${{ runner.os }}-npm-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-npm-
- name: Checkout
uses: actions/checkout@v2
- name: Checkout
uses: actions/checkout@v2

- name: Install tools
run: make install-ui
- name: Install tools
run: make install-ui

- name: Build
run: make ui
- name: Build
run: make ui

- name: Lint
run: make lint-ui
- name: Lint
run: make lint-ui

- name: Test
run: make test-ui
- name: Test
run: make test-ui

- name: Porcelain
run: |
test -z "$(git status --porcelain)" || (git status; git diff; false)
- name: Porcelain
run: |
test -z "$(git status --porcelain)" || (git status; git diff; false)
38 changes: 19 additions & 19 deletions .github/workflows/documentation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,24 +9,24 @@ jobs:
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Clean git
run: |
git checkout go.*
rm -rf flags buildflags
- name: Clean git
run: |
git checkout go.*
rm -rf flags buildflags
- name: Deploy to docs repo
uses: peaceiris/actions-gh-pages@v3
with:
personal_token: ${{ secrets.GH_REPO }}
publish_dir: ./templates/docs
external_repository: evcc-io/docs
publish_branch: main
destination_dir: templates
allow_empty_commit: false
commit_message: Templates update
if: ${{ success() }}
- name: Deploy to docs repo
uses: peaceiris/actions-gh-pages@v3
with:
personal_token: ${{ secrets.GH_REPO }}
publish_dir: ./templates/docs
external_repository: evcc-io/docs
publish_branch: main
destination_dir: templates
allow_empty_commit: false
commit_message: Templates update
if: ${{ success() }}
137 changes: 68 additions & 69 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Nightly Build

on:
schedule: # runs on the default branch: master
- cron: '0 2 * * *' # run at 2 AM UTC
- cron: "0 2 * * *" # run at 2 AM UTC
workflow_dispatch:

jobs:
Expand Down Expand Up @@ -34,84 +34,83 @@ jobs:
docker:
name: Publish Docker :nightly
needs:
- call-build-workflow
- call-build-workflow
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Install
env:
SEIHON_VERSION: v0.9.0
run: curl -sfL https://raw.githubusercontent.com/ldez/seihon/master/godownloader.sh | sudo bash -s -- -b $GOPATH/bin ${SEIHON_VERSION}
- name: Install
env:
SEIHON_VERSION: v0.9.0
run: curl -sfL https://raw.githubusercontent.com/ldez/seihon/master/godownloader.sh | sudo bash -s -- -b $GOPATH/bin ${SEIHON_VERSION}

- name: Login
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKER_PASS }}

- name: Publish
run: make publish-nightly
- name: Login
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKER_PASS }}

- name: Publish
run: make publish-nightly

apt:
name: Publish APT nightly
needs:
- call-build-workflow
- call-build-workflow
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Cache Go modules
uses: actions/cache@v2
with:
path: |
~/go/pkg
~/.cache/go-build
key: ${{ runner.os }}-${{ matrix.go-version }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-${{ matrix.go-version }}-go-
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: ^1.18
id: go

- name: Set up Node
uses: actions/setup-node@v2
with:
node-version: '16'

- name: Install Cloudsmith CLI
run: pip install --upgrade cloudsmith-cli

- name: Clean git
run: |
git checkout go.*
rm -rf flags buildflags
- name: Create nightly build
uses: goreleaser/goreleaser-action@v2
with:
version: latest
args: --snapshot -f .goreleaser-nightly.yml --rm-dist
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Publish .deb to Cloudsmith
env:
CLOUDSMITH_API_KEY: ${{ secrets.CLOUDSMITH_API_KEY }}
run: |
for filename in release/*.deb; do
echo "Pushing $filename to 'unstable'"
cloudsmith push deb evcc/unstable/any-distro/any-version $filename
done
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Cache Go modules
uses: actions/cache@v2
with:
path: |
~/go/pkg
~/.cache/go-build
key: ${{ runner.os }}-${{ matrix.go-version }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-${{ matrix.go-version }}-go-
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: ^1.18
id: go

- name: Set up Node
uses: actions/setup-node@v2
with:
node-version: "16"

- name: Install Cloudsmith CLI
run: pip install --upgrade cloudsmith-cli

- name: Clean git
run: |
git checkout go.*
rm -rf flags buildflags
- name: Create nightly build
uses: goreleaser/goreleaser-action@v2
with:
version: latest
args: --snapshot -f .goreleaser-nightly.yml --rm-dist
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Publish .deb to Cloudsmith
env:
CLOUDSMITH_API_KEY: ${{ secrets.CLOUDSMITH_API_KEY }}
run: |
for filename in release/*.deb; do
echo "Pushing $filename to 'unstable'"
cloudsmith push deb evcc/unstable/any-distro/any-version $filename
done
Loading

0 comments on commit cef008f

Please sign in to comment.