智能照明系统APP-本地串口
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
LightingSystemApp-serial/.svn/pristine/0c/0cb147bc81a043ad596629d2e8a...

30 lines
605 B

const path = require('path')
const {
normalizePath
} = require('@dcloudio/uni-cli-shared')
const {
getPlatformExts
} = require('../shared')
const templateExt = getPlatformExts().template
const SLOTS_OUTPUT_PATH = '/[root]common/slots'
function getRelativePath (from, to) {
let relativePath = path.relative(from, to)
if (relativePath.indexOf('.') !== 0) {
relativePath = './' + relativePath
}
return normalizePath(relativePath)
}
function getSlotsPath (root) {
return SLOTS_OUTPUT_PATH.replace('[root]', root) + templateExt
}
module.exports = {
getSlotsPath,
getRelativePath
}