Skip to content

Commit

Permalink
Code consistency using prettier (#73)
Browse files Browse the repository at this point in the history
* updated action with node16

* Code consistency using prettier

* Added workflow for prettify

* updated prettify workflow

* updated the prettier workflow

* updated the prettier workflow

* Enforce prettier

* code fix

* code fix
  • Loading branch information
Vidya2606 authored Jun 27, 2022
1 parent b6860ae commit 4d245b6
Show file tree
Hide file tree
Showing 18 changed files with 11,350 additions and 11,267 deletions.
6 changes: 2 additions & 4 deletions .github/ISSUE_TEMPLATE/bug-report-feature-request.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
name: Bug Report / Feature Request
about: Create a report to help us improve
title: ""
title: ''
labels: need-to-triage
assignees: "@Azure/aks-atlanta"
assignees: '@Azure/aks-atlanta'
---


48 changes: 24 additions & 24 deletions .github/workflows/defaultLabels.yml
Original file line number Diff line number Diff line change
@@ -1,30 +1,30 @@
name: setting-default-labels

on:
schedule:
- cron: "0 0/3 * * *"
schedule:
- cron: '0 0/3 * * *'

jobs:
label-issues:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3
name: Setting issue as idle
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-issue-message: "This issue is idle because it has been open for 14 days with no activity."
stale-issue-label: "idle"
days-before-stale: 14
days-before-close: -1
operations-per-run: 100
exempt-issue-labels: "backlog"
label-issues:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3
name: Setting issue as idle
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-issue-message: 'This issue is idle because it has been open for 14 days with no activity.'
stale-issue-label: 'idle'
days-before-stale: 14
days-before-close: -1
operations-per-run: 100
exempt-issue-labels: 'backlog'

- uses: actions/stale@v3
name: Setting PR as idle
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-pr-message: "This PR is idle because it has been open for 14 days with no activity."
stale-pr-label: "idle"
days-before-stale: 14
days-before-close: -1
operations-per-run: 100
- uses: actions/stale@v3
name: Setting PR as idle
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-pr-message: 'This PR is idle because it has been open for 14 days with no activity.'
stale-pr-label: 'idle'
days-before-stale: 14
days-before-close: -1
operations-per-run: 100
18 changes: 18 additions & 0 deletions .github/workflows/prettify-code.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: 'Run prettify'
on:
pull_request:
push:
branches: [main]

jobs:
prettier:
name: Prettier Check
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v2

- name: Enforce Prettier
uses: actionsx/prettier@v2
with:
args: --check .
18 changes: 9 additions & 9 deletions .github/workflows/release-pr.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
name: Create release PR

on:
workflow_dispatch:
inputs:
release:
description: "Define release version (ex: v1, v2, v3)"
required: true
workflow_dispatch:
inputs:
release:
description: 'Define release version (ex: v1, v2, v3)'
required: true

jobs:
release-pr:
uses: OliverMKing/javascript-release-workflow/.github/workflows/release-pr.yml@main
with:
release: ${{ github.event.inputs.release }}
release-pr:
uses: OliverMKing/javascript-release-workflow/.github/workflows/release-pr.yml@main
with:
release: ${{ github.event.inputs.release }}
10 changes: 5 additions & 5 deletions .github/workflows/tag-and-draft.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
name: Tag and create release draft

on:
push:
branches:
- releases/*
push:
branches:
- releases/*

jobs:
tag-and-release:
uses: OliverMKing/javascript-release-workflow/.github/workflows/tag-and-release.yml@main
tag-and-release:
uses: OliverMKing/javascript-release-workflow/.github/workflows/tag-and-release.yml@main
34 changes: 17 additions & 17 deletions .github/workflows/unit-tests.yml
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
name: "Run L0 tests."
name: 'Run L0 tests.'
on: # rebuild any PRs and main branch changes
pull_request:
branches:
- main
- "releases/*"
push:
branches:
- main
- "releases/*"
pull_request:
branches:
- main
- 'releases/*'
push:
branches:
- main
- 'releases/*'

jobs:
build: # make sure build/ci works properly
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
build: # make sure build/ci works properly
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1

- name: Run unit tests
run: |
npm install
npm test
- name: Run unit tests
run: |
npm install
npm test
3 changes: 3 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# dependencies
/node_modules
coverage
8 changes: 8 additions & 0 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"trailingComma": "none",
"bracketSpacing": false,
"semi": false,
"tabWidth": 3,
"singleQuote": true,
"printWidth": 80
}
18 changes: 9 additions & 9 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# Microsoft Open Source Code of Conduct

This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).

Resources:

- [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/)
- [Microsoft Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/)
- Contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with questions or concerns
# Microsoft Open Source Code of Conduct

This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).

Resources:

- [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/)
- [Microsoft Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/)
- Contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with questions or concerns
Loading

0 comments on commit 4d245b6

Please sign in to comment.