refactor(xapi-explore-sr): convert to EM (#7191)

This commit is contained in:
b-Nollet
2023-11-17 16:55:11 +01:00
committed by GitHub
parent 06068cdcc6
commit 5fe53dfa99
4 changed files with 6 additions and 20 deletions

View File

@@ -1,3 +0,0 @@
'use strict'
module.exports = require('../../@xen-orchestra/babel-config')(require('./package.json'))

View File

@@ -1 +0,0 @@
../../scripts/babel-eslintrc.js

View File

@@ -1,13 +1,15 @@
#!/usr/bin/env node
import { createClient } from 'xen-api'
import archy from 'archy'
import chalk from 'chalk'
import execPromise from 'exec-promise'
import firstDefined from '@xen-orchestra/defined'
import forEach from 'lodash/forEach.js'
import humanFormat from 'human-format'
import map from 'lodash/map.js'
import orderBy from 'lodash/orderBy.js'
import pw from 'pw'
import { createClient } from 'xen-api'
import { forEach, map, orderBy } from 'lodash'
// ===================================================================

View File

@@ -25,9 +25,9 @@
"url": "https://vates.fr"
},
"preferGlobal": true,
"main": "dist/",
"main": "./index.mjs",
"bin": {
"xapi-explore-sr": "dist/index.js"
"xapi-explore-sr": "./index.mjs"
},
"engines": {
"node": ">=8"
@@ -42,19 +42,7 @@
"pw": "^0.0.4",
"xen-api": "^1.3.6"
},
"devDependencies": {
"@babel/cli": "^7.1.5",
"@babel/core": "^7.1.5",
"@babel/preset-env": "^7.1.5",
"cross-env": "^7.0.2",
"rimraf": "^5.0.1"
},
"scripts": {
"build": "cross-env NODE_ENV=production babel --source-maps --out-dir=dist/ src/",
"dev": "cross-env NODE_ENV=development babel --watch --source-maps --out-dir=dist/ src/",
"prebuild": "rimraf dist/",
"predev": "yarn run prebuild",
"prepublishOnly": "yarn run build",
"postversion": "npm publish"
}
}