Skip to content
This repository has been archived by the owner on Oct 26, 2023. It is now read-only.

Commit

Permalink
release v0.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael M committed Feb 16, 2022
2 parents 884fc92 + b3f3367 commit 41572f2
Show file tree
Hide file tree
Showing 38 changed files with 18,626 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Editor configuration, see https://editorconfig.org
root = true

[*]
charset = utf-8
indent_style = space
indent_size = 4
insert_final_newline = true
trim_trailing_whitespace = true

[*.{js,ts}]
quote_type = single

[*.md]
max_line_length = off
trim_trailing_whitespace = false

[*.html]
indent_size = 2
quote_type = double

[*.json]
indent_size = 2
3 changes: 3 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
/dist
/coverage
/node_modules
36 changes: 36 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{
"root": true,
"ignorePatterns": ["**/*"],
"plugins": ["@nrwl/nx"],
"overrides": [
{
"files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
"extends": ["custom/imports"],
"rules": {
"@nrwl/nx/enforce-module-boundaries": [
"error",
{
"enforceBuildableLibDependency": true,
"allow": [],
"depConstraints": [
{
"sourceTag": "*",
"onlyDependOnLibsWithTags": ["*"]
}
]
}
]
}
},
{
"files": ["*.ts", "*.tsx"],
"extends": ["plugin:@nrwl/nx/typescript"],
"rules": {}
},
{
"files": ["*.js", "*.jsx"],
"extends": ["plugin:@nrwl/nx/javascript"],
"rules": {}
}
]
}
62 changes: 62 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
name: Build

on:
push:
branches: [ dev, main ]
pull_request:
branches: [ dev, main ]

jobs:

build:
name: Build/Coverage
runs-on: ubuntu-latest
steps:
- name: Checkout commit
uses: actions/checkout@v2

- name: Setup node
uses: actions/setup-node@v1
with:
node-version: 12

- name: Get npm cache path
id: npm-cache-path
run: echo "::set-output name=path::$(npm config get cache)"
- name: Check for npm cache
uses: actions/cache@v2
id: npm-cache
with:
path: ${{ steps.npm-cache-path.outputs.path }}
key: ${{ runner.os }}-npm-${{ hashFiles('package-lock.json') }}

- name: Clean install node modules (if no cache)
if: steps.npm-cache.outputs.cache-hit != 'true'
run: npm ci
- name: Install node modules (cached)
if: steps.npm-cache.outputs.cache-hit == 'true'
run: npm i

- name: Build project
run: npx nx build keep-updated

- name: Test & coverage
run: npx nx test keep-updated --codeCoverage --coverageReporters=lcov

