diff --git a/.ci/.azure-pipelines-steps.yml b/.ci/.azure-pipelines-steps.yml index 894c21e..b54ea9b 100644 --- a/.ci/.azure-pipelines-steps.yml +++ b/.ci/.azure-pipelines-steps.yml @@ -1,8 +1,4 @@ steps: -- script: npm i -g npm@$(npm_version) - displayName: Use legacy npm version $(npm_version) - condition: ne(variables['npm_version'], '') - - task: NodeTool@0 inputs: versionSpec: '$(node_version)' diff --git a/.ci/.azure-pipelines.yml b/.ci/.azure-pipelines.yml index dcdd68e..9294859 100644 --- a/.ci/.azure-pipelines.yml +++ b/.ci/.azure-pipelines.yml @@ -15,12 +15,6 @@ jobs: node_version: 8 Node_v6: node_version: 6 - Node_v4: - node_version: 4 - Node_v0_12: - node_version: 0.12 - Node_v0_10: - node_version: 0.10 steps: - template: .azure-pipelines-steps.yml @@ -36,15 +30,6 @@ jobs: node_version: 8 Node_v6: node_version: 6 - Node_v4: - node_version: 4 - npm_version: 2 - Node_v0_12: - node_version: 0.12 - npm_version: 2 - Node_v0_10: - node_version: 0.10 - npm_version: 2 steps: - template: .azure-pipelines-steps.yml @@ -60,12 +45,6 @@ jobs: node_version: 8 Node_v6: node_version: 6 - Node_v4: - node_version: 4 - Node_v0_12: - node_version: 0.12 - Node_v0_10: - node_version: 0.10 steps: - template: .azure-pipelines-steps.yml diff --git a/.travis.yml b/.travis.yml index 7e14b19..ff53345 100644 --- a/.travis.yml +++ b/.travis.yml @@ -4,8 +4,5 @@ node_js: - '10' - '8' - '6' - - '4' - - '0.12' - - '0.10' after_script: - npm run coveralls diff --git a/appveyor.yml b/appveyor.yml index d8845d7..8ead79d 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -4,9 +4,6 @@ environment: matrix: # node.js - - nodejs_version: "0.10" - - nodejs_version: "0.12" - - nodejs_version: "4" - nodejs_version: "6" - nodejs_version: "8" - nodejs_version: "10" diff --git a/index.js b/index.js index cb4d2fb..900d3fb 100644 --- a/index.js +++ b/index.js @@ -1,7 +1,7 @@ 'use strict'; var isGlob = require('is-glob'); -var pathDirname = require('path-dirname'); +var pathPosixDirname = require('path').posix.dirname; var isWin32 = require('os').platform() === 'win32'; var slash = '/'; @@ -26,7 +26,7 @@ module.exports = function globParent(str) { // remove path parts that are globby do { - str = pathDirname.posix(str); + str = pathPosixDirname(str); } while (isGlob(str) || globby.test(str)); // remove escape chars and return result diff --git a/package.json b/package.json index 85cba82..2bf714b 100644 --- a/package.json +++ b/package.json @@ -10,7 +10,7 @@ "repository": "gulpjs/glob-parent", "license": "ISC", "engines": { - "node": ">= 0.10" + "node": ">= 6" }, "main": "index.js", "files": [ @@ -25,16 +25,15 @@ "coveralls": "nyc report --reporter=text-lcov | coveralls" }, "dependencies": { - "is-glob": "^4.0.1", - "path-dirname": "^1.0.2" + "is-glob": "^4.0.1" }, "devDependencies": { "coveralls": "github:phated/node-coveralls#2.x", "eslint": "^2.13.1", "eslint-config-gulp": "^3.0.1", "expect": "^1.20.2", - "mocha": "^3.5.3", - "nyc": "^10.3.2" + "mocha": "^6.0.2", + "nyc": "^13.3.0" }, "keywords": [ "glob",