Comparing version 1.3.0 to 1.4.0
13
index.js
@@ -15,7 +15,8 @@ #!/usr/bin/env node | ||
let successGlobalFilesCount = 0; | ||
const outputDir = path.resolve(__dirname, '../../', distFolder); | ||
const outputDir = path.resolve(process.cwd(), distFolder); | ||
compileFolderRecursively(outputDir); | ||
/** | ||
* Compile files in folders recursively | ||
* Compile files in folders recursively. | ||
* | ||
* @param {string} outputDir | ||
@@ -32,3 +33,4 @@ * @param {number} fileCounter | ||
if (fs.lstatSync(fullFilePath).isFile() | ||
&& path.extname(fullFilePath) === '.js') { | ||
&& (path.extname(fullFilePath) === '.js' | ||
|| path.extname(fullFilePath) === '.css')) { | ||
++globalFilesCount; | ||
@@ -54,3 +56,3 @@ | ||
/** | ||
* File compression func | ||
* File compression. | ||
* | ||
@@ -76,3 +78,4 @@ * @param {string} filename | ||
/** | ||
* Custom logger | ||
* Custom logger. | ||
* | ||
* @param {boolean} enable | ||
@@ -79,0 +82,0 @@ * @return {Function} logger function |
{ | ||
"name": "gzipper", | ||
"version": "1.3.0", | ||
"version": "1.4.0", | ||
"description": "Simple gzip script for your files.", | ||
@@ -26,3 +26,3 @@ "main": "index.js", | ||
"devDependencies": { | ||
"eslint": "^4.10.0", | ||
"eslint": "^5.0.1", | ||
"eslint-config-google": "^0.9.1" | ||
@@ -29,0 +29,0 @@ }, |
# gzipper | ||
Simple CLI for gzipping your js files. | ||
Simple CLI for gzipping your js and css files. | ||
## **PLEASE UPDATE TO v1.3.0** | ||
## How to use: | ||
@@ -38,3 +36,3 @@ ### Install globally the package. | ||
### Args | ||
* ```--log``` - enable logging | ||
* ```--log``` - enable logging for each file | ||
@@ -44,3 +42,3 @@ ### Roadmap | ||
- [ ] Unit tests | ||
- [ ] Additional arguments for CLI | ||
- [x] Additional arguments for CLI | ||
- [ ] Your porposal for improvement | ||
@@ -47,0 +45,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
39712
76
48