Skip to content

Commit

Permalink
Bump dependencies by "Check updates #6" (#13)
Browse files Browse the repository at this point in the history
* Bump dependencies by "Check updates #6"

* Bump snyk

* Fix typos in README

Co-authored-by: fabasoad <[email protected]>
Co-authored-by: fabasoad <[email protected]>
  • Loading branch information
3 people authored Feb 20, 2021
1 parent 0ad4cff commit 90d2e19
Show file tree
Hide file tree
Showing 11 changed files with 719 additions and 602 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/check-updates.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Check updates

on:
schedule:
- cron: '0 0 1,15 * *'
- cron: '0 0 1 * *'

env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: true
Expand Down
108 changes: 0 additions & 108 deletions .github/workflows/ci-main.yml

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,52 +1,28 @@
---
name: CI (latest)
name: Functional Tests

on:
push:
tags:
- 'v*.*.*'
branches:
- main
- 'bugfix/**'
- 'feature/**'

env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: true

jobs:
unit_tests:
name: Unit tests
timeout-minutes: 5
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
with:
ref: ${{ github.ref }}
- name: Cache node_modules
id: yarn-cache
uses: actions/[email protected]
with:
path: '**/node_modules'
key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Compile
if: ${{ steps.yarn-cache.outputs.cache-hit != 'true' }}
run: yarn install
- name: Lint
run: yarn run lint
- name: Security tests
run: |
yarn run security:auth ${{ secrets.SNYK_API_TOKEN }}
yarn run security:test
- name: Unit tests
run: yarn run test
functional_tests:
name: Functional tests
name: Translate
timeout-minutes: 5
runs-on: ubuntu-latest
strategy:
matrix:
source: ['Performance']
fail-fast: false
steps:
- uses: fabasoad/translation-action@main
- uses: actions/[email protected]
- uses: ./
id: linguatools
with:
provider: linguatools
Expand All @@ -57,7 +33,7 @@ jobs:
echo "'${{ matrix.source }}' has been translated to '${{ steps.linguatools.outputs.text }}'"
[[ "${{ steps.linguatools.outputs.text }}" == "Leistung" ]] || exit 1;
shell: bash
- uses: fabasoad/translation-action@main
- uses: ./
id: mymemory_free
with:
provider: mymemory
Expand All @@ -68,7 +44,7 @@ jobs:
echo "'${{ matrix.source }}' has been translated to '${{ steps.mymemory_free.outputs.text }}'"
[[ "${{ steps.mymemory_free.outputs.text }}" == "Live performance" ]] || exit 1;
shell: bash
- uses: fabasoad/translation-action@main
- uses: ./
id: mymemory_registered
with:
provider: mymemory
Expand All @@ -80,7 +56,7 @@ jobs:
echo "'${{ matrix.source }}' has been translated to '${{ steps.mymemory_registered.outputs.text }}'"
[[ "${{ steps.mymemory_registered.outputs.text }}" == "Elevate" ]] || exit 1;
shell: bash
- uses: fabasoad/translation-action@main
- uses: ./
id: funtranslations
with:
provider: funtranslations
Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,28 @@
---
name: CodeQL
name: Security Tests

on:
push:
branches:
- main
- 'bugfix/**'
- 'feature/**'
schedule:
- cron: '25 2 * * 6'

jobs:
analyze:
name: Analyze
snyk_tests:
name: Snyk
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
with:
ref: ${{ github.ref }}
- uses: snyk/actions/node@master
env:
SNYK_TOKEN: ${{ secrets.SNYK_API_TOKEN }}
codeql_tests:
name: CodeQL
runs-on: ubuntu-latest
strategy:
fail-fast: false
Expand Down
44 changes: 44 additions & 0 deletions .github/workflows/unit-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
---
name: Unit Tests

on:
push:
branches:
- main
- 'bugfix/**'
- 'feature/**'

env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: true

jobs:
unit_tests:
name: Lint and Test
timeout-minutes: 5
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
- name: Cache node_modules
id: cache
uses: actions/[email protected]
with:
path: '**/node_modules'
key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Compile
if: ${{ steps.cache.outputs.cache-hit != 'true' }}
run: yarn install
- name: Lint
run: yarn run lint
- name: Unit tests
run: yarn test
if: github.ref != 'refs/heads/main'
- name: Unit tests with coverage
uses: paambaati/[email protected]
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
env:
CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }}
with:
coverageCommand: yarn test
debug: true
2 changes: 1 addition & 1 deletion .husky/.gitignore
Original file line number Diff line number Diff line change
@@ -1 +1 @@
_
_
2 changes: 2 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,15 @@
},
"cSpell.words": [
"Abend",
"Autobuild",
"Khru",
"Leistung",
"Noite",
"UNSECURE",
"apim",
"camelcase",
"canadacentral",
"codeql",
"funtranslations",
"issuehunt",
"lcov",
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Translation action

![GitHub release (latest SemVer including pre-releases)](https://img.shields.io/github/v/release/fabasoad/translation-action?include_prereleases) ![CI (latest)](https://github.com/fabasoad/translation-action/workflows/CI%20(latest)/badge.svg) ![CI (main)](https://github.com/fabasoad/translation-action/workflows/CI%20(main)/badge.svg) ![CodeQL](https://github.com/fabasoad/translation-action/workflows/CodeQL/badge.svg) ![YAML Lint](https://github.com/fabasoad/translation-action/workflows/YAML%20Lint/badge.svg) [![Total alerts](https://img.shields.io/lgtm/alerts/g/fabasoad/translation-action.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/fabasoad/translation-action/alerts/) [![Language grade: JavaScript](https://img.shields.io/lgtm/grade/javascript/g/fabasoad/translation-action.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/fabasoad/translation-action/context:javascript) [![Maintainability](https://api.codeclimate.com/v1/badges/84bb3beceb9503272bc9/maintainability)](https://codeclimate.com/github/fabasoad/translation-action/maintainability) [![Test Coverage](https://api.codeclimate.com/v1/badges/84bb3beceb9503272bc9/test_coverage)](https://codeclimate.com/github/fabasoad/translation-action/test_coverage) [![Known Vulnerabilities](https://snyk.io/test/github/fabasoad/translation-action/badge.svg?targetFile=package.json)](https://snyk.io/test/github/fabasoad/translation-action?targetFile=package.json)
![GitHub release (latest SemVer including pre-releases)](https://img.shields.io/github/v/release/fabasoad/translation-action?include_prereleases) ![Unit Tests](https://github.com/fabasoad/translation-action/workflows/Unit%20Tests/badge.svg) ![Functional Tests](https://github.com/fabasoad/translation-action/workflows/Functional%20Tests/badge.svg) ![YAML Lint](https://github.com/fabasoad/translation-action/workflows/YAML%20Lint/badge.svg) ![Security Tests](https://github.com/fabasoad/translation-action/workflows/Security%20Tests/badge.svg) [![Total alerts](https://img.shields.io/lgtm/alerts/g/fabasoad/translation-action.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/fabasoad/translation-action/alerts/) [![Language grade: JavaScript](https://img.shields.io/lgtm/grade/javascript/g/fabasoad/translation-action.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/fabasoad/translation-action/context:javascript) [![Maintainability](https://api.codeclimate.com/v1/badges/84bb3beceb9503272bc9/maintainability)](https://codeclimate.com/github/fabasoad/translation-action/maintainability) [![Test Coverage](https://api.codeclimate.com/v1/badges/84bb3beceb9503272bc9/test_coverage)](https://codeclimate.com/github/fabasoad/translation-action/test_coverage) [![Known Vulnerabilities](https://snyk.io/test/github/fabasoad/translation-action/badge.svg?targetFile=package.json)](https://snyk.io/test/github/fabasoad/translation-action?targetFile=package.json)

This action translates any text to any language supported by chosen provider. There is a list of providers that can be used for text translation. Please find more details for each provider below.

Expand Down
2 changes: 1 addition & 1 deletion dist/index.js

Large diffs are not rendered by default.

16 changes: 8 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "translation-action",
"version": "1.4.6",
"version": "1.4.7",
"description": "This GitHub action translates any text from any language to any language.",
"main": "dist/index.js",
"scripts": {
Expand Down Expand Up @@ -39,22 +39,22 @@
"devDependencies": {
"@types/jest": "26.0.20",
"@types/node-fetch": "2.5.8",
"@typescript-eslint/eslint-plugin": "4.14.1",
"@typescript-eslint/parser": "4.14.1",
"@typescript-eslint/eslint-plugin": "4.15.1",
"@typescript-eslint/parser": "4.15.1",
"@vercel/ncc": "0.27.0",
"dotenv": "8.2.0",
"eslint": "7.19.0",
"eslint": "7.20.0",
"eslint-config-google": "0.14.0",
"git-branch-is": "4.0.0",
"husky": "5.0.6",
"husky": "5.0.9",
"jest": "26.6.3",
"jest-circus": "26.6.3",
"markdownlint-cli": "0.26.0",
"mocha-param": "2.0.1",
"nyc": "15.1.0",
"snyk": "1.440.1",
"ts-jest": "26.5.0",
"typescript": "4.1.3"
"snyk": "1.458.0",
"ts-jest": "26.5.1",
"typescript": "4.1.5"
},
"snyk": true
}
Loading

0 comments on commit 90d2e19

Please sign in to comment.