handlebars-i18n-cli 1.0.3 → 1.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,30 @@
1
+ on: ["push", "pull_request"]
2
+
3
+ name: Test Coveralls
4
+
5
+ jobs:
6
+
7
+ build:
8
+ name: Build
9
+ runs-on: ubuntu-latest
10
+ steps:
11
+
12
+ - uses: actions/checkout@v1
13
+
14
+ - name: Use Node.js 16.x
15
+ uses: actions/setup-node@v3
16
+ with:
17
+ node-version: 16.x
18
+
19
+ - name: npm install, make test-coverage
20
+ run: |
21
+ npm install
22
+ npm test -- --coverage
23
+
24
+ - name: Wait for coverage report
25
+ run: sleep 5
26
+
27
+ - name: Publish to coveralls.io
28
+ uses: coverallsapp/github-action@v1.1.2
29
+ with:
30
+ github-token: ${{ secrets.COVERALLS_REPO_TOKEN }}
@@ -27,5 +27,4 @@ jobs:
27
27
  node-version: ${{ matrix.node-version }}
28
28
  cache: 'npm'
29
29
  - run: npm ci
30
- - run: npm run build --if-present
31
- - run: npm test
30
+ - run: npm run build --if-present
package/.nycrc ADDED
@@ -0,0 +1,14 @@
1
+ {
2
+ "reporter": [
3
+ "text-summary",
4
+ "lcov"
5
+ ],
6
+ "all": true,
7
+ "include": [
8
+ "src/i18n-collect.js"
9
+ ],
10
+ "exclude": [
11
+ "node_modules/**",
12
+ "**/*.test.js"
13
+ ]
14
+ }
package/.travis.yml CHANGED
@@ -9,7 +9,7 @@ install:
9
9
  script:
10
10
  - npm test
11
11
 
12
- after_success: 'npm run coveralls'
12
+ after_success: 'npm run coverage'
13
13
 
14
14
  after_failure:
15
15
  - cat /Users/travis/.npm/_logs/*.log
package/README.md CHANGED
@@ -7,13 +7,9 @@ json files from it. It also helps to keep your translations up to date when chan
7
7
  [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)
8
8
  ![Node.js Version](https://img.shields.io/badge/Node.js-14.x-green)
9
9
  [![Build](https://github.com/fwalzel/handlebars-i18n-cli/actions/workflows/node.js.yml/badge.svg)](https://github.com/fwalzel/handlebars-i18n-cli/actions/workflows/node.js.yml/badge.svg)
10
+ [![Coverage Status](https://coveralls.io/repos/github/fwalzel/handlebars-i18n-cli/badge.svg?branch=main)](https://coveralls.io/github/fwalzel/handlebars-i18n-cli?branch=main)
10
11
  [![Known Vulnerabilities](https://snyk.io/test/github/fwalzel/handlebars-i18n-cli/badge.svg)](https://snyk.io/test/github/fwalzel/handlebars-i18n-cli/badge.svg)
11
12
 
12
- ## License
13
-
14
- Copyright (c) 2022 Florian Walzel,
15
- MIT License
16
-
17
13
 
18
14
  ## Install
19
15
 
@@ -207,7 +203,7 @@ Write each language in a separate json file instead of a single one.
207
203
  $ i18n-collect my-project/template.html my-project/translation.json --lng=de,en,fr --separateLngFiles
208
204
  ```
209
205
 
210
- Will generate three json files: **translation.de.json**, **translation.en.json**, and **translation.en.json** each holding
206
+ Will generate three json files: **translation.de.json**, **translation.en.json**, and **translation.fn.json** each holding
211
207
  only the translation for their respective language. By default all translations are written to a single json file.
212
208
 
213
209
  ---
@@ -265,5 +261,11 @@ sudo npm link
265
261
  ## Run tests
266
262
 
267
263
  ```bash
268
- $ npm test
269
- ```
264
+ $ nyc npm test
265
+ ```
266
+
267
+
268
+ ## License
269
+
270
+ Copyright (c) 2022 Florian Walzel,
271
+ MIT License
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "handlebars-i18n-cli",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "description": "A CLI tool to support node module handlebars-i18n",
5
5
  "main": "./src/i18n-collect.js",
6
6
  "bin": {
@@ -11,8 +11,9 @@
11
11
  "access": "public"
12
12
  },
13
13
  "scripts": {
14
- "test": "nyc mocha",
15
- "coveralls": "istanbul cover ./node_modules/mocha/bin/_mocha --report lcovonly -- -R spec && cat ./coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js && rm -rf ./coverage",
14
+ "test" : "nyc mocha",
15
+ "test:istanbul": "istanbul cover ./node_modules/mocha/bin/_mocha --report lcovonly -- -R spec",
16
+ "coveralls": "npm test && cat ./coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js && rm -rf ./coverage",
16
17
  "i18n-collect": "cd bin && node i18n-collect"
17
18
  },
18
19
  "repository": {