- name: Report to Codacy
uses: codacy/codacy-coverage-reporter-action@master
with:
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}
coverage-reports: 'coverage/packages/*/lcov.info'
- name: Report to Code Climate
uses: paambaati/codeclimate-action@v2.7.5
env:
CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }}
with:
coverageLocations: ${{ github.workspace }}/coverage/packages/*/lcov.info:lcov
# - name: Report to Codecov
# uses: codecov/codecov-action@v1
# with:
# token: ${{ secrets.CODECOV_TOKEN }}
# files: ./coverage/cobertura-coverage.xml
# flags: dev,jasmine
70 changes: 70 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
name: Deploy

on:
release:
types: [ published ]

jobs:

deploy:
name: Build/Coverage/Publish
runs-on: ubuntu-latest
steps:
- name: Checkout commit
uses: actions/checkout@v2

- name: Setup node
uses: actions/setup-node@v1
with:
node-version: 12
registry-url: 'https://registry.npmjs.org'

- name: Get npm cache path
id: npm-cache-path
run: echo "::set-output name=path::$(npm config get cache)"
- name: Check for npm cache
uses: actions/cache@v2
id: npm-cache
with:
path: ${{ steps.npm-cache-path.outputs.path }}
key: ${{ runner.os }}-npm-${{ hashFiles('package-lock.json') }}

- name: Clean install node modules (if no cache)
if: steps.npm-cache.outputs.cache-hit != 'true'
run: npm ci
- name: Install node modules (cached)
if: steps.npm-cache.outputs.cache-hit == 'true'
run: npm i

- name: Build project
run: npx nx build keep-updated

- name: Test & coverage
run: npx nx test keep-updated --codeCoverage --coverageReporters=lcov

- name: Report to Codacy
uses: codacy/codacy-coverage-reporter-action@master
with:
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}
coverage-reports: 'coverage/packages/*/lcov.info'
- name: Report to Code Climate
uses: paambaati/codeclimate-action@v2.7.5
env:
CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }}
with:
coverageLocations: ${{ github.workspace }}/coverage/packages/*/lcov.info:lcov
# - name: Report to Codecov
# uses: codecov/codecov-action@v1
# with:
# token: ${{ secrets.CODECOV_TOKEN }}
# files: ./coverage/cobertura-coverage.xml
# flags: release,jasmine

- name: Publish to NPM (dry-run)
run: npx nx publish keep-updated --dry-run
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Publish to NPM
run: npx nx publish keep-updated
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
41 changes: 41 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# See https://help.github.com/ignore-files/ for more about ignoring files.

# compiled output
/dist
/tmp
/out-tsc

# dependencies
/node_modules

# IDEs and editors
/.idea
.project
.classpath
.c9/
*.launch
.settings/
*.sublime-workspace

# IDE - VSCode
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json

# misc
/.sass-cache
/connect.lock
/coverage
/libpeerconnection.log
npm-debug.log
yarn-error.log
testem.log
/typings

# System Files
.DS_Store
Thumbs.db

.angular
4 changes: 4 additions & 0 deletions .husky/commit-msg
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npx --no -- commitlint --edit $1
4 changes: 4 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npx lint-staged --concurrent false
5 changes: 5 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Add files here to ignore them from prettier formatting

/dist
/coverage
/node_modules
32 changes: 32 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"arrow-body-style": "off",
"prefer-arrow-callback": "off",
"printWidth": 120,
"semi": true,
"singleQuote": true,
"tabWidth": 4,
"trailingComma": "all",
"useTabs": false,
"overrides": [
{
"files": "*.html",
"options": {
"parser": "html",
"singleQuote": false
}
},
{
"files": "*.ts",
"options": {
"parser": "typescript"
}
},
{
"files": "*.json",
"options": {
"singleQuote": false,
"tabWidth": 2
}
}
]
}
3 changes: 3 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
### Code of Conduct

Please see [Public JS](https://github.com/public-js/public-js/blob/master/CODE_OF_CONDUCT.md) for Code of Conduct.
3 changes: 3 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
### Contributing to Public JS

Please see [Public JS](https://github.com/public-js/public-js/blob/master/CONTRIBUTING.md) for Contributing guidelines.
14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# @public-js/keep-updated

[![Version](https://img.shields.io/npm/v/@public-js/keep-updated?style=flat)](https://www.npmjs.com/package/@public-js/keep-updated)
[![CI](https://github.com/public-js/keep-updated/actions/workflows/build.yml/badge.svg?branch=main)](https://github.com/public-js/keep-updated/actions/workflows/build.yml)
[![License](https://img.shields.io/npm/l/@public-js/keep-updated?style=flat)](https://www.npmjs.com/package/@public-js/keep-updated)

[![Codacy Badge](https://app.codacy.com/project/badge/Grade/fd9ab5088d3442af87a0f335688094fe)](https://www.codacy.com/gh/public-js/keep-updated/dashboard)
[![Language grade: JavaScript](https://img.shields.io/lgtm/grade/javascript/g/public-js/keep-updated.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/public-js/keep-updated/context:javascript)
[![codecov](https://codecov.io/gh/public-js/keep-updated/branch/main/graph/badge.svg?token=BbVsomZtwx)](https://codecov.io/gh/public-js/keep-updated)
[![Maintainability](https://api.codeclimate.com/v1/badges/5d950db51954705b1ca3/maintainability)](https://codeclimate.com/github/public-js/keep-updated/maintainability)

---

TODO: add project description
1 change: 1 addition & 0 deletions commitlint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
module.exports = { extends: ['@commitlint/config-conventional'] };
5 changes: 5 additions & 0 deletions jest.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
const { getJestProjects } = require('@nrwl/jest');

module.exports = {
projects: getJestProjects(),
};
3 changes: 3 additions & 0 deletions jest.preset.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
const nxPreset = require('@nrwl/jest/preset');

module.exports = { ...nxPreset };
19 changes: 19 additions & 0 deletions nx.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"extends": "@nrwl/workspace/presets/core.json",
"npmScope": "public-js",
"affected": {
"defaultBase": "main"
},
"cli": {
"defaultCollection": "@nrwl/workspace"
},
"tasksRunnerOptions": {
"default": {
"runner": "@nrwl/nx-cloud",
"options": {
"cacheableOperations": ["build", "lint", "test", "e2e"],
"accessToken": "ZGVkNzFmZDgtMWM0Yi00YTdlLThjYzItODQzNjBiZDdkOGE5fHJlYWQtd3JpdGU="
}
}
}
}
Loading

0 comments on commit 41572f2

Please sign in to comment.